/* ════════════════════════════════════════════════════════
   auth.css — shared styles for login.php & registration.php
   Colour variables (--accent, --gold, ...) come from auth_theme.php
   ════════════════════════════════════════════════════════ */

:root {
  --ink: #1d1a1c;
  --muted: #77707a;
  --line: #e6e1e3;
  --paper: #fbf9f7;
  --serif: 'Cormorant Garamond', Georgia, serif;
  --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html, body { min-height: 100%; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ── Layout ─────────────────────────────────────────── */
.lx {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
}
.lx--wide { grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.5fr); }

/* ── Brand panel (desktop) ──────────────────────────── */
.lx-brand {
  position: relative;
  overflow: hidden;
  color: #fff;
  padding: 3rem 3.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2rem;
  background:
    radial-gradient(120% 90% at 0% 0%, rgba(255,255,255,0.10) 0%, transparent 55%),
    radial-gradient(90% 80% at 100% 100%, rgba(0,0,0,0.35) 0%, transparent 60%),
    linear-gradient(150deg, var(--accent) 0%, var(--accent2) 100%);
}
.lx--wide .lx-brand {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 2.6rem 2.8rem;
}

.lx-guilloche {
  position: absolute;
  width: 760px;
  height: 760px;
  right: -380px;
  top: 50%;
  margin-top: -380px;
  pointer-events: none;
  animation: lx-spin 240s linear infinite;
}
@keyframes lx-spin { to { transform: rotate(360deg); } }

.lx-brand-top {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.9rem;
}
.lx-brand-top img {
  height: 46px;
  max-width: 160px;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.35));
}
.lx-brand-top span {
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.lx-brand-copy { position: relative; max-width: 440px; }
.lx-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
}
.lx-eyebrow::before {
  content: '';
  width: 28px;
  height: 1px;
  background: var(--gold);
}
.lx-brand-copy h1 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2.2rem, 3.4vw, 3.4rem);
  line-height: 1.08;
  margin: 1rem 0 1.1rem;
}
.lx-brand-copy h1 em { color: var(--gold); font-style: italic; }
.lx-brand-copy p {
  color: rgba(255,255,255,0.78);
  font-size: 0.98rem;
  line-height: 1.65;
  margin: 0;
}

.lx-trust {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.6rem;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.75);
}
.lx-trust div { display: flex; align-items: center; gap: 0.5rem; }
.lx-trust svg { width: 18px; height: 18px; color: var(--gold); flex-shrink: 0; }

/* ── Content panel ──────────────────────────────────── */
.lx-form-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 1.5rem;
  min-width: 0;
}
.lx-form {
  width: 100%;
  max-width: 400px;
  animation: lx-rise 0.7s cubic-bezier(.2,.7,.2,1) both;
}
.lx--wide .lx-form-wrap { align-items: flex-start; padding: 3.2rem 2.5rem; }
.lx--wide .lx-form { max-width: 760px; }
@keyframes lx-rise {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}

.lx-mobile-brand { display: none; }

.lx-greeting {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.5rem;
}
.lx-form h2 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 2.3rem;
  line-height: 1.1;
  margin: 0 0 0.4rem;
}
.lx-sub { color: var(--muted); font-size: 0.92rem; margin: 0 0 2rem; }

/* ── Buttons ────────────────────────────────────────── */
.lx-btn {
  position: relative;
  width: 100%;
  height: 56px;
  padding: 0 1.6rem;
  border: 0;
  border-radius: 12px;
  font: 600 0.98rem var(--sans);
  letter-spacing: 0.03em;
  color: #fff;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent2) 100%);
  box-shadow: 0 10px 24px -10px rgba(var(--accent-rgb), 0.7);
  overflow: hidden;
  cursor: pointer;
  transition: transform .15s, box-shadow .2s, opacity .2s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  text-decoration: none;
}
.lx-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,0.22) 50%, transparent 70%);
  transform: translateX(-100%);
  transition: transform .7s ease;
}
.lx-btn:hover:not(:disabled) { color: #fff; transform: translateY(-1px); box-shadow: 0 14px 28px -10px rgba(var(--accent-rgb), 0.75); }
.lx-btn:hover:not(:disabled)::after { transform: translateX(100%); }
.lx-btn:active:not(:disabled) { transform: translateY(0); }
.lx-btn:disabled { opacity: 0.75; cursor: progress; }
.lx-btn .lx-arrow { width: 18px; height: 18px; transition: transform .2s; }
.lx-btn:hover:not(:disabled) .lx-arrow { transform: translateX(3px); }

.lx-btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 56px;
  padding: 0 1.4rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  font: 500 0.95rem var(--sans);
  text-decoration: none;
  cursor: pointer;
  transition: border-color .2s, color .2s, background .2s;
}
.lx-btn-ghost:hover { border-color: var(--accent); color: var(--accent); background: rgba(var(--accent-rgb), 0.03); }
.lx-btn-ghost svg { width: 18px; height: 18px; }

/* ── Footer ─────────────────────────────────────────── */
.lx-footer {
  margin-top: 2.2rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.74rem;
  color: #a39ba0;
}
.lx-footer a { color: inherit; text-decoration: none; overflow-wrap: anywhere; }
.lx-footer a:hover { color: var(--accent); }
.lx-secure { display: inline-flex; align-items: center; gap: 0.35rem; }
.lx-secure svg { width: 13px; height: 13px; }

/* ── Mobile / tablet ────────────────────────────────── */
@media (max-width: 991px) {
  .lx, .lx--wide { grid-template-columns: minmax(0, 1fr); }
  .lx-brand { display: none; }
  .lx-form-wrap,
  .lx--wide .lx-form-wrap { align-items: flex-start; padding: 0 0 2rem; }
  .lx-form,
  .lx--wide .lx-form { max-width: none; }
  .lx-mobile-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
    position: relative;
    overflow: hidden;
    padding: 2.4rem 1rem 3.6rem;
    margin-bottom: -1.6rem;
    color: #fff;
    text-align: center;
    background: linear-gradient(150deg, var(--accent) 0%, var(--accent2) 100%);
  }
  .lx-mobile-brand .lx-guilloche { width: 560px; height: 560px; right: auto; left: 50%; margin: -280px 0 0 -280px; opacity: 0.55; }
  .lx-mobile-brand img { position: relative; height: 52px; max-width: 170px; object-fit: contain; }
  .lx-mobile-brand span { position: relative; font-family: var(--serif); font-size: 1.3rem; font-weight: 600; }
  .lx-card {
    position: relative;
    max-width: 560px;
    margin: 0 auto;
    margin-left: max(16px, calc(50% - 280px));
    margin-right: max(16px, calc(50% - 280px));
    padding: 1.8rem 1.4rem;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 18px 40px -24px rgba(0,0,0,0.35);
  }
  .lx--wide .lx-card {
    max-width: 760px;
    margin-left: max(16px, calc(50% - 380px));
    margin-right: max(16px, calc(50% - 380px));
  }
  .lx-form h2 { font-size: 2rem; }
}
@media (max-width: 400px) {
  .lx-card { padding: 1.6rem 1.1rem; }
  .lx-form h2 { font-size: 1.8rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
