/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --blue:    #2563EB;
  --blue-lt: #EFF6FF;
  --blue-dk: #1D4ED8;
  --green:   #16A34A;
  --red:     #DC2626;
  --purple:  #7C3AED;
  --orange:  #EA580C;
  --teal:    #0D9488;
  --gray-50:  #F8FAFC;
  --gray-100: #F1F5F9;
  --gray-200: #E2E8F0;
  --gray-400: #94A3B8;
  --gray-600: #475569;
  --gray-800: #1E293B;
  --gray-900: #0F172A;
  --radius:  14px;
  --shadow:  0 4px 24px rgba(0,0,0,.08);
  --shadow-lg: 0 16px 48px rgba(0,0,0,.14);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--gray-50);
  color: var(--gray-800);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }

/* ============================================================
   LAYOUT
   ============================================================ */
.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================================
   HEADER
   ============================================================ */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(248, 250, 252, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--gray-200);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-icon {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}

.logo-icon.small { width: 28px; height: 28px; }

.logo-text {
  font-size: 1.05rem;
  color: var(--gray-900);
  letter-spacing: -0.01em;
}

.logo-text strong { color: var(--blue); }

nav {
  display: flex;
  gap: 32px;
}

nav a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--gray-600);
  transition: color .2s;
}

nav a:hover { color: var(--blue); }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
  border: none;
}

.btn svg { width: 16px; height: 16px; flex-shrink: 0; }

.btn-primary {
  background: var(--blue);
  color: #fff;
  box-shadow: 0 2px 12px rgba(37,99,235,.35);
}

.btn-primary:hover {
  background: var(--blue-dk);
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(37,99,235,.45);
}

.btn-ghost {
  background: transparent;
  color: var(--gray-600);
  border: 1.5px solid var(--gray-200);
}

.btn-ghost:hover {
  background: var(--gray-100);
  color: var(--gray-800);
}

.btn-large {
  padding: 15px 32px;
  font-size: 1rem;
  border-radius: 12px;
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  padding: 80px 0 100px;
  overflow: hidden;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.badge {
  display: inline-block;
  background: var(--blue-lt);
  color: var(--blue);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 20px;
  margin-bottom: 20px;
}

.hero-text h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--gray-900);
  margin-bottom: 20px;
}

.gradient-text {
  background: linear-gradient(135deg, var(--blue) 0%, #7C3AED 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-sub {
  font-size: 1.05rem;
  color: var(--gray-600);
  max-width: 460px;
  margin-bottom: 36px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.hero-meta {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.meta-item {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.82rem;
  color: var(--gray-600);
  font-weight: 500;
}

.meta-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.meta-dot.green { background: var(--green); box-shadow: 0 0 0 3px rgba(22,163,74,.15); }
.meta-dot.blue  { background: var(--blue);  box-shadow: 0 0 0 3px rgba(37,99,235,.15); }

/* ── Phone Mockup ── */
.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
}

.glow-blob {
  position: absolute;
  width: 340px;
  height: 340px;
  background: radial-gradient(circle, rgba(37,99,235,.18) 0%, transparent 70%);
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 0;
}

.phone-mockup {
  position: relative;
  z-index: 1;
  width: 280px;
  background: var(--gray-900);
  border-radius: 36px;
  padding: 16px;
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(255,255,255,.06);
}

.phone-screen {
  background: #fff;
  border-radius: 24px;
  overflow: hidden;
  padding: 16px;
}

.screen-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}

.screen-dot {
  width: 8px;
  height: 8px;
  background: var(--blue);
  border-radius: 50%;
}

.screen-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--gray-900);
}

.stat-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 16px;
}

.stat-card {
  border-radius: 10px;
  padding: 10px;
  text-align: center;
}

