:root {
    /* Soft, premium, baby-friendly color palette */
    --primary: #4A5568; /* Soft charcoal */
    --primary-dark: #2D3748;
    --accent: #D4A373; /* Warm soft tan/gold */
    --accent-hover: #C8925A;
    --bg-main: #FAF9F6; /* Warm off-white / Cream */
    --bg-soft: #F0EBE1; /* Slightly darker warm tone for sections */
    --surface: #FFFFFF;
    --text: #4A5568;
    --text-light: #718096;
    --border: #E2E8F0;
    --radius-lg: 16px;
    --radius-sm: 8px;
    --shadow-soft: 0 10px 40px rgba(0, 0, 0, 0.04);
    --shadow-hover: 0 15px 50px rgba(0, 0, 0, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-main);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, .logo, .footer-logo {
    font-family: 'Playfair Display', serif;
    color: var(--primary-dark);
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Navbar */
.navbar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(0,0,0,0.03);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    font-size: 1.75rem;
    font-weight: 700;
    font-style: italic;
    letter-spacing: -0.5px;
}

/* Custom Dropdown */
.custom-dropdown {
    position: relative;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
}

.dropdown-selected {
    padding: 8px 16px;
    border: 1px solid var(--border);
    border-radius: 30px;
    background: var(--surface);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
    user-select: none;
    font-weight: 500;
}

.dropdown-selected:hover {
    border-color: var(--accent);
}

.dropdown-selected::after {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%234A5568' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") no-repeat center;
    margin-left: 4px;
    transition: transform 0.2s;
}

.custom-dropdown.open .dropdown-selected::after {
    transform: rotate(180deg);
}

.dropdown-options {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-hover);
    width: max-content;
    min-width: 130px;
    z-index: 101;
    display: none;
    overflow: hidden;
}

.custom-dropdown.open .dropdown-options {
    display: block;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.dropdown-option {
    padding: 12px 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: background 0.2s;
    color: var(--text);
}

.dropdown-option:hover {
    background: var(--bg-soft);
    color: var(--primary-dark);
}

.flag {
    font-size: 1.2rem;
    line-height: 1;
}

/* Hero Section */
.hero {
    position: relative;
    padding: 100px 0;
    min-height: 80vh;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    /* Soft, emotional baby image */
    background-image: url('https://images.unsplash.com/photo-1519689680058-324335c77eba?auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center 30%;
    z-index: 0;
}

/* Soft gradient overlay to make text readable but keep the image bright */
.hero-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to right, rgba(250, 249, 246, 0.95) 0%, rgba(250, 249, 246, 0.7) 50%, rgba(250, 249, 246, 0.2) 100%);
}

.hero-content {
    position: relative;
    z-index: 1;
    width: 100%;
}

.hero-text-box {
    max-width: 550px;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(15px);
    padding: 50px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(255,255,255,0.5);
}

.hero h1 {
    font-size: 3.2rem;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.15;
    color: var(--primary-dark);
}

.hero p {
    font-size: 1.15rem;
    margin-bottom: 35px;
    color: var(--text);
    font-weight: 300;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 16px 32px;
    border-radius: 40px;
    font-weight: 500;
    font-size: 1.05rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    text-align: center;
    font-family: 'Inter', sans-serif;
}

.btn-primary {
    background: var(--primary-dark);
    color: white;
    box-shadow: 0 8px 20px rgba(45, 55, 72, 0.2);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(45, 55, 72, 0.3);
    background: #1a202c;
}

.btn-accent {
    background: var(--accent);
    color: white;
    width: 100%;
    margin-top: 25px;
    font-size: 1.1rem;
    padding: 18px 32px;
    box-shadow: 0 8px 20px rgba(212, 163, 115, 0.3);
}

.btn-accent:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(212, 163, 115, 0.4);
}

/* Sections */
.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 50px;
    font-weight: 600;
}

.bg-soft {
    background-color: var(--bg-soft);
    padding: 80px 0;
}

/* How It Works */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

.step-card {
    background: var(--surface);
    padding: 40px 30px;
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: var(--shadow-soft);
    transition: transform 0.3s ease;
}

.step-card:hover {
    transform: translateY(-5px);
}

.step-icon {
    font-size: 3rem;
    margin-bottom: 20px;
}

.step-card h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
}

