/* ── Fuatilia public site — modern refresh ─────────────────────────────────── */
:root {
  --brand:   #0a8754;
  --brand-d: #06633c;
  --brand-l: #d1fae5;
  --brand-glow: rgba(10, 135, 84, 0.25);
  --accent:  #f59e0b;
  --ink:     #0b1220;
  --ink-2:   #1e293b;
  --muted:   #64748b;
  --border:  #e2e8f0;
  --bg:      #f8fafc;
  --bg-2:    #f1f5f9;
  --shadow:  0 24px 60px -20px rgba(15,23,42,.18);
  --shadow-sm: 0 4px 12px rgba(15,23,42,.06);
  --r-sm: 8px; --r-md: 12px; --r-lg: 16px; --r-xl: 24px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; color: var(--ink); background: #fff; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; }
a { color: var(--brand); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--brand-d); }

/* ── Topbar ────────────────────────────────────────────────────────────────── */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 40px;
  position: sticky; top: 0; background: rgba(255,255,255,.92); z-index: 50;
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid rgba(15,23,42,.06);
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand .logo-img { height: 32px; width: auto; display: block; }
.brand .logo-img.big { height: 56px; }
.brand .tag-sub { font-weight: 800; font-size: 10px; letter-spacing: 2.5px; color: var(--brand); background: var(--brand-l); padding: 4px 10px; border-radius: 999px; }
.brand.vertical { flex-direction: column; align-items: center; gap: 10px; }
.navlinks { display: flex; gap: 28px; align-items: center; }
.navlinks > a { color: var(--ink-2); font-weight: 500; font-size: 14px; transition: color .15s ease; }
.navlinks > a:hover { color: var(--brand); }

