/*
 * ERPSync - authentication pages (sign in, sign up, forgot / reset password, 2FA).
 * Used by resources/views/auth/layouts/modern.blade.php only.
 * Mobile first. Light + dark (prefers-color-scheme). Motion is transform/opacity only
 * and fully disabled under prefers-reduced-motion.
 */

.am-shell {
    --am-blue: #1565d8;
    --am-sky: #2ba8f7;
    --am-violet: #6d5dfc;
    --am-grad: linear-gradient(120deg, var(--am-blue) 0%, var(--am-sky) 55%, var(--am-violet) 100%);
    --am-ease: cubic-bezier(0.16, 1, 0.3, 1);

    --am-bg: #f4f7fd;
    --am-surface: rgba(255, 255, 255, 0.86);
    --am-surface-solid: #ffffff;
    --am-ink: #0b1b3a;
    --am-muted: #5b6b86;
    --am-line: rgba(15, 42, 92, 0.12);
    --am-input-bg: #fbfcff;
    --am-input-border: #d9e1ee;
    --am-link: #1565d8;
    --am-ring: rgba(43, 168, 247, 0.28);
    --am-danger: #d93a47;
    --am-success: #0f9d74;
    --am-shadow: 0 1px 2px rgba(11, 27, 58, 0.04), 0 24px 60px -24px rgba(21, 60, 140, 0.28);

    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    min-height: 100vh;
    min-height: 100dvh;
    background: var(--am-bg);
    color: var(--am-ink);
    font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    font-size: 15px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

@media (prefers-color-scheme: dark) {
    .am-shell {
        --am-bg: #0a1120;
        --am-surface: rgba(17, 26, 46, 0.82);
        --am-surface-solid: #111a2e;
        --am-ink: #e7eefa;
        --am-muted: #9aabc6;
        --am-line: rgba(148, 163, 184, 0.18);
        --am-input-bg: #0d1628;
        --am-input-border: #26344f;
        --am-link: #6cb8ff;
        --am-ring: rgba(108, 184, 255, 0.32);
        --am-danger: #ff6b76;
        --am-success: #34d399;
        --am-shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 24px 60px -24px rgba(0, 0, 0, 0.7);
    }
}

html, body { background: #f4f7fd; }
@media (prefers-color-scheme: dark) { html, body { background: #0a1120; } }

.am-shell *, .am-shell *::before, .am-shell *::after { box-sizing: border-box; }
.am-shell a { text-decoration: none; }

/* ── Brand panel ─────────────────────────────────────────────────────────── */
.am-brand {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    color: #fff;
    background: linear-gradient(140deg, #0e3d9e 0%, var(--am-blue) 38%, #1f8fe9 64%, var(--am-violet) 100%);
    padding: 1.1rem 1rem 1.25rem;
}
.am-brand-inner { position: relative; z-index: 2; height: 100%; display: flex; flex-direction: column; }
.am-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.55;
    z-index: 0;
    will-change: transform;
}
.am-orb-1 { width: 380px; height: 380px; background: #53c1ff; top: -120px; left: -120px; animation: am-drift 20s ease-in-out infinite alternate; }
.am-orb-2 { width: 320px; height: 320px; background: #8f7bff; bottom: -120px; right: -80px; animation: am-drift 24s ease-in-out -6s infinite alternate-reverse; }
.am-orb-3 { width: 240px; height: 240px; background: #36e0c8; top: 45%; left: 40%; opacity: 0.25; animation: am-drift 28s ease-in-out -12s infinite alternate; }
.am-grid {
    position: absolute;
    inset: 0;
    z-index: 1;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
    background-size: 40px 40px;
    -webkit-mask-image: radial-gradient(ellipse at 30% 30%, #000 10%, transparent 70%);
    mask-image: radial-gradient(ellipse at 30% 30%, #000 10%, transparent 70%);
}
.am-logo { display: inline-flex; align-items: center; border-radius: 10px; }
.am-logo img { height: 36px; width: auto; display: block; }
.am-brand-copy, .am-float, .am-brand-foot { display: none; }

.am-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.38rem 0.85rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.22);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}
.am-brand-title {
    font-family: 'Plus Jakarta Sans', 'Inter', system-ui, sans-serif;
    font-weight: 800;
    font-size: clamp(1.9rem, 2.6vw, 2.6rem);
    line-height: 1.12;
    letter-spacing: -0.025em;
    color: #fff;
    margin: 1.25rem 0 0.9rem;
    max-width: 17ch;
}
.am-brand-sub { color: rgba(255, 255, 255, 0.84); font-size: 1.02rem; max-width: 42ch; margin: 0 0 1.75rem; }
.am-brand-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.85rem; }
.am-brand-list li { display: flex; align-items: center; gap: 0.75rem; font-weight: 500; color: rgba(255, 255, 255, 0.95); }
.am-brand-list span {
    flex: 0 0 34px;
    height: 34px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 1.05rem;
}

.am-float { position: relative; height: 150px; margin-top: auto; }
.am-float-card {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.75rem 1rem 0.75rem 0.75rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.95);
    color: #0b1b3a;
    box-shadow: 0 18px 40px -16px rgba(5, 20, 60, 0.55);
    animation: am-float 7s ease-in-out infinite;
}
.am-float-card strong { display: block; font-size: 0.86rem; line-height: 1.2; }
.am-float-card small { display: block; font-size: 0.74rem; color: #5b6b86; }
.am-float-1 { left: 0; top: 10px; }
.am-float-2 { left: 42%; top: 72px; animation-delay: -3.5s; }
.am-float-icon { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; color: #fff; font-size: 1.05rem; }
.am-tone-green .am-float-icon, .am-float-icon.am-tone-green { background: linear-gradient(135deg, #0f9d74, #34d399); }
.am-float-icon.am-tone-violet { background: linear-gradient(135deg, #6d5dfc, #a78bfa); }
.am-brand-foot { margin: 0; padding-top: 1.5rem; font-size: 0.82rem; color: rgba(255, 255, 255, 0.7); }

/* ── Form side ───────────────────────────────────────────────────────────── */
.am-main {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    padding: 0.75rem 1rem 2rem;
    min-width: 0;
}
.am-bg-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
}
.am-bg-blob-1 { width: 420px; height: 420px; background: rgba(43, 168, 247, 0.18); top: -160px; right: -140px; animation: am-drift 26s ease-in-out infinite alternate; }
.am-bg-blob-2 { width: 380px; height: 380px; background: rgba(109, 93, 252, 0.14); bottom: -160px; left: -120px; animation: am-drift 30s ease-in-out -8s infinite alternate-reverse; }

.am-topbar {
    position: relative;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    min-height: 44px;
}
.am-back {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--am-muted) !important;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.4rem 0.6rem;
    margin-left: -0.6rem;
    border-radius: 10px;
    transition: color 0.2s ease, background-color 0.2s ease;
}
.am-back:hover { color: var(--am-ink) !important; background: var(--am-line); }
.am-lang-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.4rem 0.7rem;
    border-radius: 999px;
    border: 1px solid var(--am-line);
    background: var(--am-surface);
    color: var(--am-ink);
    font-size: 0.85rem;
    font-weight: 500;
    min-height: 36px;
}
.am-lang-btn img { border-radius: 3px; object-fit: cover; }
.am-lang .dropdown-menu { max-height: 320px; overflow-y: auto; border-radius: 12px; }

.am-center {
    position: relative;
    z-index: 2;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding-top: 1rem;
}
.am-card {
    width: 100%;
    max-width: 440px;
    background: var(--am-surface);
    border: 1px solid var(--am-line);
    border-radius: 22px;
    box-shadow: var(--am-shadow);
    padding: 1.5rem 1.25rem;
    -webkit-backdrop-filter: blur(16px) saturate(140%);
    backdrop-filter: blur(16px) saturate(140%);
    animation: am-rise 700ms var(--am-ease) both;
}
.am-wide .am-card { max-width: 860px; }
.am-below {
    margin-top: 1.25rem;
    text-align: center;
    color: var(--am-muted);
    font-size: 0.92rem;
}

.am-head { text-align: center; margin-bottom: 1.5rem; }
.am-head-icon {
    width: 52px;
    height: 52px;
    margin: 0 auto 0.9rem;
    border-radius: 16px;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 1.45rem;
    background: var(--am-grad);
    box-shadow: 0 12px 26px -12px rgba(21, 101, 216, 0.75);
}
.am-title {
    font-family: 'Plus Jakarta Sans', 'Inter', system-ui, sans-serif;
    font-weight: 800;
    font-size: 1.55rem;
    letter-spacing: -0.02em;
    line-height: 1.2;
    color: var(--am-ink);
    margin: 0 0 0.35rem;
}
.am-sub { color: var(--am-muted); margin: 0; font-size: 0.95rem; }
.am-step-title { font-size: 1.1rem; font-weight: 700; color: var(--am-ink); margin: 0 0 1rem; }

/* Fields */
.am-form { margin: 0; }
.am-field { margin-bottom: 1.05rem; }
.am-shell .form-label {
    display: block;
    font-weight: 600;
    font-size: 0.86rem;
    color: var(--am-ink);
    margin-bottom: 0.4rem;
}
.am-shell .form-label.required::after { content: " *"; color: var(--am-danger); }
.am-label-row { display: flex; align-items: baseline; justify-content: space-between; gap: 0.75rem; }
.am-input { position: relative; }
.am-input-icon {
    position: absolute;
    left: 14px;
    top: 24px;
    transform: translateY(-50%);
    font-size: 1.1rem;
    color: var(--am-muted);
    pointer-events: none;
    transition: color 0.2s ease;
}
.am-input:focus-within .am-input-icon { color: var(--am-sky); }

.am-shell .form-control {
    height: 48px;
    border-radius: 12px;
    border: 1px solid var(--am-input-border);
    background-color: var(--am-input-bg);
    color: var(--am-ink);
    font-size: 0.95rem;
    padding: 0.6rem 0.9rem;
    box-shadow: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}
.am-shell .am-input:not(.am-input-plain) > .form-control { padding-left: 2.75rem; }
.am-shell .form-control.am-has-toggle { padding-right: 3rem; }
.am-shell .form-control::placeholder { color: var(--am-muted); opacity: 0.7; }
.am-shell .form-control:hover { border-color: color-mix(in srgb, var(--am-sky) 45%, var(--am-input-border)); }
.am-shell .form-control:focus {
    outline: none;
    border-color: var(--am-sky);
    background-color: var(--am-surface-solid);
    box-shadow: 0 0 0 4px var(--am-ring);
    color: var(--am-ink);
}
.am-shell .form-control.is-invalid,
.am-shell .was-validated .form-control:invalid {
    border-color: var(--am-danger);
    background-image: none;
}
.am-shell .form-control.is-invalid:focus,
.am-shell .was-validated .form-control:invalid:focus { box-shadow: 0 0 0 4px color-mix(in srgb, var(--am-danger) 22%, transparent); }
.am-shell .form-control.is-valid { background-image: none; }
.am-shell .invalid-feedback { color: var(--am-danger); font-size: 0.82rem; margin-top: 0.35rem; }
.am-shell .invalid-feedback strong { font-weight: 500; }

.am-input-group .input-group-text {
    border-radius: 0 12px 12px 0;
    border: 1px solid var(--am-input-border);
    background: color-mix(in srgb, var(--am-input-bg) 70%, var(--am-line));
    color: var(--am-muted);
    font-size: 0.88rem;
}
.am-input-group > .form-control { border-radius: 12px 0 0 12px !important; }
.am-input-group > .invalid-feedback { order: 3; width: 100%; }

.am-toggle {
    position: absolute;
    right: 4px;
    top: 4px;
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--am-muted);
    display: grid;
    place-items: center;
    font-size: 1.1rem;
    cursor: pointer;
    transition: color 0.2s ease, background-color 0.2s ease;
}
.am-toggle:hover { color: var(--am-ink); background: var(--am-line); }

.am-check { display: flex; align-items: flex-start; gap: 0.55rem; padding-left: 0; margin: 0.25rem 0 1.25rem; }
.am-check .form-check-input {
    float: none;
    margin: 0.15rem 0 0;
    width: 1.1rem;
    height: 1.1rem;
    flex: 0 0 auto;
    border-radius: 6px;
    border-color: var(--am-input-border);
    background-color: var(--am-input-bg);
    cursor: pointer;
}
.am-check .form-check-input:checked { background-color: var(--am-blue); border-color: var(--am-blue); }
.am-check .form-check-input:focus { box-shadow: 0 0 0 4px var(--am-ring); border-color: var(--am-sky); }
.am-check .form-check-label { color: var(--am-muted); font-size: 0.9rem; cursor: pointer; }
.am-check .form-check-label { order: 2; flex: 1; min-width: 0; }
.am-check .invalid-feedback { flex-basis: 100%; order: 3; }
.am-check { flex-wrap: wrap; }

.am-otp {
    text-align: center;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 1.5rem !important;
    letter-spacing: 0.5em;
    height: 58px !important;
    font-weight: 600;
}
.am-otp-sm { font-size: 1.05rem !important; letter-spacing: 0.12em; }

/* Links */
.am-link { color: var(--am-link) !important; font-weight: 600; border-radius: 4px; }
.am-link:hover { text-decoration: underline !important; text-underline-offset: 3px; }
.am-link-sm { font-size: 0.82rem; font-weight: 500; }
.am-link-btn {
    border: 0;
    background: none;
    padding: 0.25rem 0.5rem;
    color: var(--am-link);
    font-weight: 500;
    font-size: 0.9rem;
    border-radius: 8px;
    cursor: pointer;
}
.am-link-btn:hover { text-decoration: underline; text-underline-offset: 3px; }
.am-switch { text-align: center; margin-top: 1rem; }
.am-hint { color: var(--am-muted); }

/* Buttons */
.am-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 48px;
    padding: 0.7rem 1.35rem;
    border-radius: 12px;
    border: 1px solid transparent;
    font-weight: 600;
    font-size: 0.97rem;
    line-height: 1;
    cursor: pointer;
    transition: transform 0.2s var(--am-ease), box-shadow 0.2s var(--am-ease), background-color 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}
.am-btn:active { transform: scale(0.98); }
.am-btn-primary {
    width: 100%;
    color: #fff !important;
    background: var(--am-grad);
    background-size: 160% 100%;
    box-shadow: 0 10px 24px -10px rgba(21, 101, 216, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.22);
}
.am-btn-primary:hover { background-position: 100% 0; box-shadow: 0 14px 30px -12px rgba(21, 101, 216, 0.85); transform: translateY(-1px); }
.am-btn-primary i { transition: transform 0.25s var(--am-ease); }
.am-btn-primary:hover i.ri-arrow-right-line { transform: translateX(3px); }
.am-btn-auto { width: auto; }
.am-btn-ghost { background: transparent; color: var(--am-muted) !important; border-color: var(--am-line); }
.am-btn-ghost:hover { color: var(--am-ink) !important; background: var(--am-line); }
.am-btn[disabled] { cursor: progress; opacity: 0.9; }
.am-btn-label { display: inline-flex; align-items: center; gap: 0.45rem; transition: opacity 0.15s ease; }
.am-spinner {
    position: absolute;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-top-color: #fff;
    opacity: 0;
    animation: am-spin 0.7s linear infinite;
    animation-play-state: paused;
}
.am-btn.is-loading .am-btn-label { opacity: 0; }
.am-btn.is-loading .am-spinner { opacity: 1; animation-play-state: running; }

/* Alerts */
.am-alert {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    padding: 0.75rem 0.9rem;
    border-radius: 12px;
    font-size: 0.88rem;
    margin-bottom: 1.1rem;
    border: 1px solid transparent;
}
.am-alert > i { font-size: 1.1rem; line-height: 1.3; flex: 0 0 auto; }
.am-alert-info { color: var(--am-ink); background: color-mix(in srgb, var(--am-sky) 10%, transparent); border-color: color-mix(in srgb, var(--am-sky) 25%, transparent); }
.am-alert-info > i { color: var(--am-sky); }
.am-alert-success { color: var(--am-ink); background: color-mix(in srgb, var(--am-success) 10%, transparent); border-color: color-mix(in srgb, var(--am-success) 28%, transparent); }
.am-alert-success > i { color: var(--am-success); }
.am-alert-danger { color: var(--am-ink); background: color-mix(in srgb, var(--am-danger) 10%, transparent); border-color: color-mix(in srgb, var(--am-danger) 28%, transparent); }
.am-alert-danger > i { color: var(--am-danger); }
.am-alert.alert-dismissible { padding-right: 2.75rem; position: relative; }
.am-alert .btn-close { position: absolute; top: 0.6rem; right: 0.6rem; padding: 0.5rem; }

/* Demo quick login */
.am-divider {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 1.5rem 0 1rem;
    color: var(--am-muted);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.am-divider::before, .am-divider::after { content: ""; flex: 1; height: 1px; background: var(--am-line); }
.am-quick { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.6rem; }
.am-quick-btn {
    --tone: var(--am-blue);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    min-height: 68px;
    padding: 0.6rem 0.4rem;
    border-radius: 14px;
    border: 1px solid color-mix(in srgb, var(--tone) 22%, transparent);
    background: color-mix(in srgb, var(--tone) 8%, transparent);
    color: var(--am-ink);
    font-weight: 600;
    font-size: 0.82rem;
    cursor: pointer;
    transition: transform 0.2s var(--am-ease), border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}
.am-quick-btn i { font-size: 1.3rem; color: var(--tone); }
.am-quick-btn:hover {
    transform: translateY(-2px);
    border-color: color-mix(in srgb, var(--tone) 50%, transparent);
    background: color-mix(in srgb, var(--tone) 13%, transparent);
    box-shadow: 0 10px 20px -14px var(--tone);
}
.am-quick-btn:active { transform: scale(0.97); }
.am-quick-btn[disabled] { opacity: 0.75; cursor: progress; }
.am-quick-wide { flex-direction: row; width: 100%; min-height: 48px; margin-top: 0.6rem; }
.am-tone-blue { --tone: #1565d8; }
.am-tone-sky { --tone: #0ea5e9; }
.am-tone-amber { --tone: #e8890c; }
.am-tone-rose { --tone: #e11d63; }

/* Focus rings (keyboard) */
.am-shell a:focus-visible,
.am-shell button:focus-visible,
.am-shell [role="button"]:focus-visible,
.am-shell .form-check-input:focus-visible {
    outline: 3px solid var(--am-sky);
    outline-offset: 2px;
    box-shadow: none;
}

/* ── Signup (multi-step) ─────────────────────────────────────────────────── */
.am-steps .am-head { margin-bottom: 1.25rem; }
.am-progress { position: relative; margin: 2.25rem auto 2.5rem; max-width: 520px; }
.am-progress .progress { height: 4px !important; background: var(--am-line); border-radius: 99px; }
.am-progress .progress-bar { background: var(--am-grad); border-radius: 99px; transition: width 0.4s var(--am-ease); }
.am-progress .progress-bar-tab {
    position: absolute;
    inset: -18px 0 auto;
    display: flex;
    justify-content: space-between;
    border: 0;
    padding: 0;
}
.am-progress .progress-bar-tab .nav-link {
    width: 40px;
    height: 40px;
    padding: 0;
    display: grid;
    place-items: center;
    border-radius: 50% !important;
    background: var(--am-surface-solid);
    border: 2px solid var(--am-line);
    color: var(--am-muted);
}
.am-progress .progress-bar-tab .nav-link i { font-size: 1.05rem !important; }
.am-progress .progress-bar-tab .nav-link.active,
.am-progress .progress-bar-tab .nav-link.done {
    background: var(--am-grad);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 8px 18px -10px rgba(21, 101, 216, 0.8);
}
.am-steps .tab-content { padding-top: 1.25rem; }
.am-plans { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 0.85rem; }
.am-plan {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    padding: 1.1rem 1rem;
    border-radius: 16px;
    border: 1.5px solid var(--am-input-border);
    background: var(--am-input-bg);
    cursor: pointer;
    transition: transform 0.2s var(--am-ease), border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}
.am-plan:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--am-sky) 55%, var(--am-input-border)); }
.am-plan.active {
    border-color: var(--am-blue);
    background: color-mix(in srgb, var(--am-blue) 7%, var(--am-surface-solid));
    box-shadow: 0 0 0 4px var(--am-ring);
}
.am-plan-name { font-weight: 700; font-size: 1rem; color: var(--am-ink); }
.am-plan-period { font-size: 0.78rem; color: var(--am-muted); text-transform: capitalize; }
.am-plan-price { margin-top: 0.4rem; font-size: 1.35rem; font-weight: 800; color: var(--am-ink); font-family: 'Plus Jakarta Sans', 'Inter', sans-serif; }
.am-plan-price small { font-size: 0.8rem; font-weight: 600; color: var(--am-muted); }
.am-plan-check {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 0.85rem;
    color: #fff;
    background: var(--am-grad);
    opacity: 0;
    transform: scale(0.6);
    transition: opacity 0.2s ease, transform 0.25s var(--am-ease);
}
.am-plan.active .am-plan-check { opacity: 1; transform: scale(1); }
.am-step-actions { display: flex; align-items: center; gap: 0.75rem; margin-top: 1.5rem; }
.am-step-actions .am-btn-primary { margin-left: auto; }
.am-pay-btn {
    width: 100%;
    min-height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    border-radius: 14px;
    border: 1.5px solid var(--am-input-border);
    background: var(--am-input-bg);
    color: var(--am-ink);
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.2s ease, transform 0.2s var(--am-ease), box-shadow 0.2s ease;
}
.am-pay-btn i { font-size: 1.3rem; color: var(--am-blue); }
.am-pay-btn:hover { transform: translateY(-2px); border-color: var(--am-sky); box-shadow: 0 0 0 4px var(--am-ring); }
.am-stripe-el { min-height: 48px; padding: 0.85rem 0.9rem; border-radius: 12px; border: 1px solid var(--am-input-border); background: var(--am-input-bg); }
.am-success { text-align: center; padding: 1rem 0 0.5rem; }
.am-success-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 1rem;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 2rem;
    color: #fff;
    background: linear-gradient(135deg, #0f9d74, #34d399);
    box-shadow: 0 16px 30px -14px rgba(15, 157, 116, 0.8);
}
.am-success .am-sub { margin-bottom: 1.25rem; }

/* ── Tablet + desktop ────────────────────────────────────────────────────── */
@media (min-width: 576px) {
    .am-main { padding: 1rem 1.5rem 2.5rem; }
    .am-card { padding: 2rem 2rem; border-radius: 24px; }
}

@media (min-width: 992px) {
    .am-shell { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); }
    .am-shell.am-wide { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); }
    .am-brand {
        position: sticky;
        top: 0;
        height: 100vh;
        height: 100dvh;
        padding: 2.5rem clamp(2rem, 4vw, 3.5rem);
    }
    .am-logo img { height: 44px; }
    .am-brand-copy { display: block; margin-top: clamp(2.5rem, 9vh, 6rem); }
    .am-float { display: block; }
    .am-brand-foot { display: block; }
    .am-main { padding: 1.5rem clamp(1.5rem, 4vw, 3.5rem) 2.5rem; }
    .am-card { padding: 2.5rem 2.5rem; }
    .am-wide .am-brand-title { font-size: clamp(1.7rem, 2.2vw, 2.2rem); }
    .am-wide .am-float { display: none; }
    .am-wide .am-brand-foot { margin-top: auto; }
}

@media (max-width: 991.98px) {
    /* Compact brand header on phones / tablets */
    .am-brand { display: flex; align-items: center; min-height: 64px; }
    .am-brand-inner { flex-direction: row; align-items: center; }
    .am-orb { filter: blur(40px); }
}

@media (max-width: 380px) {
    .am-quick { gap: 0.45rem; }
    .am-quick-btn { font-size: 0.76rem; }
}

/* ── Keyframes ───────────────────────────────────────────────────────────── */
@keyframes am-drift {
    0% { transform: translate3d(0, 0, 0) scale(1); }
    50% { transform: translate3d(40px, 30px, 0) scale(1.08); }
    100% { transform: translate3d(-30px, 50px, 0) scale(0.95); }
}
@keyframes am-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes am-rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes am-spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
    .am-shell *, .am-shell *::before, .am-shell *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition: none !important;
    }
    .am-spinner { animation: am-spin 1.2s linear infinite !important; }
    .am-orb, .am-bg-blob, .am-float-card { animation: none !important; }
}
