/*
--- mic-test.co Custom Stylesheet ---
*/

/* 1. CSS Variables & Global Styles */
:root {
    --font-sans: 'Inter', sans-serif;
    --color-text: #111827;      /* gray-900 */
    --color-text-muted: #4b5563; /* gray-600 */
    --color-bg: #f3f4f6;         /* gray-100 */
    --color-indigo: #6366f1;
    --color-purple: #a855f7;
    --color-red: #ef4444;
    --color-pink: #ec4899;
    --color-green: #22c55e;
    --glass-bg: rgba(255, 255, 255, 0.6);
    --glass-border: rgba(230, 232, 236, 0.8);
}

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

body {
    font-family: var(--font-sans);
    background-color: var(--color-bg);
    color: var(--color-text);
    zoom: 0.80;
}

.aurora-bg {
    opacity: 0.1;
    position: absolute;
    top: 50%;
    left: 50%;
    height: 500px;
    width: 100%;
    max-width: 1024px;
    transform: translate(-50%, -50%);
    filter: blur(100px);
    background-image: radial-gradient(at 27% 37%, hsla(215, 98%, 61%, 1) 0px, transparent 50%), radial-gradient(at 73% 44%, hsla(333, 73%, 52%, 1) 0px, transparent 50%);
}
.relative-wrapper { position: relative; z-index: 10; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 1rem; }

/* 2. Header & Navigation */
.main-header { padding: 1.25rem 0; }
.main-nav { display: flex; justify-content: space-between; align-items: center; }
.logo {
    font-size: 1.5rem;
    font-weight: 800; /* Extra-Bold */
    text-decoration: none;
    color: #1f2937;
    letter-spacing: 1px;
    text-transform: uppercase;
}
.logo span {
    font-weight: 400; /* Regular weight */
    color: var(--color-text-muted);
}
.nav-links { display: none; align-items: center; gap: 1.5rem; }
.nav-links a { font-size: 0.875rem; font-weight: 500; color: var(--color-text-muted); text-decoration: none; transition: color 0.2s ease; }
.nav-links a:hover { color: var(--color-indigo); }

/* 3. Main Content & Hero */
.hero-section { text-align: center; padding: 4rem 0 6rem 0; }
.hero-section h1 { font-size: 3rem; font-weight: 700; letter-spacing: -0.05em; }
.hero-section p { margin-top: 1rem; max-width: 42rem; margin-left: auto; margin-right: auto; font-size: 1.125rem; color: var(--color-text-muted); }

/* 4. Glass Card & Tool UI */
.glass-card {
    background-color: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 1rem;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.05);
    padding: 2rem;
}
.mic-tool-grid { display: grid; gap: 2rem; align-items: center; }
.controls-column { display: flex; flex-direction: column; gap: 1.5rem; }
h2.section-title { font-size: 1.125rem; font-weight: 600; margin-bottom: 0.5rem; }
.mic-select { margin-top: 0.5rem; width: 100%; padding: 0.75rem; border-radius: 0.375rem; border: 1px solid #d1d5db; background-color: #f9fafb; font-size: 0.875rem; }
.btn { width: 100%; display: flex; align-items: center; justify-content: center; gap: 0.5rem; font-weight: 600; padding: 0.75rem 1.5rem; border-radius: 0.375rem; border: none; cursor: pointer; transition: all 0.2s ease; color: white; }
.btn:hover { transform: scale(1.05); }
.btn-start { background-image: linear-gradient(to right, var(--color-indigo), var(--color-purple)); }
.btn-stop { background-image: linear-gradient(to right, var(--color-red), var(--color-pink)); }

/* 5. Results Section (Redesigned) */
#results {
    border-top: 1px solid #e5e7eb;
    padding-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}
