:root {
    --nav-height: 4rem;
}

.title {
    font-size: 1.75rem;        
    font-weight: 700;         
    letter-spacing: -0.025em;  
    line-height: 2.5rem;       
    margin-bottom: 0.5rem;    
    color: #0f172a;          
}

/* prose content */

.prose-content h1, .prose-content .h1-title {
    font-family: var(--heading-font);
    font-size: clamp(1.07rem, 8vw, 1.13rem); 
    line-height: 1.1;
    font-weight: 600;
    padding-bottom: 0.25rem;
}

.prose-content h2, .prose-content .h2-title {
    font-size: clamp(1.01rem, 5vw, 1.06rem);
    font-weight: 500;
}

.prose-content h1 {
    margin-bottom: 0.75rem;
}

.prose-content h2 {
    margin-top: 2rem;
    margin-bottom: 0.5rem;
}

.prose-content p {
    margin-bottom: 1rem;
}

.icon-success {
    color: #388E3C;
}

.success-check-icon {
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    display: inline-block;
    color: rgb(56, 142, 60);
}
/* nav bar */

.sticky-nav {
    width: 100%;
    height: var(--nav-height);
    display: flex;
    flex-shrink: 0;
    align-items: center;
}

.logo {
    padding-right: 0;
    padding-top: 0.0025rem;
    font-size: 1.45rem;
    line-height: 1.75rem;
    font-family: 'Plus Jakarta Sans';
    font-weight: 700;
    letter-spacing: -0.025em;
    display: flex;
    text-decoration: none;
}

.nav-container {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex: 1;
    justify-content: space-between;
    padding: 0 1.5rem;
    position: relative;
    height: 56px;
}




.nav-right-container {
    display: flex;
    gap: 0.5rem;
}

.mobile-trigger { 
    display: flex; 
    background: none; 
    border: none; 
    font-size: 1.1rem;
    cursor: pointer;
    padding: 8px 0;
    color: #475569;
    flex-direction: row;
    flex: 1;
    justify-content: space-between;
}

.icon-btn {
    border: none;
    color: #475569;
    background: none;
}

    
.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;
}

.compare-icon {
    display: inline-flex;
}

.compare-label {
    display: none;
}

.paste-btn {
    border: none;
    background: none;
    color: #475569;
}

.search-history {
    position: absolute;
    top: 3.25rem;
    left: 0;
    width: 100%;
    background: white;
    border-bottom: 1px solid #f1f5f9;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
    padding: 1rem;
    display: none;
}

#searchInput:focus + .search-history, 
.search-history:active {
    display: block;
}



.fa-magnifying-glass {
    font-size: 0.875rem; 
    padding-top: 0.1rem;
    font-weight: 900; 
}

.compare-btn { 
    display: flex; 
    align-items: center; 
    gap: 6px; 
    /* padding: 0 10px;  */
    height: 32px; 
    background: transparent; 
    border: none; 
    cursor: pointer; 
    font-weight: 500; 
    white-space: nowrap; 
    border-radius: var(--radius); 
}

.compare-mobile-btn {
    font-size: 1.1rem; 
    line-height: inherit;
}

.compare-btn:hover { 
    background: var(--bg-accent); 
}

.icon-btn { 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    width: 34px; 
    height: 34px; 
    border-radius: var(--radius); 
    border: none; 
    background: transparent; 
    cursor: pointer; 
    color: var(--color-icon); 
    font-size: 20px; 
}

.icon-btn:hover { 
    background: var(--surface-1); 
}

.nav-link,
.a.nav-link {
    display: flex;
    gap: 1.25rem;
    align-items: center;
}

.nav-link-group {
    color: #475569;    
}



.modal-crop-container {
    max-width: 100%;
    max-height: 60vh; 
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

#imagePreview {
    max-width: 100%;
    display: block;
}

.drawer-btn {
    display: none;
}

