/* Import Google Fonts: Space Grotesk (Headings) & Inter (Body) */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500&family=Space+Grotesk:wght@500;700&display=swap');

:root {
    --bg-body: #F4F4F5; /* Light Grey (Not pure white) */
    --bg-card: #FFFFFF;
    --text-main: #18181B;
    --text-muted: #71717A;
    --accent: #000000;
    --radius: 16px;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.05), 0 10px 10px -5px rgba(0, 0, 0, 0.02);
}

* { box-sizing: border-box; }

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-body);
    /* Subtle Dot Pattern Background for "Pro" feel */
    background-image: radial-gradient(#e5e7eb 1px, transparent 1px);
    background-size: 24px 24px;
    color: var(--text-main);
    margin: 0;
    padding-bottom: 80px;
    /* FIX FOR MOBILE CLICK OUTSIDE: */
    cursor: pointer; /* Tricks iOS into passing clicks to the body */
    -webkit-tap-highlight-color: transparent;
}

a { text-decoration: none; color: inherit; }

/* --- HEADER: Floating Glassmorphism Style --- */
.main-header {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

/* .logo { 
    font-family: 'Space Grotesk', sans-serif; 
    font-weight: 700; 
    font-size: 1.5rem; 
    letter-spacing: -0.03em;
} */

/* 1. Your Existing Logo Styles */
.logo-link {
    display: block;
    width: 150px; 
    height: 50px;
    background-image: url('/images/paletedecklogoMob.png'); /* Mobile First */
    background-size: contain;
    background-repeat: no-repeat;
}

@media (min-width: 768px) {
    .logo-link {
        width: 300px;
        height: 50px;
        background-image: url('/images/paletedeckLogo.png'); /* Desktop Switch */
    }
}

/* 2. NEW: The "Screen Reader Only" Utility Class */
/* This effectively hides the text from the eye, but not from Google */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
 

.btn-create {
    background: var(--text-main);
    color: white;
    padding: 10px 20px;
    border-radius: 50px; /* Pill shape */
    font-weight: 500;
    font-size: 0.9rem;
    transition: transform 0.2s;
}
.btn-create:hover { transform: scale(1.05); }

/* --- HERO: Big & Bold --- */
.hero-section {
    text-align: center;
    padding: 80px 20px 60px;
    max-width: 800px;
    margin: 0 auto;
}
.hero-section h1 { 
    font-family: 'Space Grotesk', sans-serif;
    font-size: 3.5rem; 
    line-height: 1.1;
    margin-bottom: 1rem;
    letter-spacing: -0.04em;
}
.hero-section p { 
    font-size: 1.1rem; 
    color: var(--text-muted); 
}

/* --- TABS: Minimalist Underline --- */
.filter-bar {
    display: flex;
    justify-content: center;
    margin-bottom: 40px;
}
.tabs {
    background: white;
    padding: 6px;
    border-radius: 50px;
    box-shadow: var(--shadow);
    display: inline-flex;
    gap: 5px;
}
.tabs a {
    padding: 10px 24px;
    border-radius: 40px;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: all 0.2s;
}
.tabs a.active {
    background: var(--text-main);
    color: white;
}

/* --- GRID --- */
.palette-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); /* Slightly wider cards */
    gap: 32px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- PALETTE CARD CONTAINER --- */
.palette-card {
    background: var(--bg-card);
    border-radius: 24px;
    padding: 12px;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease;
}
.palette-card:hover { transform: translateY(-5px); }

/* --- MAIN DISPLAY (The Stack) --- */
.palette-display {
    height: 220px;
    display: flex;
    flex-direction: column; /* This makes it VERTICAL STACK (Cake Layers) */
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent; /* Removes blue tap box on mobile */
}

/* --- COLOR STRIP --- */
.color-strip {
    width: 100%;
    flex: 1; /* All strips start with equal height */
    position: relative;
    transition: flex 0.3s cubic-bezier(0.25, 1, 0.5, 1); /* Smooth resize animation */
    
    display: flex;
    align-items: center;
    justify-content: center;
}

