/* ==========================================================================
   AI Trainers public-facing foundation
   Shared by the landing page and the auth pages. Layered on top of style.css
   (Bootstrap 5 + theme). Everything is namespaced `lp-` so it cannot leak into
   the signed-in app UI, which keeps the theme's own blue.
   ========================================================================== */

:root {
    /* Ink carries a violet cast rather than the neutral slate it used to, so
       the dark sections sit under the accent instead of fighting it. */
    --lp-ink: #0f0d1f;
    --lp-ink-raised: #191630;

    /* Accent. Violet reads as "AI" without borrowing the corporate blue every
       other platform in this space uses, and it leaves green free to mean
       money on the pay table. */
    --lp-accent: #6d5efc;
    --lp-accent-soft: #a99bff;
    --lp-accent-deep: #4c33e0;
    --lp-accent-wash: #f1eeff;

    --lp-line-dark: rgba(255, 255, 255, 0.11);
    --lp-line-light: #e3e0ef;
    --lp-ledger: #2ca87f;
    --lp-ink-text: #171430;
    --lp-body-text: #5c5975;
    --lp-mist: #8b88a3;
    --lp-dim: #b8b4cc;
    --lp-mono: ui-monospace, "SF Mono", SFMono-Regular, "Cascadia Mono", Menlo, Consolas, monospace;
}

/* --------------------------------------------------------------------------
   Accent override, scoped to the public pages only.

   The signed-in app keeps the theme's blue `--bs-primary`; these two body
   classes are the only places the violet takes over, so `btn-primary`,
   `link-primary` and `text-primary` follow the brand out here without the
   admin UI changing colour.
   -------------------------------------------------------------------------- */

body.landing-page,
body.auth-page {
    --bs-primary: #6d5efc;
    --bs-primary-rgb: 109, 94, 252;
    --bs-link-color: #6d5efc;
    --bs-link-color-rgb: 109, 94, 252;
    --bs-link-hover-color: #4c33e0;
}

body.landing-page .btn-primary,
body.auth-page .btn-primary {
    --bs-btn-bg: var(--lp-accent);
    --bs-btn-border-color: var(--lp-accent);
    --bs-btn-hover-bg: var(--lp-accent-deep);
    --bs-btn-hover-border-color: var(--lp-accent-deep);
    --bs-btn-active-bg: var(--lp-accent-deep);
    --bs-btn-active-border-color: var(--lp-accent-deep);
    --bs-btn-disabled-bg: var(--lp-accent);
    --bs-btn-disabled-border-color: var(--lp-accent);
    box-shadow: 0 10px 24px -12px rgba(76, 51, 224, 0.75);
}

body.landing-page .link-primary,
body.auth-page .link-primary,
body.landing-page .text-primary,
body.auth-page .text-primary {
    color: var(--lp-accent) !important;
}

body.landing-page .form-control:focus,
body.auth-page .form-control:focus,
body.landing-page .form-select:focus,
body.auth-page .form-select:focus {
    border-color: var(--lp-accent-soft);
    box-shadow: 0 0 0 3px rgba(109, 94, 252, 0.16);
}

body.landing-page .form-check-input:checked,
body.auth-page .form-check-input:checked {
    background-color: var(--lp-accent);
    border-color: var(--lp-accent);
}

/* --------------------------------------------------------------- typography */

.lp-display {
    font-size: clamp(2.35rem, 5.4vw, 4rem);
    font-weight: 800;
    letter-spacing: -0.035em;
    line-height: 1.04;
    color: #fff;
    margin: 0;
}

.lp-h2 {
    font-size: clamp(1.7rem, 3.1vw, 2.4rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.14;
    margin: 0;
}

.lp-h3 {
    font-size: 1.0625rem;
    font-weight: 700;
    letter-spacing: -0.012em;
    margin: 0;
}

.lp-lead {
    font-size: 1.0625rem;
    line-height: 1.72;
    max-width: 56ch;
    margin: 1.15rem 0 0;
}

.lp-label {
    font-family: var(--lp-mono);
    font-size: 0.6875rem;
    font-weight: 500;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.lp-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    margin-bottom: 1.15rem;
    color: var(--bs-primary);
}

.lp-eyebrow::before {
    content: "";
    width: 26px;
    height: 1px;
    background: currentColor;
    opacity: 0.65;
}

.lp-fine {
    margin: 1.25rem 0 0;
    color: var(--lp-mist);
    font-size: 0.8125rem;
    line-height: 1.6;
}

/* -------------------------------------------------------------------- ink */

.lp-ink {
    background: var(--lp-ink);
    color: var(--lp-dim);
}

.lp-ink h1,
.lp-ink h2,
.lp-ink h3,
.lp-ink h4,
.lp-ink strong {
    color: #fff;
}

/* The grid-and-glow backdrop used on the hero and the auth aside. Apply to a
   `position: relative; overflow: hidden` element and raise its children. */

.lp-grid::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(var(--lp-line-dark) 1px, transparent 1px),
        linear-gradient(90deg, var(--lp-line-dark) 1px, transparent 1px);
    background-size: 68px 68px;
    -webkit-mask-image: radial-gradient(115% 85% at 12% 0%, #000 0%, transparent 68%);
    mask-image: radial-gradient(115% 85% at 12% 0%, #000 0%, transparent 68%);
    opacity: 0.6;
    pointer-events: none;
}

.lp-grid::after {
    content: "";
    position: absolute;
    width: 780px;
    height: 780px;
    right: -230px;
    top: -300px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(109, 94, 252, 0.34), transparent 62%);
    pointer-events: none;
}

/* --------------------------------------------------------------------- logo */

.lp-logo {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    text-decoration: none;
    line-height: 1;
}

.lp-logo__mark {
    width: var(--lp-logo-size, 34px);
    height: var(--lp-logo-size, 34px);
    flex-shrink: 0;
}

.lp-logo__word {
    font-size: calc(var(--lp-logo-size, 34px) * 0.62);
    font-weight: 600;
    letter-spacing: -0.03em;
    color: var(--lp-logo-ink, #171430);
    transition: color 0.2s ease;
}

.lp-logo__word-accent {
    font-weight: 800;
    color: var(--lp-logo-accent, #6d5efc);
    transition: color 0.2s ease;
}

.lp-logo--light {
    --lp-logo-ink: #ffffff;
    --lp-logo-accent: #a99bff;
}

/* ------------------------------------------------------------------ buttons */

.lp-btn-ghost {
    color: #fff;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.26);
}

.lp-btn-ghost:hover,
.lp-btn-ghost:focus-visible {
    color: var(--lp-ink);
    background: #fff;
    border-color: #fff;
}

.lp-arrow {
    display: inline-block;
    transition: transform 0.18s ease;
}

.btn:hover .lp-arrow,
a:hover .lp-arrow {
    transform: translateX(4px);
}

/* ------------------------------------------------------------ a11y + motion */

.lp-skip {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 1200;
    padding: 0.75rem 1.25rem;
    background: #fff;
    color: #1d2630;
    border-radius: 0 0 10px 0;
}

.lp-skip:focus {
    left: 0;
}

@media (prefers-reduced-motion: reduce) {

    .lp-arrow,
    .lp-logo__word,
    .lp-logo__word-accent {
        transition: none;
    }
}