.playback-card { background-color: #f9fafb; padding: 1rem; border-radius: 0.75rem; border: 1px solid #e5e7eb; }
audio { width: 100%; }
audio::-webkit-media-controls-panel { background-color: #f9fafb; }
.btn-secondary { width: 100%; margin-top: 1rem; background: #eef2ff; color: var(--color-indigo); font-weight: 600; transition: background-color 0.2s ease; }
.btn-secondary:hover { background: #e0e7ff; transform: scale(1.02); }

.results-list {
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    overflow: hidden;
    padding: 0 1rem;
}
.result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0.5rem;
    border-top: 1px solid #e5e7eb;
}
.result-item:first-child {
    border-top: none;
}
.metric-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.metric-icon {
    flex-shrink: 0;
    width: 1.25rem;
    height: 1.25rem;
    color: var(--color-text-muted);
}
.metric-label .label {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    font-weight: 500;
}
.result-item .value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-text);
    background-color: #eef2ff;
    padding: 0.25rem 0.6rem;
    border-radius: 0.375rem;
}

/* 6. Visualization */
.visuals-wrapper { height: 16rem; border-radius: 0.75rem; background-image: linear-gradient(to top right, #111827, #1f2937); display: flex; align-items: center; justify-content: center; padding: 1rem; }
#visual-placeholder { text-align: center; color: #6b7280; }
#waveform { width: 100%; height: 12rem; }

/* 7. Content Sections (GENERAL CONTAINER) */
.content-section { max-width: 56rem; margin: 6rem auto 0 auto; text-align: center; }
.content-section h2 { font-size: 2.25rem; font-weight: 700; }
.section-subtitle { margin-top: 0.5rem; font-size: 1.125rem; color: var(--color-text-muted); }


/* ================================================================== */
/* --- 7a. UNIFIED STYLES FOR ALL CONTENT SECTION CARDS & GRIDS --- */
/* ================================================================== */

/* 1. General Grid Container Styles */
/* This applies to "How It Works", "Features", and "Use Cases" */
.how-to-grid,
.features-grid,
.use-cases-grid {
    display: grid;
    gap: 1.5rem;
    margin-top: 3rem;
    text-align: left; /* Override the centered text from .content-section */
}

/* 2. Grid Column Layouts (Responsive) */
/* Default to a single column on mobile */
.how-to-grid,
.features-grid,
.use-cases-grid {
    grid-template-columns: 1fr;
}

/* On medium screens and up, switch to multi-column */
@media (min-width: 768px) {
    .how-to-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .features-grid,
    .use-cases-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* On large screens, the feature/use-case grids can expand */
@media (min-width: 1024px) {
    .features-grid,
    .use-cases-grid {
        /* Using 4 columns for the sections that have 4 items */
        grid-template-columns: repeat(4, 1fr);
    }
}


/* 3. Unified Card Style */
/* This styles every card in every section to look the same */
.how-to-card,
.feature-card,
.use-case-card {
    background-color: #ffffff;
    border: 1px solid #e5e7eb; /* Soft grey border */
    border-radius: 1rem;      /* 16px rounded corners */
    padding: 2rem 1.5rem;
    box-shadow: 0 4px 15px -2px rgba(0,0,0,0.06);
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}
.how-to-card:hover,
.feature-card:hover,
.use-case-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px -5px rgba(0,0,0,0.1);
}

/* 4. Typography Inside Cards */
.how-to-card h3,
.feature-card h3,
.use-case-card h4 { /* Your HTML uses h4 here */
    font-size: 1.125rem; /* 18px */
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 0.75rem;
}

.how-to-card p,
.feature-card p,
.use-case-card p {
    color: var(--color-text-muted);
    line-height: 1.6;
}

/* Special style for the step number in the "How It Works" section */
.how-to-card h3 .step-number {
    display: inline-block;
    width: 2rem;
    height: 2rem;
    line-height: 2rem;
    text-align: center;
    background-color: #eef2ff; /* Light indigo */
    color: var(--color-indigo);
    border-radius: 50%;
    font-weight: 700;
    margin-right: 0.75rem;
}


/* 5. FAQ Section Styles */
/* This is not a grid, but a vertical list */
.faq-container {
    margin-top: 3rem;
    text-align: left;
    border-top: 1px solid #e5e7eb;
}

.faq-item {
    padding: 1.5rem 0;
    border-bottom: 1px solid #e5e7eb;
}
.faq-item:first-child {
    padding-top: 2.5rem;
}
.faq-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.faq-item h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--color-text);
}

.faq-item p {
    color: var(--color-text-muted);
    line-height: 1.6;
    max-width: 45rem; /* Limit line length for readability */
}


/* 6. Privacy Section Cleanup */
.privacy-section {
    padding-top: 3rem;
    margin-top: 3rem;
    border-top: 1px solid #e5e7eb;
}
.privacy-section h2 {
    font-size: 1.75rem;
}


/* --- Language Selector Card --- */
.lang-selector-card {
    max-width: 56rem;
    margin: 3rem auto 0 auto;
    padding: 1.5rem;
}
.lang-label {
    font-weight: 500;
    color: var(--color-text-muted);
    margin-bottom: 1rem;
    font-size: 0.875rem;
}
.lang-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 0.75rem;
}
.lang-grid a {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    padding: 0.6rem 1rem;
    border-radius: 0.5rem;
    border: 1px solid #e5e7eb;
    color: var(--color-text);
    font-weight: 500;
    font-size: 0.875rem;
    transition: all 0.2s ease-in-out;
}
.lang-grid a:hover {
    border-color: var(--color-indigo);
    background-color: #f9fafb;
}
.lang-grid a.active {
    background-color: var(--color-green);
    border-color: var(--color-green);
    color: white;
    font-weight: 600;
    box-shadow: 0 4px 10px -2px rgba(34, 197, 94, 0.3);
}
.lang-grid .flag {
    font-size: 1rem;
    margin-right: 0.5rem;
    line-height: 1;
}
.lang-grid .checkmark {
    width: 1rem;
    height: 1rem;
    margin-left: auto;
}