.step-card p {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* Preview Section */
.preview-section {
    padding: 100px 24px;
}

.preview-container {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 60px;
    align-items: center;
}

.canvas-display-area {
    background: #E8E4DB; /* Soft wall color */
    border-radius: var(--radius-lg);
    padding: 60px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 500px;
    position: relative;
    overflow: hidden;
}

/* Add a subtle wallpaper/texture hint to the wall */
.canvas-display-area::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: radial-gradient(#d5d1c8 1px, transparent 1px);
    background-size: 20px 20px;
    opacity: 0.5;
}

.canvas-mockup {
    position: relative;
    z-index: 2;
    /* More realistic 3D effect */
    transform: perspective(1200px) rotateY(-10deg) rotateX(2deg);
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.canvas-mockup:hover {
    transform: perspective(1200px) rotateY(-2deg) rotateX(0deg);
}

.canvas-mockup img {
    display: block;
    width: 100%;
    max-width: 400px;
    height: auto;
    background: #fff;
    border-radius: 2px;
    box-shadow: inset 0 0 20px rgba(0,0,0,0.05);
}

/* Examples Carousel */
.examples-carousel {
    position: relative;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    z-index: 2;
}

.carousel-track {
    position: relative;
    width: 100%;
    aspect-ratio: 4/5;
    background: #fff;
    border-radius: 2px;
}

.canvas-mockup img.carousel-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    border-radius: 2px;
}

.canvas-mockup img.carousel-img.active {
    opacity: 1;
}

.carousel-overlay-text {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.6);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    white-space: nowrap;
    backdrop-filter: blur(4px);
    z-index: 10;
    pointer-events: none;
}

/* Canvas Edges for 3D realism */
.canvas-edge-right {
    position: absolute;
    top: 3px;
    right: -15px;
    width: 15px;
    height: 100%;
    background: linear-gradient(to right, rgba(0,0,0,0.1), rgba(0,0,0,0.3));
    transform: skewY(45deg);
    transform-origin: top left;
    border-radius: 0 2px 2px 0;
}

.canvas-edge-bottom {
    position: absolute;
    bottom: -15px;
    left: 3px;
    width: 100%;
    height: 15px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.1), rgba(0,0,0,0.4));
    transform: skewX(45deg);
    transform-origin: top left;
    border-radius: 0 0 2px 2px;
}

.canvas-shadow {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.15);
    filter: blur(20px);
    z-index: -1;
    transform: translateZ(-10px);
}

.preview-hint {
    margin-top: 30px;
    font-size: 0.85rem;
    color: #5a5750;
    text-transform: uppercase;
    letter-spacing: 2px;
    z-index: 2;
    background: rgba(255, 255, 255, 0.85);
    padding: 8px 20px;
    border-radius: 20px;
    border: 1px solid rgba(0,0,0,0.1);
    backdrop-filter: blur(8px);
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.config-card {
    background: var(--surface);
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border);
}

.form-group {
    margin-bottom: 30px;
}

.form-group label {
    display: block;
    margin-bottom: 12px;
    font-weight: 500;
    color: var(--primary-dark);
}

.styled-select {
    width: 100%;
    padding: 16px;
    font-size: 1.05rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface);
    color: var(--text);
    outline: none;
    transition: border-color 0.3s;
    font-family: 'Inter', sans-serif;
}

.styled-select:focus {
    border-color: var(--accent);
}

.price-display {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 25px;
    margin-top: 10px;
    border-top: 1px solid var(--border);
}

.price-display span {
    font-size: 1.1rem;
    color: var(--text-light);
}

.price-display strong {
    font-size: 2.2rem;
    color: var(--primary-dark);
    font-weight: 700;
}

.guarantee-text {
    margin-top: 20px;
    font-size: 0.85rem;
    color: var(--text-light);
    line-height: 1.8;
    text-align: center;
}

/* Gallery */
.examples-section {
    padding: 80px 24px 80px;
}

.gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.gallery-item {
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
    aspect-ratio: 4/5;
    box-shadow: var(--shadow-soft);
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 30px 20px 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
    color: white;
    font-weight: 500;
    transform: translateY(10px);
    opacity: 0;
    transition: all 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

.gallery-item:hover .gallery-overlay {
    transform: translateY(0);
    opacity: 1;
}

/* FAQ Section */
.faq-section {
    padding: 80px 0 100px;
}

.faq-container {
    max-width: 800px;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.faq-item {
    background: var(--surface);
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.02);
    overflow: hidden;
    border: 1px solid var(--border);
}

.faq-question {
    width: 100%;
    text-align: left;
    padding: 24px 30px;
    background: none;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-dark);
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: background-color 0.3s;
}

.faq-question:hover {
    background-color: rgba(0, 0, 0, 0.01);
}

.faq-icon {
    font-size: 1.5rem;
    font-weight: 300;
    color: var(--accent);
    transition: transform 0.3s ease;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    background: var(--surface);
}

.faq-answer p {
    padding: 0 30px 24px;
    color: var(--text-light);
    line-height: 1.7;
}

.faq-item.active .faq-icon {
    transform: rotate(45deg);
}