.stat-card.blue   { background: #EFF6FF; }
.stat-card.red    { background: #FEF2F2; }
.stat-card.green  { background: #F0FDF4; }
.stat-card.purple { background: #F5F3FF; }

.stat-icon { font-size: 1rem; margin-bottom: 2px; }

.stat-val {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--gray-900);
  line-height: 1;
}

.stat-lbl {
  font-size: 0.62rem;
  color: var(--gray-400);
  font-weight: 500;
  margin-top: 2px;
}

.appt-list { display: flex; flex-direction: column; gap: 8px; }

.appt-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px;
  background: var(--gray-50);
  border-radius: 8px;
}

.appt-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  font-size: 0.6rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.appt-info { flex: 1; min-width: 0; }

.appt-name {
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--gray-900);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.appt-time {
  font-size: 0.6rem;
  color: var(--gray-400);
}

.appt-badge {
  font-size: 0.55rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
}

.appt-badge.scheduled { background: #EFF6FF; color: var(--blue); }
.appt-badge.done      { background: #F0FDF4; color: var(--green); }
.appt-badge.critical  { background: #FEF2F2; color: var(--red); }

/* ============================================================
   FEATURES
   ============================================================ */
.features {
  padding: 96px 0;
  background: #fff;
  border-top: 1px solid var(--gray-200);
  border-bottom: 1px solid var(--gray-200);
}

.section-label {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 12px;
}

.section-label.light { color: rgba(255,255,255,.7); }

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--gray-900);
  margin-bottom: 56px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 28px;
  transition: box-shadow .2s, transform .2s;
}

.feature-card:hover {
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.feature-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.feature-icon svg { width: 20px; height: 20px; }

.feature-icon.blue   { background: #EFF6FF; color: var(--blue); }
.feature-icon.green  { background: #F0FDF4; color: var(--green); }
.feature-icon.purple { background: #F5F3FF; color: var(--purple); }
.feature-icon.red    { background: #FEF2F2; color: var(--red); }
.feature-icon.orange { background: #FFF7ED; color: var(--orange); }
.feature-icon.teal   { background: #F0FDFA; color: var(--teal); }

.feature-card h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--gray-900);
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 0.88rem;
  color: var(--gray-600);
  line-height: 1.65;
}

/* ============================================================
   DOWNLOAD
   ============================================================ */
.download {
  padding: 96px 0;
}

.download-card {
  background: linear-gradient(135deg, var(--blue) 0%, #4F46E5 100%);
  border-radius: 24px;
  padding: 56px 64px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 64px;
  align-items: center;
  box-shadow: 0 24px 64px rgba(37,99,235,.35);
}

.download-left h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
}

.download-left p {
  color: rgba(255,255,255,.75);
  font-size: 1rem;
  margin-bottom: 32px;
}

.download-left p code {
  background: rgba(255,255,255,.15);
  padding: 2px 7px;
  border-radius: 5px;
  font-size: 0.88em;
  font-family: 'Courier New', monospace;
}

.build-info {
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 28px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.build-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
}

.build-key { color: rgba(255,255,255,.6); font-weight: 500; }
.build-val { color: #fff; font-weight: 600; font-family: 'Courier New', monospace; }

.install-note {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  font-size: 0.8rem;
  color: rgba(255,255,255,.6);
  margin-top: 16px;
  line-height: 1.5;
}

.install-note svg { flex-shrink: 0; margin-top: 2px; }
.install-note strong { color: rgba(255,255,255,.85); }

/* QR placeholder */
.qr-placeholder {
  width: 160px;
  height: 160px;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: rgba(255,255,255,.5);
}

.qr-placeholder svg { width: 80px; height: 80px; }
.qr-placeholder span { font-size: 0.72rem; font-weight: 500; }

/* ============================================================
   FOOTER
   ============================================================ */
footer {
  background: var(--gray-900);
  padding: 32px 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-inner .logo-text { color: #fff; }

.footer-copy {
  font-size: 0.82rem;
  color: var(--gray-400);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 48px;
    text-align: center;
  }

  .hero-sub { max-width: 100%; }

  .hero-actions { justify-content: center; }

  .hero-meta { justify-content: center; }

  .hero-visual { order: -1; }

  .features-grid { grid-template-columns: repeat(2, 1fr); }

  .download-card {
    grid-template-columns: 1fr;
    padding: 40px 32px;
    gap: 40px;
    text-align: center;
  }

  .download-right { display: flex; justify-content: center; }

  .build-row { flex-direction: column; align-items: flex-start; gap: 2px; }
}

@media (max-width: 600px) {
  .features-grid { grid-template-columns: 1fr; }

  nav { gap: 20px; }

  .download-card { padding: 32px 20px; }

  .hero { padding: 56px 0 72px; }

  .phone-mockup { width: 240px; }
}