/* 8. Footer */
.main-footer { text-align: center; padding: 2rem 0; margin-top: 4rem; border-top: 1px solid #e5e7eb; font-size: 0.875rem; color: #6b7280; }
.footer-links { margin-top: 0.5rem; }
.footer-links a { color: inherit; text-decoration: none; margin: 0 0.5rem; }
.footer-links a:hover { text-decoration: underline; }


/* 9. Utilities */
.hidden { display: none !important; }

/* 10. Responsive Design */
@media (min-width: 768px) {
    .nav-links { display: flex; }
    .hero-section h1 { font-size: 3.75rem; }
    .mic-tool-grid { grid-template-columns: repeat(2, 1fr); }
    /* Grid layouts for content sections are handled in section 7a */
}


/* 11. Troubleshooting Page Styles */
.page-hero {
    text-align: center;
    padding: 2rem 0 4rem 0;
}
.page-hero h1 {
    font-size: 2.5rem;
    font-weight: 700;
}
.troubleshooting-guide {
    max-width: 48rem; /* 768px */
    margin: 0 auto;
    border: 1px solid #e5e7eb;
    border-radius: 1rem;
    background-color: #ffffff;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05), 0 2px 4px -2px rgba(0,0,0,0.05);
    overflow: hidden;
}
.accordion-item {
    border-bottom: 1px solid #e5e7eb;
}
.accordion-item:last-child {
    border-bottom: none;
}
.accordion-header {
    width: 100%;
    background-color: transparent;
    border: none;
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    text-align: left;
}
.accordion-header:hover {
    background-color: #f9fafb;
}
.accordion-title {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.accordion-title h2 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--color-text);
}
.accordion-icon {
    width: 1.25rem;
    height: 1.25rem;
    color: var(--color-text-muted);
    transition: transform 0.3s ease;
}
.accordion-header.active .accordion-icon {
    transform: rotate(180deg);
    color: var(--color-indigo);
}
.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    color: var(--color-text-muted);
}
.accordion-content > div {
    padding: 0 1.5rem 1.5rem 1.5rem;
    line-height: 1.6;
}
.accordion-content ul, .accordion-content ol {
    padding-left: 2rem;
    margin-top: 1rem;
    margin-bottom: 1rem;
}
.accordion-content strong {
    color: var(--color-text);
    font-weight: 600;
}
.accordion-content code {
    background-color: #eef2ff;
    padding: 0.1rem 0.4rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
}


/* 12. Static Content Page Styles (e.g., Privacy, About) */
.content-page-wrapper {
    max-width: 48rem; /* 768px */
    margin: 2rem auto 0 auto;
    background-color: #ffffff;
    padding: 2rem 2.5rem;
    border-radius: 1rem;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05), 0 2px 4px -2px rgba(0,0,0,0.05);
    border: 1px solid #e5e7eb;
}
.content-page-wrapper h1 {
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 1rem;
}
.content-page-wrapper h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
}
.content-page-wrapper p, 
.content-page-wrapper li {
    line-height: 1.7;
    color: var(--color-text-muted);
    margin-bottom: 1rem;
}
.content-page-wrapper ul {
    padding-left: 1.5rem;
    list-style-type: disc;
}
.content-page-wrapper strong {
    color: var(--color-text);
    font-weight: 600;
}



/* 13. Mobile Navigation Styles */

.mobile-menu-toggle {
    display: none; /* Hidden by default on desktop */
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001; /* Ensure it's on top of other content */
    color: var(--color-text);
}

/* --- Styles for Mobile Screens (max-width: 767px) --- */
@media (max-width: 767px) {
    .mobile-menu-toggle {
        display: block; /* Show the hamburger button */
    }

    .nav-links {
        /* Mobile Menu Overlay Styles */
        position: fixed;
        top: 0;
        right: -100%; /* Start off-screen */
        width: 100%;
        height: 100vh;
        background-color: #ffffff;
        z-index: 1000;

        /* Layout for menu items */
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 2rem;
        
        transition: right 0.3s ease-in-out;
    }

    .nav-links.is-open {
        right: 0; /* Slide in from the right */
    }

    .nav-links a {
        font-size: 1.5rem; /* Make links larger for mobile */
        color: var(--color-text);
    }
}