/* --- DESKTOP HOVER EFFECTS --- */
@media (hover: hover) {
    /* When hovering the container, expand the hovered strip */
    .palette-display:hover .color-strip:hover { flex: 2; }
    
    /* Shrink the others */
    .palette-display:hover .color-strip:not(:hover) { flex: 0.8; }
    
    /* Show Hex Code on Hover */
    .palette-display:hover .color-strip:hover .hex-pill { opacity: 1; transform: scale(1); }
}

/* --- MOBILE ACTIVE STATES (Triggered by JS) --- */
.color-strip.active { flex: 2 !important; }
.palette-display.has-active .color-strip:not(.active) { flex: 0.8; }
.color-strip.active .hex-pill { opacity: 1 !important; transform: scale(1) !important; }


/* --- HEX PILL (The Text) --- */
.hex-pill {
    /* 1. Make text readable on ANY color */
    background-color: rgba(0, 0, 0, 0.6); /* Dark semi-transparent background */
    backdrop-filter: blur(4px);
    color: white;
    
    /* 2. Positioning & Size */
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-family: monospace;
    font-weight: bold;
    z-index: 10;
    
    /* 3. Animation State: Hidden by Default */
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.2s cubic-bezier(0.25, 1, 0.5, 1);
    pointer-events: none; /* Allows clicks to pass through to the color strip */
}

/* --- FORCE VISIBILITY RULES --- */

/* Rule A: Desktop Hover */
@media (hover: hover) {
    .palette-display:hover .color-strip:hover .hex-pill {
        opacity: 1;
        transform: scale(1);
    }
}

/* Rule B: Mobile Active State (The Fix!) */
/* We use !important to ensure this overrides everything else */
.color-strip.active .hex-pill {
    opacity: 1 !important;
    transform: scale(1) !important;
    display: block !important;
}
.copy-icon { opacity: 0.6; }


/* Meta Data */
.palette-meta {
    padding: 12px 8px 4px; /* Spacing below the colors */
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.like-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-family: 'Space Grotesk', sans-serif;
    color: var(--text-main);
    transition: 0.2s;
    padding: 8px 12px;
    border-radius: 8px;
}
.like-btn:hover { background: #f0f0f0; }
/* Liked State for Button */
.like-btn.liked {
    color: #E1306C; /* Instagram Red/Pink */
    background: rgba(225, 48, 108, 0.1);
}

.like-btn.liked svg {
    fill: #E1306C; /* Fills the heart icon */
    transform: scale(1.1); /* Slight pop effect */
}

/* Creator Tool (Quick Fix for layout) */
.creator-container { max-width: 900px; margin: 40px auto; padding: 20px; }
.palette-editor { border-radius: 24px; box-shadow: var(--shadow-hover); }

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .hero-section h1 { font-size: 2.5rem; }
    .palette-grid { gap: 20px; }
}
/* --- CREATOR STUDIO STYLES --- */

.creator-wrapper {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 20px;
}

.creator-header-text {
    text-align: center;
    margin-bottom: 40px;
}
.creator-header-text h1 { font-family: 'Space Grotesk', sans-serif; font-size: 3rem; margin-bottom: 0.5rem; }
.creator-header-text p { color: var(--text-muted); }
.creator-header-text kbd {
    background: #eee;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9em;
    border: 1px solid #ddd;
}

/* The Main UI Container */
.creator-ui {
    background: white;
    border-radius: 32px; /* Very round */
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.1); /* Floating effect */
    padding: 20px;
}

/* Vertical Editor Columns */
.editor-display {
    height: 400px; /* Tall workspace */
    display: flex; /* Horizontal row of vertical columns */
    border-radius: 24px;
    overflow: hidden;
    margin-bottom: 20px;
}

.editor-col {
    flex: 1;
    position: relative;
    transition: flex 0.2s;
    display: flex;
    flex-direction: column;
    justify-content: flex-end; /* Text at bottom */
    align-items: center;
    padding-bottom: 30px;
}

.editor-col:hover { flex: 1.5; } /* Expand on hover */

/* The hidden color input covers the whole column */
.editor-col input[type="color"] {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    opacity: 0; /* Invisible but clickable */
    cursor: col-resize; /* Suggests adjustment */
}

/* Hex Code Text */
.editor-meta {
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(5px);
    padding: 6px 12px;
    border-radius: 50px;
    pointer-events: none; /* Let clicks pass through to input */
    z-index: 2;
}

