/* =========================================================
   PB SMEKMA — Halaman Masuk
   Gaya tenang & elegan: navy klub, kertas gading, aksen emas tipis
   ========================================================= */
:root {
    --navy: #0B1A44;
    --navy-2: #13275F;
    --gold: #C9A55A;
    --ivory: #F7F5F0;
    --paper: #FFFFFF;
    --ink: #1A2238;
    --muted: #6B7390;
    --line: #DDE0E8;
    --danger: #B42318;
    --danger-soft: #FDECEA;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body.lx {
    font-family: 'Lexend', system-ui, -apple-system, 'Segoe UI', sans-serif;
    color: var(--ink);
    background: var(--ivory);
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* ---------- Tata letak ---------- */
.lx-wrap { min-height: 100vh; min-height: 100dvh; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }

/* ---------- Panel kiri: identitas klub ---------- */
.lx-hero {
    position: relative; overflow: hidden;
    display: flex; flex-direction: column; justify-content: center; align-items: center;
    padding: 3rem 2rem; color: #fff; text-align: center;
    background: radial-gradient(90% 70% at 50% 40%, var(--navy-2) 0%, var(--navy) 70%);
}
.lx-court { position: absolute; left: 50%; top: 50%; width: 62%; max-width: 420px; transform: translate(-50%, -50%);
    color: rgba(255, 255, 255, .05); pointer-events: none; }
.lx-brand { position: relative; display: flex; flex-direction: column; align-items: center; animation: fade .8s ease both; }
.lx-emblem { width: 170px; aspect-ratio: 497 / 560; margin-bottom: 2rem; }
.lx-emblem img { width: 100%; height: 100%; object-fit: contain; display: block; filter: drop-shadow(0 12px 24px rgba(0, 0, 0, .35)); }
.lx-emblem.is-custom { aspect-ratio: 1; }
.lx-emblem.is-custom img { border-radius: 24px; object-fit: cover; }
.lx-eyebrow { margin: 0 0 .6rem; font-size: .72rem; font-weight: 500; letter-spacing: .28em; text-transform: uppercase; color: rgba(255, 255, 255, .7); }
.lx-title { margin: 0; font-family: 'Cormorant Garamond', Georgia, serif; font-weight: 600; font-size: clamp(2.6rem, 4vw, 3.4rem); line-height: 1; letter-spacing: .02em; }
.lx-rule { display: block; width: 48px; height: 1px; margin: 1.2rem auto; background: var(--gold); }
.lx-tagline { margin: 0; font-family: 'Cormorant Garamond', Georgia, serif; font-style: italic; font-weight: 500; font-size: 1.35rem; color: var(--gold); }
.lx-hero-foot { position: absolute; bottom: 1.6rem; left: 0; right: 0; margin: 0; font-size: .75rem; letter-spacing: .08em; color: rgba(255, 255, 255, .45); }

/* ---------- Panel kanan: formulir ---------- */
.lx-panel { display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 3rem 1.5rem 2rem; }
.lx-card { width: 100%; max-width: 380px; animation: fade .8s ease .1s both; }
.lx-heading { margin: 0; font-size: 1.75rem; font-weight: 600; letter-spacing: -.02em; color: var(--navy); }
.lx-lead { margin: .4rem 0 1.8rem; font-size: .92rem; font-weight: 300; color: var(--muted); }

/* Tab Anggota / Pengurus */
.lx-tabs { display: flex; gap: 1.8rem; margin: 0 0 1.6rem; border-bottom: 1px solid var(--line); }
.lx-tab { position: relative; padding: 0 0 .75rem; border: 0; background: none; cursor: pointer;
    font: 500 .95rem 'Lexend', sans-serif; color: var(--muted); transition: color .2s; }
.lx-tab::after { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--navy); transform: scaleX(0); transition: transform .25s ease; }
.lx-tab:hover { color: var(--ink); }
.lx-tab[aria-selected="true"] { color: var(--navy); }
.lx-tab[aria-selected="true"]::after { transform: scaleX(1); }

.lx-alert { display: flex; gap: .6rem; align-items: flex-start; padding: .75rem .9rem; margin: 0 0 1.2rem; border-radius: 10px;
    font-size: .86rem; color: var(--danger); background: var(--danger-soft); }
.lx-alert i { margin-top: 1px; }