.drawer {
    position: fixed;
    top: 0;
    right: 0;
    height: 100dvh;
    overflow: hidden;
    background-color: #fff;
    z-index: 50;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
    transition: transform 0.5s cubic-bezier(0.32, 0.72, 0, 1);
    transform: translateX(100%);
    width: 100%;
}

.scan-pill-label {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border: 0.5px solid var(--color-border-tertiary);
    border-radius: 20px;
    cursor: pointer;
    font-size: 12px;
    color: var(--color-text-secondary);
    background: var(--color-background-secondary);
    width: fit-content;
}

.scan-pill-label:hover {
    border-color: var(--color-border-secondary);
    color: var(--color-text-primary);
}

.scan-pill-label svg {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

.scan-pill-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.scan-pill-hint {
    font-size: 12px;
    color: var(--color-text-tertiary);
}

.drawer-body::-webkit-scrollbar {
    display: none;
}

.drawer-body {
    -ms-overflow-style: none;
    scrollbar-width: none;
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    flex-grow: 1;
    padding: 0.5rem 2rem 5rem 2rem;
    display: flex;
    flex-direction: column;
}

.drawer.active { transform: translateX(0); }

/* Drawer Interior */
.drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid #f8fafc;
    flex-shrink: 0;
}

.back-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #475569;
    background: none;
    border: none;
    cursor: pointer;
}

.icon-w6 { width: 1.5rem; height: 1.5rem; }

.back-text, .label-caps, .clear-btn {
   
    font-weight: 500;
    letter-spacing: 0.025rem;
}

.back-link:hover {
    color: #0F172A;
}

input#sc_product_title {
    border: 1px solid #E2E8F0;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    width: 100%;
}

.product-title {
    /* margin-top: 1rem; */
    margin-bottom: 0.5rem;
}

.product-title:invalid {
    box-shadow: none;
    background-color: #ffffff;
}

.product-title:focus, input#sc_product_title:hover, input#sc_product_title:focus  { 
    border-color: #cbd5e1; 
    outline: none;
}

.cant-scan {
    position: relative;
    display: flex;
    align-items: center;
    padding-top: 0.75rem;
    padding-bottom: 1rem;
    margin-bottom: 0.5rem;
}

.drawer-input {
    flex: 1;
    width: 100%;
    font-weight: 300;
    border: 1px solid #E2E8F0;
    border-radius: 8px;
    outline: none;
    resize: none;
    padding: 0.75rem 1rem;
    overflow-y: auto; 
    min-height: 150px;
    max-height: 400px;
    scrollbar-width: thin;
    margin-top: 0.7rem;
}

/* 1. Base / Inactive State (Matches .back-link color: #475569) */
.compare-btn, 
.compare-nav-btn, 
.drawer-btn,
.back-link {
    color: #475569;
    opacity: 1;
    text-decoration: none;
    transition: color 0.15s ease;
}

/* 2. Hover State (Matches .back-link:hover color: #0F172A) */
.compare-btn:hover, 
.compare-nav-btn:hover, 
.drawer-btn:hover,
.back-link:hover {
    color: #0F172A;
}

/* 3. Active / Current Page State (Matches active/clicked color: #0F172A) */
.compare-btn.is-active, 
.compare-nav-btn.is-active, 
.drawer-btn.is-active,
.compare-btn.active, 
.compare-nav-btn.active, 
.drawer-btn.active {
    color: #0F172A;
    font-weight: 600;
    margin: 0;
}

.drawer-input:hover, .drawer-input:focus {
    border: 1px solid #CBD5E1;
}

.drawer-input::-webkit-scrollbar {
    width: 6px;
}

.drawer-input::-webkit-scrollbar-thumb {
    background-color: #e2e8f0; 
    border-radius: 8px;
}

.drawer-input::placeholder, input#sc_product_title::placeholder {
    color: #cbd5e1;
    opacity: 1;
}

.drawer-footer {
    padding-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.clear-btn {
    background: none;
    border: none;
    font-weight: 500;
    letter-spacing: 0.025rem;
    cursor: pointer;
    color: #475569;
}

.clear-btn:hover {
    color: #0F172A;
}

.overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.1);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s;
    z-index: 90;
}

.overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.paste-container {
    display: flex;
    justify-content: flex-end;
    width: 100%;
    margin-top: 0.5rem;
    bottom: 0;
}

#analyze-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    height: 2.75rem;
    width: 2.75rem;  
    margin-top: 0.75rem;
    background-color: #94A3B8; 
    border-radius: 0.75rem; 
    border: none;
    cursor: pointer;
    transition-property: all;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 150ms;
}

.paste-container .fa-magnifying-glass {
    color: white;
    align-items: center;
    margin-left: 0.25rem;
}

#analyze-btn i {
    font-size: 0.875rem; 
    line-height: 1.25rem;
}

.flex.justify-end {
    display: flex;
    justify-content: flex-end;
}

#analyze-btn:focus,
#analyze-btn:focus-within {
    outline: 2px solid transparent;
    outline-offset: 2px;
    border-color: #64748b; 
    box-shadow: 0 0 0 1px rgba(100, 116, 139, 0.1); 
}

.error-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    text-align: center;
    gap: 1rem;
}

.error-page h1 {
    font-size: 4rem;
    font-weight: 700;
    color: #0F172A;
}

.error-page p {
    font-size: 1rem;
    color: #64748b;
}

.error-page a {
    font-size: 0.9rem;
    color: #0F172A;
    text-decoration: underline;
}

@media (min-width: 767px) {

    .nav-right-container .mobile-trigger,
    .nav-right-container .paste-btn, 
    .nav-right-container .compare-mobile-btn { 
        display: none; 
    }

    .nav-container .nav-brand-group {
        display: flex;
        align-items: center;
        width: 90%;         
        gap: 1.5rem;      
    }

    .nav-container {
        margin-left: 0.0125rem;
        margin-right: auto;
        margin-top: 0.3rem;
        margin-bottom: 0.3rem;
        height: 3rem; 
        display: flex;
        flex: 1;
        align-items: center;
        justify-content: space-between;
    }

    .logo {
        margin-left: 1.5rem;
        margin-right: 1rem;
    }

    .icon-btn, .paste-btn {
        display: none;
    }

    .compare-icon {
        display: none;
    }

    .compare-label {
        display: inline;
    }

    
    .nav-link, .drawer-btn, .compare-btn {
        text-decoration: none;  
        transition: color 0.2s ease; 
        list-style: none;      
        cursor: pointer;
        font-weight: 500;       
        border: none;
        background: none;
        letter-spacing: 0.025rem;
        margin-right: 0.5rem;
        display: inline-flex;
        align-items: center;
        white-space: nowrap;  
        width: auto;   
        color: #0F172A; 
        opacity: 0.75;  
        font-size: 0.91rem;    
    }


    .drawer { 
        width: 450px; 
    } 

}

/* skin concern tab start */

.concern-btn {
    border: 1px solid var(--unselect-btn);
    color: #475569; 
    background: var(--unselect-btn);
    padding: 7px 16px 8px 16px;
    cursor: pointer;
    border-radius: 20px;
    transition: 0.3s;
    margin-top: 0.5rem;
}

.concern-btn.active {
    border: none;
    color: #003595;
    font-weight: 500;
    background: var(--signature-pale-blue);
    border: 1px solid var(--signature-pale-blue);

    /* Add these two lines */
    pointer-events: none; 
    cursor: default;
}

.concern-selection {
    color: #475569;
    margin-bottom: 0.75rem;
    margin-top: 2rem;
}

/* AJAX error */

.si-notice {
    position: relative;                 
    display: inline-flex;
    margin-top: 2rem;
    border-radius: 0.375rem;        
    border: 1px solid #e2e8f0;      
    background-color: #f8fafc;     
    padding: 1rem;            
    color: #475569;                 
    line-height: 1.25rem;
    width: fit-content;
}
.si-notice span {
    padding-right: 0.75rem;
}
.si-x-btn {
    margin-left: 0.25rem;        
    color: #94a3b8;            
    font-size: 1.125rem;       
    font-weight: 700;      
    top: 0.5rem;
    right: 0.5rem;   
    border: none;      
}

