/* --- Global Variables --- */
:root {
    --bg-base: #0f0f11;      
    --bg-surface: #1a1a1d;   
    --bg-surface-hover: #222226;
    --text-primary: #f8f8f8; 
    --text-secondary: #a0a0a5;
    --accent-copper: #d47646; 
    --accent-copper-hover: #b85e32;
    --accent-turquoise: #2bc0b4; 
    --accent-turquoise-hover: #1e9b90;
    
    --font-heading: 'Rye', serif;
    --font-body: 'Inter', sans-serif;
    
    --shadow-soft: 0 8px 30px rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 15px rgba(212, 118, 70, 0.3);
}

/* --- Resets & Base Styles --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background: radial-gradient(circle at top center, #1a1a1d 0%, var(--bg-base) 100%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: normal;
    letter-spacing: 1.5px;
}

a {
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

/* --- Premium Navigation --- */
.main-nav {
    background-color: rgba(15, 15, 17, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1.2rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-logo {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    color: var(--accent-copper);
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 2.5rem;
    align-items: center;
}

.nav-links a {
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    color: var(--text-secondary);
}

.nav-links a:hover {
    color: var(--accent-copper);
}

#cart-toggle {
    background: transparent;
    border: 2px solid var(--accent-turquoise);
    color: var(--accent-turquoise);
    padding: 0.6rem 1.2rem;
    cursor: pointer;
    font-family: var(--font-body);
    font-weight: 600;
    border-radius: 6px;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

#cart-toggle:hover {
    background: var(--accent-turquoise);
    color: var(--bg-base);
    box-shadow: 0 0 15px rgba(43, 192, 180, 0.4);
}

/* Mobile Menu Toggle (Hidden on Desktop) */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
}

/* --- Hero Section --- */
.hero-section {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    background: url('https://placehold.co/1920x1080/121212/333?text=Western+Landscape') center/cover no-repeat;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(15,15,17,0.4) 0%, rgba(15,15,17,0.95) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    padding: 2rem;
    transform: translateY(20px);
    animation: fadeUp 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes fadeUp {
    to { opacity: 1; transform: translateY(0); }
}

.hero-title {
    font-size: 4.5rem;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    color: var(--text-primary);
    line-height: 1.1;
    text-shadow: 4px 4px 10px rgba(0,0,0,0.8);
}

.hero-subtitle {
    font-size: 1.3rem;
    margin-bottom: 3rem;
    color: var(--text-secondary);
    font-weight: 400;
}

/* --- Premium Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem;
    font-family: var(--font-body);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--accent-copper);
    color: #fff;
    border: none;
    box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
    background-color: var(--accent-copper-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(212, 118, 70, 0.5);
}

.btn-outline {
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
    margin-left: 1.5rem;
}

.btn-outline:hover {
    background-color: #fff;
    color: var(--bg-base);
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    color: var(--accent-turquoise);
    border: 1px solid var(--accent-turquoise);
    padding: 0.8rem 2rem;
    font-size: 0.9rem;
}

.btn-secondary:hover {
    background-color: var(--accent-turquoise);
    color: var(--bg-base);
}

/* --- Category Grid --- */
.category-section {
    max-width: 1400px;
    margin: 6rem auto;
    padding: 0 2rem;
}

.section-title {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 4rem;
    color: var(--text-primary);
}

.section-title span {
    color: var(--accent-copper);
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
}

.category-card {
    background-color: var(--bg-surface);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: var(--shadow-soft);
}

.category-card:hover {
    transform: translateY(-10px);
    border-color: var(--accent-copper);
    background-color: var(--bg-surface-hover);
}

.card-image {
    height: 250px;
    background-color: #111;
    border-radius: 8px;
    margin-bottom: 2rem;
    background-position: center;
    background-size: cover;
}

.category-card h3 {
    margin-bottom: 1.5rem;
    font-size: 1.6rem;
}

/* --- Customizer Layout --- */
.designer-container {
    max-width: 1500px;
    margin: 120px auto 6rem;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    gap: 4rem;
    align-items: start;
}

.preview-pane {
    background-color: var(--bg-surface);
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.05);
    min-height: 700px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 0 50px rgba(0,0,0,0.5);
}

.base-apparel {
    width: 85%;
    max-width: 600px;
    height: auto;
    transition: filter 0.4s ease;
}

.print-area {
    position: absolute;
    width: 35%;
    height: 45%;
    top: 25%;
    border: 2px dashed rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.3s ease;
}

.print-area:hover {
    border-color: rgba(255, 255, 255, 0.4);
}

#uploaded-graphic {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    display: none;
    cursor: grab;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3));
}

#uploaded-graphic:active {
    cursor: grabbing;
}

