/* ============================================================
   Age Gate by Salman — styles
   Brand: NU Biolabs blue #005EB8 / accent #1E3A8A
   ============================================================ */

:root {
    --ags-primary: #005EB8;
    --ags-primary-dark: #1E3A8A;
    --ags-text: #0F172A;
    --ags-muted: #475569;
    --ags-border: #E2E8F0;
    --ags-card-bg: #FFFFFF;
    --ags-backdrop: rgba(13, 27, 42, 0.96);
    --ags-error-bg: #FEF2F2;
    --ags-error-text: #B91C1C;
    --ags-error-border: #FCA5A5;
}

/* ---------- Gate 1 (site entry) ---------- */
.ags-gate1[hidden] { display: none !important; }
.ags-gate1 {
    position: fixed; inset: 0;
    z-index: 2147483640;
    display: flex; align-items: center; justify-content: center;
    padding: 20px;
}
.ags-gate1__backdrop {
    position: absolute; inset: 0;
    background: var(--ags-backdrop);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.ags-gate1__card {
    position: relative;
    background: var(--ags-card-bg);
    border-radius: 12px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.45);
    width: 100%;
    max-width: 520px;
    padding: 40px 32px 28px;
    text-align: center;
    color: var(--ags-text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
.ags-gate1__logo { margin: 0 0 20px; }
.ags-gate1__logo img { max-width: 200px; max-height: 64px; height: auto; width: auto; }
.ags-gate1__title {
    font-size: 24px; font-weight: 700; margin: 0 0 12px; color: var(--ags-text); line-height: 1.25;
}
.ags-gate1__subtitle {
    font-size: 15px; line-height: 1.55; color: var(--ags-muted); margin: 0 0 22px;
}
.ags-gate1__challenge {
    font-size: 17px; font-weight: 600; margin: 0 0 22px; color: var(--ags-text);
}
.ags-gate1__buttons {
    display: flex; gap: 12px; justify-content: center; margin: 0 0 22px; flex-wrap: wrap;
}
.ags-gate1__fineprint {
    font-size: 12px; line-height: 1.55; color: var(--ags-muted); margin: 0;
}
.ags-gate1__fineprint a { color: var(--ags-primary); text-decoration: underline; }

/* ---------- Buttons (shared) ---------- */
.ags-btn {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 140px; padding: 12px 20px;
    border-radius: 8px; border: 1px solid transparent;
    font-size: 15px; font-weight: 600; cursor: pointer;
    transition: transform .08s ease, box-shadow .15s ease, background-color .15s ease;
    font-family: inherit;
}
.ags-btn:active { transform: translateY(1px); }
.ags-btn--yes, .ags-btn--primary {
    background: var(--ags-primary); color: #fff !important;
}
.ags-btn--yes:hover, .ags-btn--primary:hover {
    background: var(--ags-primary-dark);
    box-shadow: 0 6px 14px rgba(0, 94, 184, 0.3);
}
.ags-btn--no {
    background: #F1F5F9; color: #334155 !important; border-color: var(--ags-border);
}
.ags-btn--no:hover { background: #E2E8F0; }

/* ---------- Gate 2 (checkout) ---------- */
.ags-gate2 {
    margin: 24px auto;
    max-width: 520px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
.ags-gate2__card {
    background: var(--ags-card-bg);
    border: 1px solid var(--ags-border);
    border-radius: 12px;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.06);
    padding: 32px 28px;
    color: var(--ags-text);
}
.ags-gate2__logo { text-align: center; margin: 0 0 16px; }
.ags-gate2__logo img { max-width: 160px; max-height: 56px; height: auto; width: auto; }
.ags-gate2__title {
    text-align: center; font-size: 22px; font-weight: 700; margin: 0 0 8px; line-height: 1.3;
}
.ags-gate2__subtitle {
    text-align: center; font-size: 14px; color: var(--ags-muted); margin: 0 0 22px; line-height: 1.55;
}

.ags-tabs {
    display: grid; grid-template-columns: 1fr 1fr;
    background: #F1F5F9; border-radius: 10px; padding: 4px;
    margin: 0 0 20px;
}
.ags-tab {
    appearance: none; border: 0; background: transparent;
    padding: 10px 12px; border-radius: 8px;
    font-size: 14px; font-weight: 600; cursor: pointer;
    color: var(--ags-muted); font-family: inherit;
    transition: background-color .15s, color .15s;
}
.ags-tab.is-active { background: var(--ags-primary); color: #fff; }

.ags-error {
    background: var(--ags-error-bg);
    border: 1px solid var(--ags-error-border);
    color: var(--ags-error-text);
    padding: 10px 14px; border-radius: 8px; font-size: 14px;
    margin: 0 0 16px;
}

.ags-form { display: none; }
.ags-form.is-active { display: block; }
.ags-field { display: block; margin: 0 0 14px; }
.ags-field__label {
    display: block; font-size: 13px; font-weight: 600; color: var(--ags-text); margin: 0 0 6px;
}
.ags-field input {
    width: 100%; box-sizing: border-box;
    padding: 11px 12px; border: 1px solid var(--ags-border); border-radius: 8px;
    font-size: 15px; font-family: inherit; color: var(--ags-text); background: #fff;
}
.ags-field input:focus {
    outline: none; border-color: var(--ags-primary);
    box-shadow: 0 0 0 3px rgba(0, 94, 184, 0.18);
}
.ags-check {
    display: flex; gap: 10px; align-items: flex-start;
    font-size: 13px; color: var(--ags-text); line-height: 1.5;
    margin: 0 0 12px; cursor: pointer;
}
.ags-check input { margin-top: 3px; flex: 0 0 auto; accent-color: var(--ags-primary); }
.ags-form .ags-btn--primary { width: 100%; margin-top: 8px; }
.ags-fineprint {
    font-size: 12px; line-height: 1.55; color: var(--ags-muted); margin: 14px 0 0; text-align: center;
}
.ags-fineprint a { color: var(--ags-primary); text-decoration: underline; }

/* ---------- Gate 2 overrides ---------------------------------------------
   On the Gate 2 page the user is anonymous and there is no checkout to
   reach yet — suppress every cart UI so nothing covers the login/register
   form. Targets:
   - Elementor Pro Menu Cart widget (auto-opens a side drawer after
     add-to-cart and is what blocked the form during testing)
   - WooCommerce mini-cart blocks
   - Custom nubio-cart icon
   - Any body scroll-lock the drawer applied
-------------------------------------------------------------------------- */
body.ags-gate2-active .elementor-widget-woocommerce-menu-cart,
body.ags-gate2-active .elementor-menu-cart__wrapper,
body.ags-gate2-active .elementor-menu-cart__container,
body.ags-gate2-active .elementor-menu-cart__main,
body.ags-gate2-active .elementor-menu-cart__close-button,
body.ags-gate2-active .elementor-menu-cart__toggle,
body.ags-gate2-active .woocommerce-mini-cart,
body.ags-gate2-active .wc-block-mini-cart,
body.ags-gate2-active .nubio-menu-cart-item {
    display: none !important;
    visibility: hidden !important;
}
body.ags-gate2-active {
    overflow: auto !important;
    position: static !important;
}
body.ags-gate2-active .dialog-lightbox-widget,
body.ags-gate2-active .elementor-lightbox {
    display: none !important;
}

/* ---------- Mobile ---------- */
@media (max-width: 480px) {
    .ags-gate1__card { padding: 32px 22px 22px; }
    .ags-gate1__title { font-size: 20px; }
    .ags-btn { min-width: 120px; padding: 11px 16px; font-size: 14px; }
    .ags-gate2__card { padding: 24px 18px; }
}