/* Footer */
footer {
    background: var(--primary-dark);
    color: white;
    padding: 60px 0;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.footer-logo {
    font-size: 2rem;
    color: white;
    opacity: 0.9;
}

footer p {
    color: #A0AEC0;
    font-size: 0.9rem;
}

/* Pre-upload model selector in hero */
.pre-upload-config {
    margin-bottom: 16px;
}

.pre-upload-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.pre-upload-row label {
    font-weight: 500;
    color: var(--primary-dark);
    white-space: nowrap;
    font-size: 0.95rem;
}

.styled-select-inline {
    padding: 8px 12px;
    font-size: 0.95rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,0.9);
    color: var(--text);
    outline: none;
    transition: border-color 0.3s;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
}

.styled-select-inline:focus {
    border-color: var(--accent);
}

/* Style Thumbnails */
.style-selection-row {
    align-items: center;
    margin-top: 15px;
    justify-content: center;
}

.style-thumbnails {
    display: flex;
    gap: 15px;
}

.style-thumbnail {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px;
    border: 2px solid transparent;
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,0.7);
    transition: all 0.2s ease;
}

.style-thumbnail:hover {
    background: rgba(255,255,255,1);
    transform: translateY(-2px);
}

.style-thumbnail.active {
    border-color: var(--accent);
    background: #fff;
    box-shadow: 0 4px 15px rgba(212, 163, 115, 0.25);
}

.style-thumbnail img {
    width: 90px;
    height: 90px;
    border-radius: 8px;
    object-fit: cover;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.style-thumbnail span {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text);
    text-align: center;
}

/* Upload error */
.upload-error {
    margin-top: 20px;
    background-color: #FFF5F5;
    color: #C53030;
    border: 2px solid #FEB2B2;
    padding: 16px;
    border-radius: var(--radius-sm);
    font-size: 1.05rem;
    font-weight: 600;
    text-align: center;
    box-shadow: 0 4px 12px rgba(229, 62, 62, 0.15);
    animation: fadeIn 0.3s ease;
}

/* Privacy Note */
.privacy-note {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 24px auto 0;
    max-width: 400px;
    padding: 16px 20px;
    background: #FFFFFF;
    border-radius: var(--radius-sm);
    border: 2px solid #48BB78; /* Trust/Safety green */
    font-size: 0.95rem;
    color: #2D3748;
    text-align: left;
    line-height: 1.5;
    box-shadow: 0 6px 15px rgba(72, 187, 120, 0.15);
    font-weight: 500;
}

.privacy-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    color: #48BB78;
}

#uploadLabel {
    display: block;
    width: 100%;
    max-width: 350px;
    margin: 20px auto 0;
    text-align: center;
}

/* Loading State (New Design) */
.generating-state {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 400px;
    background: #111;
    border-radius: 2px;
    margin: 0 auto;
    overflow: hidden;
}

.generating-canvas {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 2px;
    /* Remove blur so the minecraft blocks are sharp */
}

.generating-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle, rgba(255,255,255,0.8) 0%, rgba(255,255,255,0.4) 100%);
    z-index: 3;
}

.generating-canvas-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
    padding: 30px;
    text-align: center;
    z-index: 5;
}

.generating-text-content {
    background: rgba(255, 255, 255, 0.85);
    padding: 20px 30px;
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.spinner-modern {
    width: 56px;
    height: 56px;
    border: 4px solid rgba(212, 163, 115, 0.2);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
    box-shadow: 0 0 15px rgba(212, 163, 115, 0.3);
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.generating-msg {
    font-family: 'Playfair Display', serif;
    font-size: 1.6rem;
    color: var(--primary-dark);
    margin-bottom: 12px !important;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(255, 255, 255, 0.8);
}

.generating-hint {
    font-size: 0.95rem;
    color: var(--text-light);
    background: rgba(255, 255, 255, 0.9);
    padding: 8px 16px;
    border-radius: 20px;
    display: inline-block;
    font-weight: 500;
    border: 1px solid rgba(0,0,0,0.05);
}

/* Configurator layout inside preview */
.configurator {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Footer links */
.footer-links {
    display: flex;
    gap: 12px;
    align-items: center;
    font-size: 0.85rem;
}

.footer-links a {
    color: #A0AEC0;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: white;
}

.footer-links span {
    color: #4A5568;
}

/* Section padding for faq bg-soft */
.faq-section.bg-soft {
    padding: 80px 24px 100px;
}

/* Responsive */
@media (max-width: 900px) {
    .preview-container {
        grid-template-columns: 1fr;
    }
    .steps-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .gallery {
        grid-template-columns: 1fr;
    }
    .hero-text-box {
        padding: 30px;
        margin: 0 20px;
    }
    .hero h1 {
        font-size: 2.5rem;
    }
}