/* adratn.club — design system (shadcn/Atomic-CRM style)
   Light default + dark via system pref or [data-theme] override. */

:root {
  --bg: #ffffff;
  --card: #ffffff;
  --border: #e4e4e7;
  --fg: #18181b;
  --muted: #71717a;
  --input: #ffffff;
  --hover: rgba(0, 0, 0, .045);
  /* Brand: turquoise #2dccd3 + navy #043B64 (adratn.club) */
  --brand: #2dccd3;          /* turquoise — logo, highlights */
  --brand-ink: #043B64;      /* navy — text/icon on turquoise */
  --accent: #043B64;         /* navy — primary buttons / active controls */
  --accent-hover: #0a4e82;
  --accent-fg: #ffffff;
  --ring: rgba(45, 204, 211, .40);
  --radius: 8px;
  --shadow: 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.04);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0a0a0a;
    --card: #18181b;
    --border: #27272a;
    --fg: #fafafa;
    --muted: #a1a1aa;
    --input: #111113;
    --hover: rgba(255, 255, 255, .06);
    --shadow: 0 1px 3px rgba(0,0,0,.4);
    --accent: #2dccd3;         /* turquoise pops on dark */
    --accent-hover: #25b4ba;
    --accent-fg: #043B64;      /* navy text on turquoise */
  }
}

:root[data-theme="dark"] {
  --bg: #0a0a0a;
  --card: #18181b;
  --border: #27272a;
  --fg: #fafafa;
  --muted: #a1a1aa;
  --input: #111113;
  --hover: rgba(255, 255, 255, .06);
  --shadow: 0 1px 3px rgba(0,0,0,.4);
  --accent: #2dccd3;
  --accent-hover: #25b4ba;
  --accent-fg: #043B64;
}

* { box-sizing: border-box; }
html, body { height: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Top bar (theme + language controls) */
.topbar {
  position: absolute;
  top: 0; left: 0; right: 0;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: .5rem;
  padding: 1rem 1.25rem;
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--fg);
  border-radius: 8px;
  cursor: pointer;
  transition: background .15s;
}
.icon-btn:hover { background: var(--hover); }
.icon-btn svg { width: 18px; height: 18px; }

.lang {
  display: inline-flex;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.lang button {
  border: 0;
  background: var(--card);
  color: var(--muted);
  padding: .45rem .7rem;
  font-size: .78rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s, color .15s;
}
.lang button + button { border-left: 1px solid var(--border); }
.lang button.active { background: var(--accent); color: var(--accent-fg); }

/* Centered card layout */
.main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.card {
  width: 100%;
  max-width: 400px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2rem;
}

/* Brand */
.brand {
  display: flex;
  align-items: center;
  gap: .7rem;
  margin-bottom: 1.75rem;
}
.brand .logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px; height: 42px;
  border-radius: 10px;
  background: var(--brand);
  color: var(--brand-ink);
  flex: 0 0 auto;
}
.brand .logo svg { width: 23px; height: 23px; }
.brand .name { font-weight: 650; font-size: 1.05rem; letter-spacing: -.01em; line-height: 1.2; }
.brand .sub { display: block; font-weight: 400; font-size: .78rem; color: var(--muted); margin-top: 1px; }

h1 { font-size: 1.4rem; margin: 0 0 .3rem; letter-spacing: -.02em; }
.lead { margin: 0 0 1.6rem; color: var(--muted); font-size: .9rem; }

/* Form */
.field { margin-bottom: 1rem; }
.field label { display: block; font-size: .82rem; font-weight: 500; margin-bottom: .4rem; }
.input {
  width: 100%;
  height: 40px;
  padding: 0 .75rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--input);
  color: var(--fg);
  font-size: .92rem;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.input::placeholder { color: var(--muted); opacity: .7; }
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--ring); }

.btn {
  width: 100%;
  height: 40px;
  border: 0;
  border-radius: 6px;
  background: var(--accent);
  color: var(--accent-fg);
  font-size: .92rem;
  font-weight: 600;
  cursor: pointer;
  margin-top: .5rem;
  transition: background .15s;
}
.btn:hover { background: var(--accent-hover); }

.note {
  margin: .9rem 0 0;
  text-align: center;
  font-size: .76rem;
  color: var(--muted);
}

/* Footer */
.footer {
  padding: 1.25rem;
  text-align: center;
  color: var(--muted);
  font-size: .74rem;
  line-height: 1.5;
}

@media (max-width: 480px) {
  .card { padding: 1.5rem; }
}