/* Tools Area */
.tools-pane {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
    position: sticky;
    top: 120px;
}

.tool-section {
    background-color: var(--bg-surface);
    padding: 2.5rem;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.05);
    box-shadow: var(--shadow-soft);
}

.tool-section h3 {
    color: var(--text-primary);
    margin-bottom: 2rem;
    font-size: 1.4rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.tool-section h3::before {
    content: '';
    display: block;
    width: 12px;
    height: 12px;
    background-color: var(--accent-copper);
    border-radius: 50%;
}

.color-options {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.color-swatch {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid var(--bg-surface);
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
}

.color-swatch:hover, .color-swatch.active {
    transform: scale(1.15);
    border-color: var(--accent-turquoise);
}

.upload-zone {
    border: 2px dashed rgba(212, 118, 70, 0.4);
    border-radius: 12px;
    padding: 4rem 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: rgba(0,0,0,0.2);
}

.upload-zone:hover, .upload-zone.dragover {
    background-color: rgba(212, 118, 70, 0.05);
    border-color: var(--accent-copper);
}

.upload-zone p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.size-selector {
    width: 100%;
    padding: 1.2rem;
    background-color: #111;
    color: var(--text-primary);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    margin-bottom: 2rem;
    font-family: var(--font-body);
    font-size: 1.1rem;
    appearance: none;
    cursor: pointer;
}

.size-selector:focus {
    outline: none;
    border-color: var(--accent-copper);
}

.price-display {
    font-size: 2.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    font-family: var(--font-heading);
}

/* --- Footer --- */
.site-footer {
    background-color: #050505;
    padding: 5rem 2rem 2rem;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand h3 {
    color: var(--accent-copper);
    margin-bottom: 1rem;
    font-size: 1.8rem;
}

.footer-brand p {
    color: var(--text-secondary);
    max-width: 350px;
    font-size: 1.1rem;
}

.footer-socials a {
    margin-right: 1.5rem;
    color: var(--text-primary);
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-socials a:hover {
    color: var(--accent-turquoise);
}

.footer-bottom {
    max-width: 1400px;
    margin: 0 auto;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 2rem;
    display: flex;
    justify-content: space-between;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.agency-credit {
    font-style: normal;
    color: #555;
}


/* --- 📱 MOBILE RESPONSIVENESS --- */
@media (max-width: 992px) {
    .designer-container {
        grid-template-columns: 1fr;
        gap: 2rem;
        margin-top: 100px;
    }
    
    .tools-pane {
        position: static;
    }
    
    .preview-pane {
        min-height: 500px;
    }
}

@media (max-width: 768px) {
    /* Navigation Adjustments */
    .mobile-menu-btn {
        display: block;
    }
    
    .nav-links {
        display: none; /* Hide on mobile initially */
        width: 100%;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        background-color: var(--bg-surface);
        padding: 2rem;
        border-bottom: 1px solid #333;
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .nav-container {
        flex-wrap: wrap;
    }
    
    .brand-logo {
        font-size: 1.2rem;
    }
    
    /* Typography Adjustments */
    .hero-title {
        font-size: 2.8rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .btn {
        width: 100%;
        margin: 0 0 1rem 0;
    }
    
    .section-title {
        font-size: 2.2rem;
    }
    
    /* Footer Adjustments */
    .footer-content {
        flex-direction: column;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}

/* --- Mobile Responsiveness (Add to bottom of style.css) --- */
@media (max-width: 768px) {
    /* Stack the navigation */
    .nav-container { 
        flex-direction: column; 
        gap: 1rem; 
        padding: 1rem;
    }
    
    .nav-links { 
        flex-wrap: wrap; 
        justify-content: center; 
        gap: 1rem; 
    }
    
    /* Adjust Hero for smaller screens */
    .hero-section {
        margin-top: 120px; /* Offset for taller stacked nav */
    }
    
    .hero-title { 
        font-size: 2.2rem; 
    }
    
    .hero-subtitle { 
        font-size: 1rem; 
        margin-bottom: 2rem;
    }
    
    .hero-actions {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }
    
    .btn-outline {
        margin-left: 0;
    }
    
    /* Stack the category grid */
    .category-grid { 
        grid-template-columns: 1fr; 
        gap: 1.5rem;
    }
    
    /* Center and stack the footer */
    .footer-content { 
        flex-direction: column; 
        gap: 2rem; 
        text-align: center; 
    }
    
    .footer-brand p {
        margin: 0 auto;
    }
    
    .footer-socials { 
        margin-top: 1rem; 
    }
    
    .footer-bottom { 
        flex-direction: column; 
        gap: 1rem; 
        text-align: center; 
    }
}