/* Hover state */
.si-x-btn:hover {
    color: #475569;            
}

/* Focus state */
.si-x-btn:focus {
    outline: none;            
}

/* trial start */
/* Navbar Base Styles */
.sticky-nav {
    position: sticky;
    top: 0;
    background: #ffffff;
    border-bottom: 1px solid #f1f5f9;
    z-index: 10;
}


.sticky-nav .logo {
    font-weight: 700;
    font-size: 1.125rem;
    text-decoration: none;
    color: #003595;
}

/* Action Group (Compare & Check List) */
.nav-link-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.compare-btn, .compare-nav-btn, .drawer-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;

}

/* Hide text labels on mobile default view */
.compare-label, .drawer-label {
    display: none;
}

/* ----------------------------------
   MOBILE COLLAPSED STATE
----------------------------------- */
.nav-search-toggle,
.nav-search-back {
    display: flex;
    align-items: center;
    justify-content: center;
    /* width: 36px; */
    height: 36px;
    border: none;
    background: transparent;
    
    cursor: pointer;
    padding: 0;
}

.nav-search-back {
    display: none; /* Hide back arrow when collapsed */
}

/* Container acts only as a positioning wrapper */
.nav-search-field {
    position: relative;
    display: none;
    align-items: center;
    width: 100%;
    border: 1px solid #e2e8f0; 
    border-radius: 8px;
    background: #f8fafc;
}

/* 1. BEFORE (Default State) - Applied directly to the input */
.nav-search-input {
    width: 100%;
    height: 36px;
    padding: 0 10px 0 32px; /* Extra left padding for search icon */
    background: #ffffff;
    border-radius: 8px;
    font-size: 0.875rem;
    color: #0f172a;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

/* 2. AFTER (Focused State) - Standard :focus directly on the input */
.nav-search-input:focus {
    border-color: #cbd5e1; /* Active border color on focus */
    box-shadow: 0 0 0 1px #cbd5e1; /* Optional subtle focus ring */
}

/* Position search icon inside the input field */
.search-input-icon {
    position: absolute;
    left: 10px;
    color: #64748b;
    pointer-events: none; /* Allows clicks to pass through to the input */
    margin-right: 8px;
    flex-shrink: 0;
}

.nav-search-input {
    border: none;
    background: transparent;
    outline: none;
    width: 100%;
    font-size: 0.875rem;
    color: #0f172a;
}

.nav-search-input::placeholder {
    color: #94a3b8;
}

/* ----------------------------------
   MOBILE EXPANDED STATE (.active)
----------------------------------- */
.nav-search.active {
    position: absolute;
    inset: 0;
    background: #ffffff;
    z-index: 200;
    display: flex;
    align-items: center;
    padding: 0 1rem;
    gap: 12px;
}

.nav-search.active .nav-search-toggle {
    display: none; /* Hide magnifying icon */
}

.nav-search.active .nav-search-back {
    display: flex; /* Show back arrow */
}

.nav-search.active .nav-search-field {
    display: flex; /* Show full-width search bar */
    flex: 1;
}

/* ----------------------------------
   DESKTOP VIEW (min-width: 834px)
----------------------------------- */
@media (min-width: 834px) {
    .nav-search {
        position: static;
    }

    .nav-link-group .nav-icon {
        display: none;
    }

    /* Hide mobile toggle buttons on desktop */
    .nav-search-toggle,
    .nav-search-back {
        display: none;
    }

    /* Always show search input next to brand logo */
    .nav-search-field {
        display: flex;
        width: 18rem;
    }

    /* PUSHES ACTION BUTTONS ALL THE WAY TO THE FAR RIGHT */
    .nav-link-group {
        margin-left: auto;
    }

    /* Show action labels next to icons */
    .compare-label, .drawer-label {
        display: inline;
    }
}

/* trial end */

#cropModal { z-index: 100; /* or higher, e.g. 999 */ }


    