/* =========================================================
   GramsToCups — Custom Stylesheet
   Built on top of Materialize CSS 1.0.0
   ========================================================= */

/* ----- CSS Variables ----- */
:root {
    --primary:        #00897B;
    --primary-dark:   #00695C;
    --primary-light:  #4DB6AC;
    --primary-xlight: #E0F2F1;
    --accent:         #FF6F00;
    --accent-light:   #FFF3E0;
    --text-dark:      #212121;
    --text-medium:    #546E7A;
    --text-light:     #90A4AE;
    --bg-light:       #F5F7FA;
    --bg-white:       #FFFFFF;
    --border:         #E0E0E0;
    --success:        #2E7D32;
    --error:          #C62828;
    --warning:        #E65100;
    --card-shadow:    0 2px 8px rgba(0,0,0,0.08);
    --card-shadow-hover: 0 6px 20px rgba(0,0,0,0.14);
    --radius:         8px;
}

/* ----- Reset & Base ----- */
*, *::before, *::after { box-sizing: border-box; }
a { text-decoration: none !important; }

html {
    scroll-behavior: smooth;
    overflow-x: hidden;   /* prevent horizontal scroll from decorative elements */
}

body {
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 16px;
    line-height: 1.65;
    color: var(--text-dark);
    background: var(--bg-light);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;   /* belt-and-suspenders: kills any horizontal overflow */
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 500;
    line-height: 1.3;
    margin-top: 0;
    color: var(--text-dark);
}

a { color: var(--primary); transition: color 0.2s; }
a:hover { color: var(--primary-dark); }

img { max-width: 100%; height: auto; }

/* ----- Navbar ----- */
.site-nav {
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.site-nav .brand-logo {
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: -0.3px;
    display: flex;
    align-items: center;
    gap: 6px;
    /* ensure img logos are not clipped */
    padding: 8px 0;
    height: 56px;
    line-height: normal;
}
.site-nav .brand-logo img,
.site-logo img {
    max-height: 40px;
    width: auto;
    object-fit: contain;
    display: block;
}
.site-nav .nav-link { font-weight: 500; }
.site-nav .nav-search-form { margin: 0; }
.site-nav .nav-search-field { margin: 0; height: 56px; display: flex; align-items: center; }
.site-nav .nav-search-field input {
    border: none !important;
    border-bottom: 2px solid rgba(255,255,255,0.5) !important;
    color: #fff !important;
    width: 180px;
    transition: width 0.3s;
}
.site-nav .nav-search-field input::placeholder { color: rgba(255,255,255,0.7); }
.site-nav .nav-search-field input:focus { width: 220px; border-bottom-color: #fff !important; box-shadow: none !important; }

/* Search dropdown */
.search-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    width: 320px;
    z-index: 999;
    max-height: 400px;
    overflow-y: auto;
    display: none;
    border-radius: var(--radius);
}
.search-dropdown.visible { display: block; }
.search-result-item {
    padding: 10px 16px;
    cursor: pointer;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 10px;
}
.search-result-item:hover { background: var(--primary-xlight); }
.search-result-item:last-child { border: none; }
.search-result-label { font-weight: 500; font-size: 0.9rem; }
.search-result-sub { font-size: 0.78rem; color: var(--text-medium); }

/* Sidenav brand */
.sidenav-brand {
    background: var(--primary);
    padding: 20px 16px;
}
.sidenav-brand .brand-text { font-size: 1.2rem; font-weight: 700; }

/* Dropdown content */
.dropdown-content { min-width: 220px; border-radius: var(--radius); }
.dropdown-content li a { padding: 8px 16px; font-size: 0.9rem; }

/* Remove black outline/border that appears on nav dropdown triggers when clicked */
nav ul li a.dropdown-trigger,
nav ul li a.dropdown-trigger:focus,
nav ul li a.dropdown-trigger:active {
    outline: none !important;
    box-shadow: none !important;
    border: none !important;
}

/* ----- Hero Section ----- */
.hero-section {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 60%, #26A69A 100%);
    padding: 48px 0 64px;
    color: #fff;
    position: relative;
    overflow: visible;
    min-height: 380px;
}
/* Decorative circle via clip on pseudo-element instead of overflow:hidden on parent */
.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
    pointer-events: none;
    overflow: hidden;
}