.hex-val {
    font-family: 'Space Grotesk', monospace;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* Toolbar */
.creator-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 10px 0;
}

.tools-left {
    display: flex;
    gap: 8px;
    align-items: center;
}

.divider { width: 1px; height: 20px; background: #eee; margin: 0 10px; }

.tool-btn {
    background: white;
    border: 1px solid #eee;
    padding: 10px 18px;
    border-radius: 50px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    cursor: pointer;
    color: var(--text-main);
    transition: all 0.2s;
}

.tool-btn:hover {
    background: #f4f4f5;
    transform: translateY(-2px);
    border-color: #ccc;
}

.save-btn {
    background: var(--text-main); /* Black */
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 700;
    cursor: pointer;
    font-family: 'Space Grotesk', sans-serif;
    transition: transform 0.2s;
}
.save-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* Mobile Adjustments */
@media (max-width: 600px) {
    .editor-display { flex-direction: column; height: 500px; }
    .editor-col { width: 100%; height: 100%; }
    .creator-toolbar { flex-direction: column; gap: 20px; }
    .tools-left { flex-wrap: wrap; justify-content: center; }
}

/* --- 3-COLUMN LAYOUT SYSTEM --- */

.main-layout {
    display: grid;
    /* Left: 240px | Middle: Auto (Flex) | Right: 300px (Standard Ad Size) */
    grid-template-columns: 240px 1fr 300px; 
    gap: 40px;
    max-width: 1400px;
    margin: 30px auto;
    padding: 0 20px;
    align-items: start; /* Prevent sidebars from stretching height */
}

/* --- LEFT SIDEBAR (Navigation) --- */
.sidebar-nav {
    position: sticky;
    top: 100px; /* Sticks when scrolling */
    /* NEW: Constrain height and allow vertical scroll */
    max-height: calc(100vh - 120px); /* 100% of window height minus the 100px top gap + 20px bottom gap */
    overflow-y: auto; /* Creates the independent scroll */
    padding-right: 10px; /* Prevents the scrollbar from overlapping text */
}
/* NEW: Sleek Desktop Scrollbar */
@media (min-width: 769px) {
    .sidebar-nav::-webkit-scrollbar {
        width: 5px;
    }
    .sidebar-nav::-webkit-scrollbar-track {
        background: transparent;
    }
    .sidebar-nav::-webkit-scrollbar-thumb {
        background: #eaeaea; 
        border-radius: 10px;
    }
    .sidebar-nav::-webkit-scrollbar-thumb:hover {
        background: #ccc; 
    }
}
.nav-group { margin-bottom: 30px; }

.nav-group h3 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.85rem;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 1px;
    margin-bottom: 12px;
    padding-left: 10px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    border-radius: 12px;
    color: var(--text-main);
    font-weight: 500;
    transition: all 0.2s;
    margin-bottom: 4px;
}

.nav-item:hover {
    background-color: white;
    box-shadow: var(--shadow);
}

.nav-item.active {
    background-color: var(--text-main);
    color: white;
    box-shadow: var(--shadow-hover);
}

.nav-item .icon { font-size: 1.2rem; }

/* --- MIDDLE (Feed) --- */
.feed-content {
    width: 100%;
}
.mobile-header h1 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 20px;
    display: none; /* Hidden on desktop */
}

/* Override Grid for Middle Column */
.palette-grid {
    display: grid;
    /* Auto-fill logic for the middle column */
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); 
    gap: 24px;
    margin: 0; 
    padding: 0;
    max-width: 100%;
}

/* --- RIGHT SIDEBAR (Ads) --- */
.sidebar-ads {
    position: sticky;
    top: 100px;
}

.ad-placeholder {
    background: #e4e4e7;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #a1a1aa;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 20px;
}

/* Standard Ad Sizes */
.ad-placeholder { height: 250px; width: 100%; } /* Square Ad */
.ad-placeholder.small { height: 100px; } 


/* --- RESPONSIVENESS (Mobile & Tablet) --- */

@media (max-width: 900px) {
    /* Tablet: Reduce sidebar width */
    .main-layout {
        grid-template-columns: 200px 1fr;
        gap: 20px;
    }
}

