/* ==========================================================================
   PDF Reducer design system - sign in / register / password reset
   Split layout around Filament's own (accessible) form components.
   ========================================================================== */

.pr-auth {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    min-height: 100vh;
    min-height: 100dvh;
    font-family: var(--pr-font);
    color: var(--pr-text);
    background: var(--pr-bg);
}

.pr-auth__brand {
    display: none;
}

.pr-auth__panel {
    display: flex;
    flex-direction: column;
    padding: clamp(14px, 3vw, 28px);
}

.pr-auth__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.pr-auth__back {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-height: 44px;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--pr-text-2);
    text-decoration: none;
}

.pr-auth__back:hover {
    color: var(--pr-text);
}

.pr-auth__card {
    width: 100%;
    max-width: 440px;
    margin: auto;
    padding: clamp(22px, 5vw, 36px);
    border: 1px solid var(--pr-border);
    border-radius: var(--pr-radius-xl);
    background: var(--pr-surface);
    box-shadow: var(--pr-shadow);
}

.pr-auth-title {
    margin: 0 0 0.35rem;
    font-size: clamp(1.5rem, 1.2rem + 1.2vw, 1.9rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--pr-text);
}

.pr-auth-sub {
    margin: 0 0 1.5rem;
    color: var(--pr-text-2);
}

.pr-auth-error {
    margin-bottom: 1.25rem;
    padding: .85rem 1rem;
    border: 1px solid var(--pr-primary);
    border-radius: var(--pr-radius);
    color: var(--pr-primary-text);
    background: var(--pr-surface-2);
    font-size: .9375rem;
}

.pr-auth-divider {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    margin: 1.4rem 0;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--pr-text-3);
}

.pr-auth-divider::before,
.pr-auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--pr-border);
}

.pr-auth-google {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.7rem;
    width: 100%;
    min-height: 46px;
    padding: 0.55rem 1rem;
    border: 1px solid var(--pr-border-strong);
    border-radius: var(--pr-radius);
    background: var(--pr-surface);
    color: var(--pr-text);
    font-size: 0.9375rem;
    font-weight: 600;
    text-decoration: none;
    transition: background 140ms ease, border-color 140ms ease;
}

.pr-auth-google:hover {
    background: var(--pr-surface-3);
}

.pr-auth-switch {
    margin: 1.4rem 0 0;
    text-align: center;
    font-size: 0.9375rem;
    color: var(--pr-text-2);
}

.pr-auth-switch a {
    font-weight: 700;
    color: var(--pr-primary-text);
}

/* Brand panel (wide screens) */
@media (min-width: 960px) {
    .pr-auth {
        grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    }

    .pr-auth__brand {
        position: relative;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        padding: clamp(32px, 4vw, 56px);
        overflow: hidden;
        color: #fff;
        background:
            radial-gradient(70% 50% at 100% 0%, rgba(255, 255, 255, 0.18), transparent 70%),
            linear-gradient(160deg, #98190f 0%, #e02a1b 55%, #ff5a3c 100%);
    }

    .pr-auth__brand::after {
        content: '';
        position: absolute;
        inset: auto -20% -30% auto;
        width: 70%;
        aspect-ratio: 1;
        border-radius: 50%;
        background: radial-gradient(closest-side, rgba(255, 255, 255, 0.14), transparent);
        pointer-events: none;
    }

    .pr-brand--light {
        display: inline-flex;
        align-items: center;
        gap: 0.7rem;
        color: #fff;
        font-size: 1.35rem;
        font-weight: 800;
        text-decoration: none;
    }

    .pr-brand--light .pr-brand__logo {
        border-radius: 12px;
    }

    .pr-auth__pitch {
        position: relative;
        z-index: 1;
        max-width: 420px;
    }

    .pr-auth__pitch h2 {
        margin: 0 0 1.5rem;
        font-size: clamp(1.75rem, 1.2rem + 1.6vw, 2.5rem);
        font-weight: 800;
        line-height: 1.15;
        letter-spacing: -0.03em;
        color: #fff;
    }

    .pr-auth__pitch ul {
        display: grid;
        gap: 0.9rem;
        margin: 0;
        padding: 0;
        list-style: none;
    }

    .pr-auth__pitch li {
        display: flex;
        gap: 0.75rem;
        align-items: flex-start;
        font-size: 1rem;
        line-height: 1.5;
        color: rgba(255, 255, 255, 0.92);
    }

    .pr-auth__pitch li i {
        margin-top: 0.25em;
        color: #fff;
    }

    .pr-auth__legal {
        position: relative;
        z-index: 1;
        margin: 0;
        font-size: 0.875rem;
        color: rgba(255, 255, 255, 0.75);
    }
}

/* Tune Filament's own controls to the brand without replacing them */
.pr-auth .fi-input-wrp {
    border-radius: var(--pr-radius);
}

.pr-auth .fi-btn {
    min-height: 46px;
    border-radius: var(--pr-radius);
    font-weight: 700;
}

.pr-auth .fi-fo-field-wrp-label span {
    font-weight: 600;
}

@media (prefers-reduced-motion: reduce) {
    .pr-auth * {
        transition-duration: 0.01ms !important;
    }
}

/* The language switcher plugin is position: fixed with no horizontal anchor
   (its own stylesheet relied on a script we no longer need): tuck it into the
   top bar, next to the theme button. */
.fls-display-on {
    inset-inline-start: auto;
    inset-inline-end: calc(clamp(14px, 3vw, 28px) + 52px);
    top: calc(clamp(14px, 3vw, 28px) + 4px);
    padding: 0;
}

.fls-display-on > div {
    background: transparent;
}