/* Materialize dropdown ul MUST be above hero content — ensure high z-index */
.hero-section .select-dropdown.dropdown-content {
    position: absolute !important;
    z-index: 9999 !important;
    max-height: 280px;
    overflow-y: auto;
}
.hero-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 10px;
    line-height: 1.2;
}
.hero-subtitle {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.88);
    margin-bottom: 32px;
    font-weight: 300;
}

/* ----- Calculator Card ----- */
.calculator-card {
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.18);
    border-top: 4px solid var(--accent);
    overflow: visible;
    position: relative;
    z-index: 10;
}
.calculator-card .card-content { padding: 28px; }
.calc-direction-tabs { margin-bottom: 20px; }
.calc-direction-tabs .direction-btn {
    border: 2px solid var(--border);
    border-radius: 20px;
    padding: 6px 18px;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.9rem;
    background: #fff;
    color: var(--text-medium);
    transition: all 0.2s;
    margin-right: 8px;
}
.calc-direction-tabs .direction-btn.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.calc-row { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
.calc-row .input-field { flex: 1; min-width: 180px; }
.calc-row .input-field label { font-weight: 500; }

.calc-result {
    background: var(--primary-xlight);
    border: 2px solid var(--primary-light);
    border-radius: var(--radius);
    padding: 18px 20px;
    margin-top: 20px;
    min-height: 70px;
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
}
.calc-result.has-result { background: var(--primary-xlight); }
.calc-result.error { background: #FFEBEE; border-color: #EF9A9A; }
.calc-result-text {
    flex: 1;
    font-size: 1.15rem;
    font-weight: 500;
    color: var(--primary-dark);
}
.calc-result-text .result-number {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--primary);
}
.calc-result-fraction { font-size: 0.9rem; color: var(--text-medium); margin-top: 2px; }
.calc-result-placeholder { color: var(--text-light); font-size: 0.95rem; font-weight: 400; }
.calc-copy-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--primary);
    padding: 4px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    opacity: 0.7;
    transition: opacity 0.2s;
}
.calc-copy-btn:hover { opacity: 1; }
.calc-actions { margin-top: 16px; display: flex; gap: 8px; flex-wrap: wrap; }
.swap-btn {
    background: var(--primary-xlight) !important;
    color: var(--primary) !important;
    border-radius: 50% !important;
    width: 40px !important;
    height: 40px !important;
    padding: 0 !important;
    min-width: 0 !important;
}

/* ----- Section Titles ----- */
.section-title {
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 6px;
}
.section-subtitle {
    color: var(--text-medium);
    font-size: 0.97rem;
    margin-bottom: 24px;
}
.section-divider {
    border: none;
    border-top: 2px solid var(--primary-xlight);
    margin: 40px 0;
}

/* ----- Popular Conversions ----- */
.popular-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0; }
.popular-chip, .related-chip {
    display: inline-flex;
    align-items: center;
    background: var(--bg-white);
    border: 1.5px solid var(--primary-light);
    color: var(--primary);
    border-radius: 20px;
    padding: 4px 14px;
    font-size: 0.88rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s;
}
.popular-chip:hover, .related-chip:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    box-shadow: 0 2px 8px rgba(0,137,123,0.25);
}
.chip-current {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

/* ----- Ingredient Cards ----- */
.ingredients-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
@media (max-width: 992px) { .ingredients-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 768px)  { .ingredients-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px)  { .ingredients-grid { grid-template-columns: 1fr; } }

.ingredient-card {
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    background: var(--bg-white);
    padding: 16px;
    text-decoration: none;
    color: var(--text-dark);
    display: block;
    transition: transform 0.2s, box-shadow 0.2s;
    border-left: 3px solid var(--primary-light);
}
.ingredient-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--card-shadow-hover);
    color: var(--text-dark);
}
.ingredient-card .ing-icon {
    font-size: 1.8rem;
    margin-bottom: 8px;
    display: block;
}
.ingredient-card .ing-name { font-weight: 600; font-size: 0.95rem; margin-bottom: 4px; }
.ingredient-card .ing-density { font-size: 0.8rem; color: var(--text-medium); }
.ingredient-card .ing-cat { font-size: 0.75rem; color: var(--text-light); }