.btn-primary { background: var(--brand); color: #fff !important; padding: 10px 18px; border-radius: var(--r-md); font-weight: 700; transition: all .15s ease; display: inline-block; border: 0; cursor: pointer; }
.btn-primary:hover { background: var(--brand-d); transform: translateY(-1px); box-shadow: 0 8px 20px var(--brand-glow); }
.btn-primary.big { padding: 16px 28px; font-size: 16px; border-radius: var(--r-md); }
.btn-ghost { color: var(--brand) !important; background: #fff; border: 1.5px solid var(--brand); padding: 9px 18px; border-radius: var(--r-md); font-weight: 700; transition: all .15s ease; cursor: pointer; }
.btn-ghost.big { padding: 15px 26px; font-size: 16px; }
.btn-ghost:hover { background: var(--brand); color: #fff !important; }
.btn-ghost.small { padding: 4px 10px; font-size: 12px; border-width: 1px; }

/* ── Hero ──────────────────────────────────────────────────────────────────── */
.hero {
  display: grid; grid-template-columns: 1.15fr 1fr; gap: 60px;
  padding: 100px 40px 80px;
  max-width: 1320px; margin: 0 auto;
  position: relative;
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background:
    radial-gradient(800px 400px at 10% 0%, rgba(10,135,84,.10), transparent 70%),
    radial-gradient(600px 360px at 90% 10%, rgba(245,158,11,.08), transparent 70%);
  z-index: -1; pointer-events: none;
}
.hero-text h1 { font-size: 64px; line-height: 1.02; margin: 0 0 24px; font-weight: 900; letter-spacing: -1.5px; }
.hero-text h1 .accent { background: linear-gradient(120deg, var(--brand) 0%, #16a34a 60%, var(--accent) 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-text .lead { font-size: 19px; color: var(--ink-2); max-width: 56ch; line-height: 1.6; }
.cta-row { display: flex; gap: 14px; margin: 36px 0 28px; flex-wrap: wrap; }
.badges { display: flex; gap: 8px; flex-wrap: wrap; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; background: #fff; color: var(--ink-2); border: 1px solid var(--border); border-radius: 999px; font-size: 13px; font-weight: 600; box-shadow: var(--shadow-sm); }

.hero-card { display: flex; align-items: center; justify-content: center; }
.card-screen { width: 380px; background: var(--ink); border-radius: var(--r-lg); box-shadow: var(--shadow); overflow: hidden; transform: perspective(1200px) rotateY(-6deg) rotateX(2deg); transition: transform .4s ease; }
.card-screen:hover { transform: perspective(1200px) rotateY(-2deg) rotateX(0deg); }
.screen-top { background: #0a0e1a; padding: 12px 14px; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid rgba(255,255,255,.06); }
.dot { width: 11px; height: 11px; border-radius: 50%; }
.dot.red { background: #ef4444; } .dot.yellow { background: #f59e0b; } .dot.green { background: #22c55e; }
.addr { color: #94a3b8; font-size: 12px; margin-left: 8px; font-family: 'JetBrains Mono', ui-monospace, monospace; }
.screen-body { padding: 22px; color: #e2e8f0; }
.metric { background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.06); border-radius: var(--r-md); padding: 14px 16px; margin-bottom: 12px; }
.metric .lbl { color: #94a3b8; font-size: 10px; text-transform: uppercase; letter-spacing: 1.5px; font-weight: 700; }
.metric .val { color: #fff; font-size: 26px; font-weight: 800; margin-top: 4px; letter-spacing: -.5px; }
.metric.green .val { color: var(--accent); }
.liveline { display: flex; align-items: center; gap: 10px; color: #22c55e; font-weight: 700; font-size: 13px; margin-top: 12px; padding: 12px; background: rgba(34,197,94,.08); border: 1px solid rgba(34,197,94,.2); border-radius: var(--r-md); }
.pulse { width: 10px; height: 10px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 0 rgba(34,197,94,.6); animation: pulse 1.6s infinite; }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(34,197,94,.6); }
  70% { box-shadow: 0 0 0 14px rgba(34,197,94,0); }
  100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); }
}

/* ── Sections ──────────────────────────────────────────────────────────────── */
.band { padding: 90px 40px; max-width: 1320px; margin: 0 auto; }
.band.alt { background: var(--bg); max-width: none; margin: 0; padding-left: max(40px, calc((100% - 1320px) / 2)); padding-right: max(40px, calc((100% - 1320px) / 2)); }
.band h2 { font-size: 44px; font-weight: 900; margin: 0 0 14px; text-align: center; letter-spacing: -1px; }
.band .section-sub { text-align: center; color: var(--muted); margin: 0 auto 50px; max-width: 60ch; font-size: 17px; line-height: 1.5; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.step, .feature {
  background: #fff; padding: 28px; border-radius: var(--r-lg);
  border: 1px solid rgba(15,23,42,.06); transition: all .25s ease;
  box-shadow: 0 2px 4px rgba(15,23,42,.02);
}
.step:hover, .feature:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: rgba(10,135,84,.2); }
.step .num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  background: linear-gradient(135deg, var(--brand), #16a34a);
  color: #fff; border-radius: var(--r-md); font-weight: 900;
  margin-bottom: 16px; font-size: 18px;
}
.step h3, .feature h3 { margin: 0 0 10px; font-size: 19px; font-weight: 800; }
.step p, .feature p { color: var(--ink-2); line-height: 1.55; margin: 0; }
.feature ul { padding-left: 22px; margin: 14px 0 0; }
.feature li { margin: 6px 0; color: var(--ink-2); line-height: 1.5; }
.device-row { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.device-spec, .device-protocol { background: #fff; border: 1px solid rgba(15,23,42,.06); border-radius: var(--r-lg); padding: 32px; box-shadow: 0 2px 4px rgba(15,23,42,.02); }
.device-spec h3, .device-protocol h3 { margin: 0 0 12px; font-size: 22px; font-weight: 800; }
.device-spec p, .device-protocol p { color: var(--ink-2); line-height: 1.55; margin: 0 0 18px; }
.spec-list { padding-left: 22px; margin: 0; }
.spec-list li { margin: 8px 0; line-height: 1.5; }
.device-protocol pre { background: #0a0e1a; color: #cbd5e1; border-radius: var(--r-md); padding: 18px; font-size: 12px; overflow-x: auto; font-family: 'JetBrains Mono', ui-monospace, monospace; line-height: 1.55; }

/* ── Stats strip ──────────────────────────────────────────────────────────── */
.stats-strip {
  background: linear-gradient(135deg, var(--brand) 0%, #16a34a 60%, #15803d 100%);
  color: #fff; padding: 36px 40px; position: relative; overflow: hidden;
}
.stats-strip::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(circle at 30% 50%, rgba(255,255,255,.1), transparent 50%);
}
.stats-inner {
  max-width: 1320px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px;
  position: relative;
}
.stat { text-align: center; }
.stat-num { font-size: 40px; font-weight: 900; letter-spacing: -1px; line-height: 1; }
.stat-lbl { font-size: 13px; opacity: .88; margin-top: 6px; text-transform: uppercase; letter-spacing: 1px; font-weight: 600; }
@media (max-width: 760px) {
  .stats-inner { grid-template-columns: 1fr 1fr; gap: 20px; }
  .stat-num { font-size: 32px; }
}

/* ── Footer ────────────────────────────────────────────────────────────────── */
.site-footer { background: var(--ink); color: #cbd5e1; padding: 56px 40px 32px; margin-top: 80px; }
.footer-inner { max-width: 1320px; margin: 0 auto; display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.footer-brand .footer-logo { height: 38px; width: auto; filter: brightness(0) invert(1); margin-bottom: 10px; display: block; }
.footer-brand .footer-prod { font-weight: 900; letter-spacing: 2.5px; font-size: 13px; color: #fff; margin-bottom: 14px; }
.footer-brand div { line-height: 1.6; font-size: 14px; }
.site-footer a { color: #93c5fd; }
.footer-links { display: flex; gap: 20px; flex-wrap: wrap; }
.footer-links a { font-weight: 600; font-size: 14px; }

/* ── Auth pages ──────────────────────────────────────────────────────────────── */
.auth-page {
  background: linear-gradient(180deg, #ecfdf5 0%, #f8fafc 100%);
  min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 32px;
  position: relative; overflow: hidden;
}
.auth-page::before {
  content: ''; position: absolute; inset: 0;
  background:
    radial-gradient(500px 300px at 80% 20%, rgba(10,135,84,.12), transparent 70%),
    radial-gradient(450px 280px at 10% 80%, rgba(245,158,11,.10), transparent 70%);
  pointer-events: none;
}
.auth-card {
  background: #fff; padding: 44px 40px 32px; border-radius: var(--r-xl);
  box-shadow: var(--shadow); width: 100%; max-width: 440px;
  position: relative;
}
.auth-card.wide { max-width: 560px; }
.auth-card .brand { justify-content: center; margin-bottom: 14px; }
.auth-card h1 { margin: 16px 0 6px; font-size: 30px; font-weight: 900; letter-spacing: -.5px; text-align: center; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.form { display: flex; flex-direction: column; gap: 16px; margin-top: 22px; }
.form label { display: flex; flex-direction: column; font-size: 12px; color: var(--ink-2); font-weight: 700; gap: 6px; text-transform: uppercase; letter-spacing: .5px; }
.form input { padding: 14px 16px; font-size: 15px; border: 1.5px solid var(--border); border-radius: var(--r-md); outline: none; font-family: inherit; transition: all .15s ease; background: var(--bg); }
.form input:focus { border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-glow); background: #fff; }
.error { color: #b91c1c; font-size: 13px; min-height: 18px; font-weight: 600; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hide { display: none !important; }
.role-tabs { display: flex; gap: 10px; margin: 22px 0 4px; }
.role-btn { flex: 1; padding: 14px; border-radius: var(--r-md); border: 2px solid var(--border); background: #fff; font-weight: 700; font-size: 14px; cursor: pointer; transition: all .15s ease; color: var(--ink-2); }
.role-btn:hover { border-color: var(--brand); }
.role-btn.active { border-color: var(--brand); background: var(--brand-l); color: var(--brand); }
.auth-card p.muted { text-align: center; }
.auth-card .small { text-align: center; margin-top: 18px; }

@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; padding: 60px 24px 40px; gap: 40px; }
  .hero-text h1 { font-size: 42px; }
  .hero-text .lead { font-size: 16px; }
  .band { padding: 64px 24px; }
  .band h2 { font-size: 32px; }
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .device-row { grid-template-columns: 1fr; }
  .topbar { padding: 14px 20px; }
  .navlinks { gap: 14px; }
  .navlinks > a:not(.btn-primary):not(.btn-ghost) { display: none; }
}