@media (max-width: 768px) {
    /* MOBILE VIEW */
    .main-layout {
        display: block; /* Stack Sidebar on top of Feed */
    }
    
/* --- FLOATING BOTTOM NAV --- */
    .sidebar-nav {
        position: fixed;
        
        /*  THE FIX: Reset the desktop height and top positioning */
        top: auto; 
        height: auto;
        max-height: fit-content;
        
        bottom: 20px; /* Floats right in the thumb zone */
        left: 10px;
        right: 10px;
        z-index: 1000; 
        
        display: flex;
        overflow-x: auto;
        overflow-y: hidden; /* Ensure no vertical scrolling inside the pill */
        
        /* Modern Glass UI Look */
        background: rgba(255, 255, 255, 0.9);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        
        padding: 12px;
        border-radius: 24px; 
        gap: 16px;
        align-items: center;
        
        box-shadow: 0 10px 30px rgba(0,0,0,0.15); 
        border: 1px solid rgba(255,255,255,0.5);
        
        transition: transform 0.3s cubic-bezier(0.33, 1, 0.68, 1), opacity 0.3s ease;
        
        -ms-overflow-style: none;
        scrollbar-width: none;
    }

    /* This class gets added by JS when scrolling down */
    .sidebar-nav.hidden-nav {
        transform: translateY(150%); /* Pushes it down off the screen */
        opacity: 0;
    }

    /* Add padding to the bottom of the feed so the last palettes aren't hidden behind the nav */
    .feed-content {
        padding-bottom: 100px; 
    }
    .sidebar-nav::-webkit-scrollbar { display: none; }
    
    .nav-group { 
        margin: 0; 
        display: flex; 
        gap: 8px; 
        flex-shrink: 0; /* Prevent squishing */
    }
    
    /* Add a divider line between groups on mobile only */
    .nav-group:not(:last-child):after {
        content: '';
        display: block;
        width: 1px;
        height: 24px;
        background: #eee;
        margin-left: 8px;
    }

    .nav-group h3 { display: none; } /* Hide headers on mobile */
    
    .nav-item { 
        white-space: nowrap; 
        padding: 8px 14px; 
        font-size: 0.9rem; 
        margin: 0;
        background: #f4f4f5; 
        border-radius: 50px;
    }
    .nav-item.active { background: var(--text-main); color: white; }
    
    .mobile-header h1 { display: block; }

    /* --- MOBILE GRID (2x2) --- */
    .palette-grid {
        grid-template-columns: 1fr 1fr; 
        gap: 12px; 
    }

    .palette-card {
        padding: 8px;
        border-radius: 16px;
    }
    
    .palette-display {
        height: 140px; 
        border-radius: 12px;
    }

    .hex-pill { display: none; }
    
    .palette-meta { padding: 8px 4px 0; }
    .like-btn { font-size: 0.8rem; padding: 4px; }
}
/* --- MOCKUP PAGE STYLES --- */

.mockup-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

.mockup-header {
    text-align: center;
    margin-bottom: 60px;
}

.mockup-container {
    display: flex;
    justify-content: center;
    gap: 60px;
    align-items: center;
    flex-wrap: wrap;
}

/* --- Generic Device Styling --- */
.mock-device {
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.2);
    transition: transform 0.3s ease;
}
.mock-device:hover { transform: translateY(-10px); }

/* --- DESKTOP STYLES --- */
.desktop {
    width: 600px;
    height: 450px;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #eee;
}