/* ----- Conversion Table ----- */
.table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: var(--radius); }
.conversion-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--card-shadow);
}
.conversion-table thead th {
    background: var(--primary);
    color: #fff;
    padding: 12px 16px;
    font-weight: 600;
    font-size: 0.88rem;
    text-align: left;
    white-space: nowrap;
}
.conversion-table tbody tr:nth-child(even) { background: var(--primary-xlight); }
.conversion-table tbody tr:hover { background: #B2DFDB; }
.conversion-table tbody td {
    padding: 10px 16px;
    font-size: 0.92rem;
    border-bottom: 1px solid var(--border);
}
.conversion-table tbody tr.highlighted-row td {
    background: #FFECB3;
    font-weight: 600;
}
.conversion-table tfoot td {
    padding: 10px 16px;
    font-size: 0.82rem;
    color: var(--text-light);
    background: #FAFAFA;
}

/* ----- FAQ Section ----- */
.faq-collapsible { border: none !important; box-shadow: none !important; }
.faq-collapsible .collapsible-header {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 8px;
    font-weight: 500;
    padding: 14px 20px;
}
.faq-collapsible .collapsible-header.active {
    background: var(--primary-xlight);
    border-color: var(--primary-light);
    color: var(--primary-dark);
    border-radius: var(--radius) var(--radius) 0 0;
    margin-bottom: 0;
}
.faq-collapsible .collapsible-body {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-top: none;
    border-radius: 0 0 var(--radius) var(--radius);
    padding: 14px 20px;
    margin-bottom: 8px;
}

/* ----- Breadcrumb ----- */
.breadcrumb-nav {
    background: transparent;
    box-shadow: none;
    height: auto;
    padding: 10px 0 4px;
}
.breadcrumb-nav .nav-wrapper { background: transparent; padding: 0; }
.breadcrumb:before { color: var(--text-light); }
.breadcrumb, .breadcrumb a { color: var(--text-medium); font-size: 0.85rem; }
.breadcrumb.active { color: var(--text-dark); font-weight: 500; }

/* ----- Result Box (gram-ingredient page) ----- */
.result-box {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: 12px;
    padding: 28px 32px;
    color: #fff;
    text-align: center;
    margin: 24px 0;
    box-shadow: 0 4px 16px rgba(0,137,123,0.3);
}
.result-box .result-label { font-size: 1.05rem; opacity: 0.9; margin-bottom: 8px; }
.result-box .result-value { font-size: 3rem; font-weight: 700; line-height: 1; }
.result-box .result-unit  { font-size: 1.2rem; opacity: 0.85; }
.result-box .result-fraction { font-size: 1.1rem; opacity: 0.8; margin-top: 6px; }
.result-box .result-formula { font-size: 0.85rem; opacity: 0.75; margin-top: 10px; font-family: monospace; }

/* ----- Info Cards ----- */
.info-card {
    border-radius: var(--radius);
    background: var(--bg-white);
    box-shadow: var(--card-shadow);
    padding: 20px 24px;
    margin-bottom: 16px;
    border-left: 4px solid var(--primary);
}
.info-card h5 { font-size: 1rem; font-weight: 600; margin-bottom: 6px; }
.info-card p  { font-size: 0.9rem; color: var(--text-medium); margin: 0; }

/* ----- Tool Cards ----- */
.tool-cards-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; }
@media (max-width: 992px) { .tool-cards-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 480px)  { .tool-cards-grid { grid-template-columns: 1fr; } }

.tool-card {
    border-radius: var(--radius);
    background: var(--bg-white);
    box-shadow: var(--card-shadow);
    padding: 20px;
    text-align: center;
    text-decoration: none;
    color: var(--text-dark);
    display: block;
    transition: transform 0.2s, box-shadow 0.2s;
}
.tool-card:hover { transform: translateY(-3px); box-shadow: var(--card-shadow-hover); color: var(--text-dark); }
.tool-card .tool-icon { font-size: 2.2rem; color: var(--primary); margin-bottom: 8px; }
.tool-card .tool-name { font-weight: 600; font-size: 0.9rem; }

/* ----- Category Cards ----- */
.category-cards-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }
@media (max-width: 768px) { .category-cards-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 480px) { .category-cards-grid { grid-template-columns: 1fr; } }

.category-card {
    border-radius: var(--radius);
    padding: 20px;
    text-align: center;
    text-decoration: none;
    display: block;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: var(--card-shadow);
}
.category-card:hover { transform: translateY(-3px); box-shadow: var(--card-shadow-hover); }