/* Kolom isian */
.lx-field { margin-bottom: 1.1rem; }
.lx-field > label { display: block; margin-bottom: .45rem; font-size: .85rem; font-weight: 500; color: var(--ink); }
.lx-input { position: relative; }
.lx-input input {
    width: 100%; height: 50px; padding: 0 3rem 0 2.75rem; border-radius: 10px;
    font: 400 .98rem 'Lexend', sans-serif; color: var(--ink);
    background: var(--paper); border: 1px solid var(--line); outline: none;
    transition: border-color .2s, box-shadow .2s;
}
.lx-input input:hover { border-color: #C5CAD6; }
.lx-input input:focus { border-color: var(--navy); box-shadow: 0 0 0 3px rgba(11, 26, 68, .08); }
.lx-ico { position: absolute; left: 1rem; top: 50%; transform: translateY(-50%); font-size: 1.05rem; color: #9AA1B8; pointer-events: none; }
.lx-field:focus-within .lx-ico { color: var(--navy); }
.lx-eye { position: absolute; right: .4rem; top: 50%; transform: translateY(-50%); width: 38px; height: 38px; border: 0; border-radius: 8px;
    background: none; color: #9AA1B8; font-size: 1.05rem; cursor: pointer; }
.lx-eye:hover { color: var(--navy); background: #F1F2F6; }
.lx-field.is-invalid input { border-color: var(--danger); box-shadow: 0 0 0 3px rgba(180, 35, 24, .08); }
.lx-field.is-invalid > label { color: var(--danger); }
.lx-caps { margin: .45rem 0 0; font-size: .8rem; color: #8A6A1F; }

.lx-hint { margin: .2rem 0 1.5rem; font-size: .8rem; line-height: 1.55; font-weight: 300; color: var(--muted); }
.lx-hint b { font-weight: 500; color: var(--ink); }

/* Tombol */
.lx-btn {
    width: 100%; height: 50px; border: 0; border-radius: 10px; cursor: pointer;
    display: flex; align-items: center; justify-content: center; gap: .6rem;
    font: 500 .98rem 'Lexend', sans-serif; letter-spacing: .01em; color: #fff;
    background: var(--navy); transition: background .2s;
}
.lx-btn:hover { background: var(--navy-2); }
.lx-btn:active { background: #08132F; }
.lx-spin { display: none; width: 16px; height: 16px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .3); border-top-color: #fff; animation: spin .7s linear infinite; }
.lx-btn.is-loading { pointer-events: none; opacity: .9; }
.lx-btn.is-loading .lx-spin { display: block; }

.lx-verify { display: flex; align-items: center; justify-content: center; gap: .5rem; margin-top: 1.6rem; padding-top: 1.4rem;
    border-top: 1px solid var(--line); font-size: .85rem; color: var(--muted); transition: color .2s; }
.lx-verify i { color: var(--gold); }
.lx-verify:hover { color: var(--navy); }

.lx-foot { margin: 2.5rem 0 0; font-size: .75rem; color: #9AA1B8; text-align: center; }

@keyframes fade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Tablet & ponsel: muat satu layar penuh ---------- */
@media (max-width: 860px) {
    .lx-wrap { grid-template-columns: 1fr; grid-template-rows: auto 1fr; height: 100vh; height: 100dvh; min-height: 0; }
    .lx-hero { flex-direction: row; justify-content: flex-start; padding: 1.1rem 1.25rem; padding-top: max(1.1rem, env(safe-area-inset-top)); text-align: left; }
    .lx-court { width: 46%; max-width: 200px; left: auto; right: -6%; transform: translateY(-50%) rotate(-90deg); }
    .lx-brand { display: grid; grid-template-columns: auto 1fr; column-gap: .9rem; align-items: center; justify-items: start; }
    .lx-emblem { grid-row: 1 / span 4; width: 54px; margin: 0; }
    .lx-emblem img { filter: drop-shadow(0 4px 10px rgba(0, 0, 0, .35)); }
    .lx-emblem.is-custom img { border-radius: 12px; }
    .lx-eyebrow { display: none; }
    .lx-title { font-size: 1.7rem; white-space: nowrap; }
    .lx-rule { display: none; }
    .lx-tagline { font-size: 1rem; margin-top: .15rem; }
    .lx-hero-foot { display: none; }

    .lx-panel { justify-content: space-between; align-items: stretch; padding: 1.4rem 1.25rem; padding-bottom: max(1rem, env(safe-area-inset-bottom)); overflow-y: auto; }
    .lx-card { max-width: 440px; margin: auto; }
    .lx-heading { font-size: 1.4rem; }
    .lx-lead { margin: .2rem 0 1.1rem; font-size: .85rem; }
    .lx-tabs { margin-bottom: 1.1rem; }
    .lx-tab { padding-bottom: .6rem; font-size: .9rem; }
    .lx-alert { margin-bottom: .9rem; padding: .6rem .8rem; font-size: .82rem; }
    .lx-field { margin-bottom: .85rem; }
    .lx-field > label { margin-bottom: .35rem; font-size: .8rem; }
    .lx-input input { height: 46px; font-size: 1rem; }
    .lx-hint { margin: 0 0 1.1rem; font-size: .76rem; line-height: 1.45; }
    .lx-btn { height: 48px; }
    .lx-verify { margin-top: 1rem; padding-top: 1rem; font-size: .82rem; }
    .lx-foot { margin: .8rem 0 0; font-size: .7rem; }
}
/* Ponsel layar pendek (mis. 360×640 dengan bilah browser) */
@media (max-width: 860px) and (max-height: 640px) {
    .lx-hero { padding-top: .8rem; padding-bottom: .8rem; }
    .lx-emblem { width: 44px; }
    .lx-title { font-size: 1.45rem; }
    .lx-tagline { font-size: .9rem; }
    .lx-panel { padding-top: 1rem; }
    .lx-heading { font-size: 1.25rem; }
    .lx-lead { display: none; }
    .lx-heading { margin-bottom: .8rem; }
    .lx-tabs { margin-bottom: .9rem; }
    .lx-field { margin-bottom: .7rem; }
    .lx-input input { height: 44px; }
    .lx-hint { margin-bottom: .9rem; }
    .lx-btn { height: 46px; }
    .lx-verify { margin-top: .8rem; padding-top: .8rem; }
    .lx-foot { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
}