.browser-bar {
    background: #f1f3f4;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid #ddd;
}
.dots { display: flex; gap: 6px; }
.dots span { width: 10px; height: 10px; border-radius: 50%; background: #ddd; }
.dots span:nth-child(1) { background: #ff5f56; }
.dots span:nth-child(2) { background: #ffbd2e; }
.dots span:nth-child(3) { background: #27c93f; }
.url-bar {
    flex-grow: 1;
    background: white;
    border-radius: 4px;
    padding: 4px 12px;
    font-size: 0.8rem;
    color: #999;
    border: 1px solid #eee;
    text-align: center;
}

.website-skeleton { height: calc(100% - 40px); overflow-y: auto; }
.mock-nav { padding: 15px 20px; display: flex; justify-content: space-between; font-weight: 700; }
.mock-links { display: flex; gap: 20px; font-weight: 500; font-size: 0.9rem; }
.mock-hero { padding: 40px 20px; text-align: center; }
.mock-hero h2 { font-size: 1.8rem; margin-bottom: 10px; }
.mock-btn { border: none; padding: 10px 24px; border-radius: 4px; font-weight: bold; margin-top: 20px; cursor: not-allowed; }

.mock-content { padding: 30px 20px; display: flex; gap: 20px; justify-content: center; }
.mock-card { flex: 1; padding: 20px; border-radius: 8px; text-align: center; box-shadow: 0 2px 5px rgba(0,0,0,0.05); }
.icon-box { width: 40px; height: 40px; margin: 0 auto 15px; border-radius: 8px; opacity: 0.8; }
.text-line { height: 8px; background: #eee; margin: 10px auto; border-radius: 4px; }
.text-line.short { width: 60%; }


/* --- MOBILE STYLES --- */
.mobile {
    width: 280px;
    height: 560px; /* Phone Aspect Ratio */
    background: #111;
    border-radius: 36px;
    padding: 12px; /* Bezel */
}

.phone-frame {
    background: white;
    width: 100%;
    height: 100%;
    border-radius: 24px;
    overflow: hidden;
    position: relative;
}

.notch {
    position: absolute; top: 0; left: 50%; transform: translateX(-50%);
    width: 120px; height: 24px;
    background: #111;
    border-bottom-left-radius: 16px;
    border-bottom-right-radius: 16px;
    z-index: 10;
}

.app-skeleton { height: 100%; display: flex; flex-direction: column; }
.app-header { padding: 35px 15px 15px; display: flex; justify-content: space-between; font-weight: bold; }
.app-body { flex-grow: 1; padding: 20px; overflow-y: auto; }
.app-body h3 { margin-bottom: 20px; }

.app-card.featured { padding: 20px; border-radius: 16px; margin-bottom: 25px; }
.app-list-item { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 12px; margin-bottom: 10px; }
.avatar { width: 36px; height: 36px; border-radius: 50%; }
.lines .line { width: 100px; height: 8px; background: #eee; margin-bottom: 6px; border-radius: 4px;}
.lines .line.short { width: 60px; }

.app-tabs {
    display: flex; justify-content: space-around; padding: 10px 0;
    border-top: 1px solid #eee; font-size: 0.7rem; text-align: center;
}
.tab { opacity: 0.5; }
.tab.active { opacity: 1; font-weight: bold; }

/* Responsiveness for Mockup Page */
@media (max-width: 950px) {
    .desktop { width: 100%; height: auto; aspect-ratio: 4/3; }
}
.mockup-link-btn {
    color: var(--text-muted);
    padding: 8px;
    border-radius: 8px;
    display: flex;
    transition: 0.2s;
}
.mockup-link-btn:hover { background: #f0f0f0; color: var(--text-main); }

/* --- MOCKUP HEADER UPGRADES --- */

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 20px;
}

.header-content h1 { margin: 0; font-size: 2rem; font-family: 'Space Grotesk'; }

.btn-download {
    background: var(--text-main);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: 0.2s;
}
.btn-download:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }

/* The Row of 4 Color Cards */
.detail-strip {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    margin-bottom: 60px;
}

.detail-card {
    background: white;
    padding: 10px;
    border-radius: 16px;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: transform 0.2s;
}
.detail-card:hover { transform: translateY(-5px); }

.color-preview {
    width: 100%;
    height: 80px;
    border-radius: 10px;
    margin-bottom: 12px;
    box-shadow: inset 0 0 0 1px rgba(0,0,0,0.05); /* Subtle border for white colors */
}

.color-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.hex-text {
    font-family: 'Space Grotesk', monospace;
    font-weight: 700;
    font-size: 1.1rem;
    cursor: pointer;
}
.hex-text:hover { color: var(--text-muted); }

.rgb-text {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-family: monospace;
}

/* Mobile Adjust for Mockup Header */
@media (max-width: 600px) {
    .detail-strip { grid-template-columns: 1fr 1fr; }
    .header-content { justify-content: center; text-align: center; }
}

/* --- ADMIN DASHBOARD STYLES --- */

/* 1. Header Layout */
.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    background: white;
    padding: 20px;
    border-radius: 16px;
    box-shadow: var(--shadow);
}

.header-text h1 { margin: 0; font-family: 'Space Grotesk'; font-size: 1.8rem; }
.header-text p { margin: 5px 0 0; color: #888; font-size: 0.9rem; }

/* 2. Toolbar Buttons */
.admin-tools {
    display: flex;
    gap: 10px;
}

.tool-btn {
    padding: 10px 18px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    border: 1px solid #eee;
    background: white;
    color: var(--text-main);
    transition: 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap; /* Prevent text wrapping inside button */
}

.tool-btn:hover { background: #f8f9fa; transform: translateY(-2px); }
.tool-btn.dark { background: #222; color: white; border: none; }
.tool-btn.dark:hover { background: #000; }

/* 3. Section Label */
.section-label {
    color: #666;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 20px;
    padding-left: 5px;
    text-transform: uppercase;
}

/* 4. Admin Card Actions */
.admin-card-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    padding-top: 15px;
}

.action-btn {
    border: none;
    padding: 10px 20px;
    border-radius: 50px;
    cursor: pointer;
    font-weight: bold;
    font-size: 0.85rem;
    transition: 0.2s;
    width: 100px; /* Fixed width for alignment */
}
.action-btn.approve { background: #dcfce7; color: #16a34a; }
.action-btn.reject { background: #fee2e2; color: #dc2626; }
.action-btn:hover { transform: scale(1.05); filter: brightness(0.95); }

/* --- RESPONSIVE MOBILE TWEAKS --- */
@media (max-width: 768px) {
    
    /* A. Stack the Header */
    .admin-header {
        flex-direction: column;
        align-items: stretch; /* Full width children */
        gap: 20px;
        text-align: center;
    }

    /* B. Make Tools a Grid (2x2 or Stacked) */
    .admin-tools {
        display: grid;
        grid-template-columns: 1fr; /* Stack vertically for easiest touch targets */
        gap: 10px;
    }

    .tool-btn {
        justify-content: center; /* Center text */
        padding: 14px; /* Larger touch target */
        font-size: 1rem;
    }

    /* C. Approve/Reject Buttons - Full Width */
    .admin-card-actions {
        flex-direction: row; 
    }
    
    .action-btn {
        flex: 1; /* Buttons take up equal space */
        width: auto;
    }
}

/* --- RICH FOOTER STYLES --- */

.main-footer {
    background: #111; /* Dark theme for separation */
    color: #fff;
    padding: 80px 20px 30px;
    margin-top: 80px;
    border-top: 1px solid #222;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.5fr 2.5fr; /* Brand takes 1.5 parts, Nav takes 2.5 */
    gap: 60px;
    margin-bottom: 60px;
}

/* 1. Brand Section */
.footer-brand {
    max-width: 350px;
}

.footer-logo {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.brand-tagline {
    color: #999;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 25px;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    color: #fff;
    background: #222;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: 0.2s;
}
.social-links a:hover { background: #333; transform: translateY(-3px); }

/* 2. Navigation Columns */
.footer-nav {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 Equal Columns */
    gap: 40px;
}

.footer-col h4 {
    color: #fff;s
    margin-bottom: 20px;
    font-family: 'Space Grotesk';
    font-size: 1.1rem;
    letter-spacing: 0.5px;
}

.footer-col a {
    display: block;
    color: #888;
    text-decoration: none;
    margin-bottom: 12px;
    font-size: 0.9rem;
    transition: 0.2s;
}

.footer-col a:hover { color: #fff; transform: translateX(5px); }

/* 3. Bottom Bar */
.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 30px;
    border-top: 1px solid #222;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #666;
    font-size: 0.85rem;
}

.legal-links { display: flex; align-items: center; gap: 15px; }
.legal-links a { color: #666; text-decoration: none; transition: 0.2s; }
.legal-links a:hover { color: #fff; text-decoration: underline; }
.dot { font-size: 0.6rem; opacity: 0.5; }


/* --- RESPONSIVE FOOTER --- */
@media (max-width: 900px) {
    .footer-container {
        grid-template-columns: 1fr; /* Stack Brand on top of Nav */
        gap: 50px;
    }
}

@media (max-width: 600px) {
    .footer-nav {
        grid-template-columns: 1fr; /* Stack all nav links vertically */
        gap: 40px;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}