/* ----- SEO Content ----- */
.seo-content h2 { font-size: 1.35rem; font-weight: 600; margin-top: 28px; margin-bottom: 10px; }
.seo-content h3 { font-size: 1.1rem; font-weight: 600; margin-top: 20px; color: var(--primary-dark); }
.seo-content p  { color: var(--text-medium); line-height: 1.7; }
.seo-content ul { padding-left: 24px; }
.seo-content ul li { color: var(--text-medium); margin-bottom: 4px; }
.seo-content a  { color: var(--primary); text-decoration: none !important; }
.seo-content a:hover { text-decoration: none !important; }

/* ----- Related Links ----- */
.related-links-card { border-radius: var(--radius); }
.related-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

/* ----- Search ----- */
.search-page-box { max-width: 600px; margin: 0 auto 32px; position: relative; }
.search-page-box input { font-size: 1.1rem; padding-right: 48px; }
.search-results-list { list-style: none; padding: 0; }
.search-result-li {
    background: var(--bg-white);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    margin-bottom: 12px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.search-result-li:hover { box-shadow: var(--card-shadow-hover); }
.search-result-li a { text-decoration: none; color: var(--text-dark); flex: 1; }
.search-result-li .sr-title { font-weight: 600; }
.search-result-li .sr-sub { font-size: 0.85rem; color: var(--text-medium); }
.search-result-type-badge {
    background: var(--primary-xlight);
    color: var(--primary-dark);
    font-size: 0.75rem;
    font-weight: 500;
    padding: 2px 10px;
    border-radius: 12px;
}

/* ----- 404 Page ----- */
.page-404 { text-align: center; padding: 60px 20px; }
.page-404 .error-code { font-size: 8rem; font-weight: 700; color: var(--primary-light); line-height: 1; }
.page-404 h1 { font-size: 2rem; margin-bottom: 12px; }
.page-404 p  { color: var(--text-medium); font-size: 1.05rem; }
.page-404 .search-404 { max-width: 400px; margin: 28px auto; }

/* ─── Cookie Consent Popup Card ─────────────────────────────────────────── */
.cookie-popup {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 320px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.18), 0 2px 8px rgba(0,0,0,0.10);
    z-index: 10000;
    padding: 24px 22px 20px;
    box-sizing: border-box;
    border-top: 3px solid #00897B;
}
.cookie-popup-icon {
    font-size: 1.6rem;
    margin-bottom: 10px;
    line-height: 1;
}
.cookie-popup-title {
    font-size: 1rem;
    font-weight: 700;
    color: #1A2E35;
    margin: 0 0 10px;
    line-height: 1.3;
}
.cookie-popup-text {
    font-size: 0.83rem;
    color: #546E7A;
    line-height: 1.55;
    margin: 0 0 18px;
}
.cookie-popup-link {
    color: #00897B;
    font-weight: 600;
    text-decoration: underline !important;
    white-space: nowrap;
}
.cookie-popup-actions {
    display: flex;
    gap: 10px;
}
.btn-cookie-accept {
    flex: 1;
    background: #00897B;
    color: #fff !important;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0 16px;
    height: 38px;
    line-height: 38px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    text-align: center;
    transition: background 0.2s;
    white-space: nowrap;
}
.btn-cookie-accept:hover { background: #00695C; }
.btn-cookie-decline {
    flex: 1;
    background: #fff;
    color: #546E7A !important;
    font-size: 0.82rem;
    font-weight: 500;
    padding: 0 12px;
    height: 38px;
    line-height: 36px;
    border-radius: 6px;
    border: 1.5px solid #CFD8DC;
    cursor: pointer;
    text-align: center;
    transition: border-color 0.2s, color 0.2s;
    white-space: nowrap;
}
.btn-cookie-decline:hover { border-color: #90A4AE; color: #37474F !important; }

/* Mobile — center at bottom, full width minus margins */
@media (max-width: 480px) {
    .cookie-popup {
        bottom: 12px;
        right: 12px;
        left: 12px;
        width: auto;           /* stretch between left/right */
        padding: 20px 16px 16px;
        border-radius: 10px;
    }
    .cookie-popup-icon { font-size: 1.3rem; margin-bottom: 8px; }
    .cookie-popup-title { font-size: 0.95rem; }
    .cookie-popup-text { font-size: 0.8rem; margin-bottom: 14px; }
    .btn-cookie-accept,
    .btn-cookie-decline { height: 36px; line-height: 34px; font-size: 0.79rem; }
}


/* ----- Footer ----- */
.page-footer { color: #CFD8DC; }
.footer-heading {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 6px; }
.footer-links a { font-size: 0.9rem; transition: color 0.2s; }
.footer-links a:hover { color: #fff !important; }
.social-links { display: flex; gap: 12px; margin-top: 10px; }
.social-links a { font-size: 1.4rem; }
.footer-copyright { padding: 12px 0; font-size: 0.85rem; }

/* ----- How it Works section ----- */
.how-it-works-steps { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; }
@media (max-width: 768px) { .how-it-works-steps { grid-template-columns: 1fr; } }
.step-card {
    background: var(--bg-white);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    padding: 22px;
    text-align: center;
}
.step-number {
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.1rem;
    margin: 0 auto 12px;
}
.step-card h4 { font-size: 1rem; font-weight: 600; margin-bottom: 6px; }
.step-card p  { font-size: 0.88rem; color: var(--text-medium); }

/* ----- Gram Highlight ----- */
.gram-highlight { color: var(--primary); font-weight: 700; }

/* ----- Sections spacing ----- */
.content-section { padding: 48px 0; }
.content-section:nth-child(even) { background: var(--bg-white); }

/* ----- Materialize overrides ----- */
.btn { border-radius: 6px; font-weight: 500; letter-spacing: 0.5px; }
.btn.teal { background-color: var(--primary) !important; }
.btn.teal:hover { background-color: var(--primary-dark) !important; }
.card { border-radius: var(--radius); box-shadow: var(--card-shadow); }
.card:hover { box-shadow: var(--card-shadow-hover); }
input:not([type]):focus:not([readonly]),
input[type=text]:not(.browser-default):focus:not([readonly]),
input[type=number]:not(.browser-default):focus:not([readonly]),
textarea.materialize-textarea:focus:not([readonly]) {
    border-bottom-color: var(--primary) !important;
    box-shadow: 0 1px 0 0 var(--primary) !important;
}
input:not([type]):focus:not([readonly]) + label,
input[type=text]:not(.browser-default):focus:not([readonly]) + label,
input[type=number]:not(.browser-default):focus:not([readonly]) + label,
textarea.materialize-textarea:focus:not([readonly]) + label {
    color: var(--primary) !important;
}
.input-field .prefix.active { color: var(--primary); }
.select-wrapper input.select-dropdown:focus { border-bottom-color: var(--primary) !important; }
.dropdown-content li > a, .dropdown-content li > span { color: var(--text-dark); }
.collapsible-header:focus { background: var(--primary-xlight); }

/* ----- Ingredient category color coding ----- */
.cat-baking      { border-left-color: #F4511E; }
.cat-sweeteners  { border-left-color: #E67C73; }
.cat-dairy       { border-left-color: #5484ED; }
.cat-grains      { border-left-color: #F6BF26; }
.cat-fruits      { border-left-color: #33B679; }
.cat-vegetables  { border-left-color: #0B8043; }
.cat-oils        { border-left-color: #8E24AA; }
.cat-nuts        { border-left-color: #795548; }
.cat-other       { border-left-color: #78909C; }

/* ----- Responsive utilities ----- */
.hide-on-tiny { }
@media (max-width: 360px) {
    .hide-on-tiny { display: none; }
    .hero-title  { font-size: 1.7rem; }
}

/* ----- Print ----- */
@media print {
    .site-nav, .cookie-bar, .page-footer, .breadcrumb-nav, .calc-actions, #calculator { display: none; }
    body { background: #fff; color: #000; font-size: 12pt; }
    .conversion-table { box-shadow: none; }
}

/* ─── Materialize Select Dropdown Fix ────────────────────────────────────────
   Materialize appends dropdown <ul> to <body>.
   Without this fix, the hero section jumps/collapses when the dropdown opens
   because the <ul> is relatively positioned inside a parent with overflow:hidden.
   Solution: ensure the dropdown is always fixed above everything.
   ──────────────────────────────────────────────────────────────────────────── */
.select-dropdown.dropdown-content {
    z-index: 9999 !important;
    max-height: 320px;
    overflow-y: auto;
}
/* Prevent input wrapper from expanding when dropdown opens */
.input-field .select-wrapper + .dropdown-content,
.input-field + .dropdown-content {
    margin-top: 0;
}
/* Fix: the Materialize wrapper div should not grow taller than the input */
.select-wrapper {
    position: relative;
}
