@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/Geist-normal-400-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/Geist-normal-400-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(fonts/Geist-normal-500-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(fonts/Geist-normal-500-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(fonts/Geist-normal-600-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(fonts/Geist-normal-600-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Geist Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/GeistMono-normal-400-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Geist Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/GeistMono-normal-400-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Geist Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(fonts/GeistMono-normal-500-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Geist Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(fonts/GeistMono-normal-500-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/InstrumentSerif-italic-400-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/InstrumentSerif-italic-400-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/InstrumentSerif-normal-400-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/InstrumentSerif-normal-400-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ── Temă e-data pentru portalul Authelia (server.thebitsmith.ro) ─────────
   Injectată de nginx (sub_filter) după CSS-ul Authelia. Limbaj vizual =
   dashboard-ul e-data: „card în card" (carcasă gri-deschis cu etichetă mono,
   card alb în interior), Geist, zinc, colțuri 10–14px. */

:root, [data-theme], [data-theme="light"], [data-theme="dark"] {
  --ink: #0a0a0b;
  --text: #27272a;
  --muted-ink: #71717a;
  --line: #e4e4e7;
  --shell: #f7f7f8;
  --paper: #fff;

  --background: var(--paper);
  --foreground: var(--ink);
  --card: var(--paper);
  --card-foreground: var(--ink);
  --popover: var(--paper);
  --popover-foreground: var(--ink);
  --primary: var(--ink);
  --primary-foreground: #fff;
  --secondary: var(--ink);
  --secondary-foreground: #fff;
  --muted: #f4f4f5;
  --muted-foreground: var(--muted-ink);
  --accent: #f4f4f5;
  --accent-foreground: var(--ink);
  --info: var(--muted-ink);
  --border: var(--line);
  --input: var(--line);
  --ring: var(--ink);
  --radius: 10px;
  --custom-icon: var(--ink);
  --custom-loading-bar: var(--ink);
  --font-sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --default-font-family: var(--font-sans);
  color-scheme: light;
}

html, body { background: var(--paper) !important; }
body {
  color: var(--text);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
}

/* semnătura de jos (în flux, nu fixă — nu se suprapune peste card) */
body::after {
  content: "Infrastructură administrată de e-data  ·  e-data.ro";
  display: block;
  padding: 8px 0 28px;
  text-align: center;
  font: 500 10.5px/1 var(--font-mono);
  letter-spacing: .1em; text-transform: uppercase;
  color: #a1a1aa;
}

/* ── carcasa (exterior, gri-deschis) ───────────────────────────────────── */
[id$="-stage"] > div {
  position: relative;
  max-width: 452px !important;
  padding: 40px 6px 6px !important;
  background: var(--shell);
  border: 1px solid var(--line);
  border-radius: 14px;
  text-align: left;
}
/* eticheta stânga: lacăt + ACCES SECURIZAT */
[id$="-stage"] > div::before {
  content: "Acces securizat";
  position: absolute; left: 14px; top: 14px;
  padding-left: 20px;
  background: url("lock.svg") left center / 14px 14px no-repeat;
  font: 500 11px/14px var(--font-mono);
  letter-spacing: .08em; text-transform: uppercase;
  color: #3f3f46;
}
/* eticheta dreapta: mențiunea e-data */
[id$="-stage"] > div::after {
  content: "securitate suplimentară · e-data";
  position: absolute; right: 14px; top: 14px;
  font: 400 12px/14px var(--font-sans);
  color: var(--muted-ink);
}

/* ── cardul (interior, alb) ────────────────────────────────────────────── */
[id$="-stage"] > div > .flex-col {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 26px 24px 24px;
  box-shadow: 0 1px 2px rgba(9, 9, 11, .03);
}

/* marca e-data în locul avatarului generic */
[id$="-stage"] .flex-col > .w-full.p-2:first-child {
  height: 34px; padding: 0 !important;
  margin-bottom: 18px;
  background: url("mark.svg") left center / 34px 34px no-repeat;
}
[id$="-stage"] .flex-col > .w-full.p-2:first-child > svg { display: none; }

/* titlu + subtitlu */
[id$="-stage"] h5 {
  font: 500 26px/1.15 var(--font-sans) !important;
  letter-spacing: -.02em;
  color: var(--ink);
  text-align: left;
}
[id$="-stage"] h5::after {
  content: "theBitSmith · panou server. Acces cu parolă și autentificare în doi pași.";
  display: block;
  margin-top: 6px;
  font: 400 14px/1.45 var(--font-sans);
  letter-spacing: 0;
  color: var(--muted-ink);
}

/* câmpuri */
[id$="-stage"] input[data-slot="floating-input"] {
  border-radius: 8px !important;
  border-color: var(--line) !important;
  background: #fff !important;
  color: var(--ink);
}
[id$="-stage"] input[data-slot="floating-input"]:focus {
  border-color: var(--ink) !important;
  box-shadow: 0 0 0 3px rgba(9, 9, 11, .06) !important;
}
[id$="-stage"] label { color: var(--muted-ink); }
[id$="-stage"] input:focus + label { color: var(--ink) !important; }

/* buton principal */
[id$="-stage"] button[data-slot="button"][data-variant="default"],
#register-link {
  height: 42px;
  border-radius: 8px !important;
  text-transform: none !important;
  font: 500 14px/1 var(--font-sans);
  letter-spacing: 0;
  background: var(--ink) !important;
  color: #fff !important;
  transition: background .15s ease;
}
[id$="-stage"] button[data-slot="button"][data-variant="default"]:hover,
#register-link:hover { background: #27272a !important; text-decoration: none !important; }

/* bifa „Ține-mă minte" */
[id$="-stage"] [data-slot="checkbox"] { border-radius: 4px; border-color: #d4d4d8; }
[id$="-stage"] [data-slot="label"] { font-weight: 400; font-size: 14px; color: var(--text); }

/* nota lungă de jos: scoasă (mențiunea e în eticheta carcasei) */
[id$="-stage"] .flex-col > div:last-child:has(> a[href*="authelia.com"]) { display: none; }

/* ── pagina 2FA ────────────────────────────────────────────────────────── */
/* rândul Deconectare | Schimbă utilizatorul | Metode → butoane mici, fără „|" */
[id$="-stage"] .flex-col > .mt-2 > .flex-col > .w-full:first-child {
  display: flex; flex-wrap: wrap; gap: 6px;
  font-size: 0;            /* ascunde separatorii „|" (noduri text) */
  margin-top: 4px;
}
[id$="-stage"] button[data-variant="ghost"] {
  height: 30px; padding: 0 10px !important;
  border: 1px solid var(--line);
  border-radius: 999px !important;
  background: #fff;
  color: var(--text) !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
  font: 500 12.5px/1 var(--font-sans) !important;
}
[id$="-stage"] button[data-variant="ghost"]:hover { background: #f4f4f5 !important; }

/* panoul metodei (TOTP / passkey) */
[id$="-stage"] .my-4.border {
  margin: 16px 0 0 !important;
  min-width: 0 !important;
  padding: 20px !important;
  border-radius: 10px !important;
  background: #fafafa;
  text-align: left;
}
[id$="-stage"] .my-4.border h6 {
  font: 500 11px/1 var(--font-mono) !important;
  letter-spacing: .08em; text-transform: uppercase;
  color: #3f3f46;
  margin-bottom: 8px;
}
[id="2fa-container"] { height: auto !important; min-height: 0 !important; }
[id$="-stage"] [id="2fa-container"] > div { justify-content: flex-start !important; align-content: flex-start !important; }
[id$="-stage"] [id="2fa-container"] .mb-4 { justify-content: flex-start !important; margin-bottom: 10px; }
[id$="-stage"] [id="2fa-container"] .mb-4 svg { width: 22px !important; height: 22px !important; color: var(--muted-ink) !important; }
[id$="-stage"] p[class*="5858ff"] {
  color: var(--text) !important;
  font-size: 14px; line-height: 1.5;
  text-align: left; flex-basis: 100%;
}
[id$="-stage"] p[class*="5858ff"] + p[class*="5858ff"] { color: var(--muted-ink) !important; margin-top: 4px; }
#register-link {
  display: inline-flex; align-items: center; justify-content: center;
  width: 100%; margin-top: 16px;
}

#language-button { color: var(--muted-ink); }

@media (max-width: 520px) {
  [id$="-stage"] > div::after { display: none; }
  [id$="-stage"] > div > .flex-col { padding: 22px 18px 18px; }
}
