/* ============================================================
   ascom-shop · Design System
   Palette : Navy #0f172a + Emerald #059669 · Inter · Mobile-first
   ============================================================ */

:root {
  --navy:   #0f172a;
  --navy-2: #1e293b;
  --navy-3: #334155;
  --emerald:#059669;
  --emerald-dark: #047857;
  --emerald-light: #d1fae5;
  --white:  #ffffff;
  --gray-50: #f8fafc;
  --gray-100:#f1f5f9;
  --gray-200:#e2e8f0;
  --gray-400:#94a3b8;
  --gray-600:#475569;
  --text:    #0f172a;
}

/* ── Base ── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: hidden; }
body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--white);
  margin: 0;
  overflow-x: hidden;
}

/* ── Utilities ── */
.text-emerald { color: var(--emerald) !important; }
.bg-navy      { background-color: var(--navy) !important; }
.bg-navy-2    { background-color: var(--navy-2) !important; }
.bg-emerald   { background-color: var(--emerald) !important; }
.btn-emerald  {
  background-color: var(--emerald);
  color: #fff;
  border: none;
  transition: background .2s;
}
.btn-emerald:hover, .btn-emerald:focus {
  background-color: var(--emerald-dark);
  color: #fff;
}
.btn-outline-emerald {
  color: var(--emerald);
  border: 2px solid var(--emerald);
  background: transparent;
  transition: all .2s;
}
.btn-outline-emerald:hover {
  background: var(--emerald);
  color: #fff;
}

/* ── Navbar ── */
.navbar-landing {
  background: rgba(15,23,42,.97);
  backdrop-filter: blur(8px);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.navbar-landing .nav-link {
  color: rgba(255,255,255,.8) !important;
  font-weight: 500;
  font-size: .9rem;
  transition: color .2s;
}
.navbar-landing .nav-link:hover { color: var(--emerald) !important; }
.navbar-brand-text {
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff !important;
  letter-spacing: -.02em;
}
.navbar-brand-text span { color: var(--emerald); }

/* ── Hero ── */
.hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 60%, #0d3d2e 100%);
  min-height: 90vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 70% 50%, rgba(5,150,105,.15) 0%, transparent 60%);
  pointer-events: none;
}
.hero-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  color: #fff;
  line-height: 1.15;
  letter-spacing: -.03em;
}
.hero-subtitle {
  color: rgba(255,255,255,.7);
  font-size: 1.15rem;
  line-height: 1.7;
  max-width: 520px;
}
.hero-badge {
  display: inline-block;
  background: rgba(5,150,105,.2);
  border: 1px solid rgba(5,150,105,.4);
  color: var(--emerald-light);
  padding: .35rem .85rem;
  border-radius: 2rem;
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .05em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}
.hero-visual {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 1rem;
  padding: 1.5rem;
  backdrop-filter: blur(4px);
}

/* ── Stats bar ── */
.stats-bar {
  background: var(--navy-2);
  padding: 2rem 0;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.stat-item { text-align: center; }
.stat-number {
  font-size: 2rem;
  font-weight: 800;
  color: var(--emerald);
  display: block;
}
.stat-label {
  color: rgba(255,255,255,.6);
  font-size: .85rem;
}

/* ── Sections ── */
.section-title {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -.03em;
  line-height: 1.2;
}
.section-label {
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--emerald);
}

/* ── Feature cards ── */
.feature-card {
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: .875rem;
  padding: 1.75rem;
  height: 100%;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(5,150,105,.1);
  border-color: rgba(5,150,105,.3);
}
.feature-icon {
  width: 48px; height: 48px;
  background: var(--emerald-light);
  border-radius: .75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  color: var(--emerald);
  font-size: 1.4rem;
}

/* ── Steps ── */
.step-number {
  width: 48px; height: 48px;
  background: var(--emerald);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  flex-shrink: 0;
}

/* ── Pricing cards ── */
.pricing-card {
  border: 1px solid var(--gray-200);
  border-radius: 1rem;
  padding: 2rem;
  height: 100%;
  transition: transform .2s, box-shadow .2s;
  position: relative;
}
.pricing-card:hover { transform: translateY(-4px); box-shadow: 0 16px 40px rgba(0,0,0,.08); }
.pricing-card.featured {
  background: var(--navy);
  color: #fff;
  border-color: var(--emerald);
  transform: scale(1.03);
}
.pricing-card.featured:hover { transform: scale(1.03) translateY(-4px); }
.pricing-badge {
  position: absolute;
  top: -13px; left: 50%;
  transform: translateX(-50%);
  background: var(--emerald);
  color: #fff;
  font-size: .75rem;
  font-weight: 700;
  padding: .25rem .85rem;
  border-radius: 2rem;
  letter-spacing: .05em;
  text-transform: uppercase;
}
.pricing-price {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -.04em;
}
.pricing-period { font-size: .9rem; color: var(--gray-400); }
.pricing-card.featured .pricing-period { color: rgba(255,255,255,.6); }
.feature-check { color: var(--emerald); }
.pricing-card.featured .feature-check { color: var(--emerald-light); }
.feature-off { color: var(--gray-300); }
.pricing-card.featured .feature-off { color: rgba(255,255,255,.2); }
.feature-off .feature-label { text-decoration: line-through; }

/* ── Billing toggle ── */
.pricing-toggle { background: var(--gray-100); border-radius: 2rem; padding: .25rem; gap: .25rem; display: inline-flex; }
.toggle-btn { border: none; background: transparent; border-radius: 2rem; padding: .45rem 1.1rem; font-weight: 600; font-size: .85rem; cursor: pointer; transition: all .2s; color: var(--gray-500); white-space: nowrap; }
.toggle-btn.active { background: #fff; color: var(--navy); box-shadow: 0 1px 4px rgba(0,0,0,.12); }
.toggle-savings { display: inline-block; background: var(--emerald); color: #fff; font-size: .65rem; font-weight: 700; padding: .1rem .4rem; border-radius: 1rem; margin-inline-start: .25rem; vertical-align: middle; }
.pricing-billing { font-size: .75rem; color: var(--gray-400); min-height: 1.1rem; margin-bottom: 1.25rem; }
.pricing-card.featured .pricing-billing { color: rgba(255,255,255,.45); }

/* ── CTA final ── */
.cta-final {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 100%);
  color: #fff;
  padding: 5rem 0;
}

/* ── Footer ── */
.footer {
  background: var(--navy);
  color: rgba(255,255,255,.6);
  padding: 3rem 0 1.5rem;
}
.footer a { color: rgba(255,255,255,.6); text-decoration: none; transition: color .2s; }
.footer a:hover { color: var(--emerald); }
.footer-brand { color: #fff; font-weight: 700; font-size: 1.1rem; }

/* ── Auth pages ── */
.auth-wrapper {
  min-height: 100vh;
  background: var(--gray-50);
  display: flex;
  align-items: center;
  padding: 2rem 0;
}
.auth-card {
  background: #fff;
  border: 1px solid var(--gray-200);
  border-radius: 1rem;
  padding: 2.5rem;
  box-shadow: 0 4px 24px rgba(0,0,0,.06);
}

/* ── Dashboard ── */
.sidebar {
  width: 260px;
  background: var(--navy);
  min-height: 100vh;
  position: fixed;
  left: 0; top: 0;
  display: flex;
  flex-direction: column;
  padding: 1.5rem 0;
  z-index: 100;
}
.sidebar-brand {
  padding: 0 1.5rem 1.5rem;
  border-bottom: 1px solid rgba(255,255,255,.08);
  margin-bottom: 1rem;
}
.sidebar-nav .nav-link {
  color: rgba(255,255,255,.7);
  padding: .65rem 1.5rem;
  font-size: .9rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: .75rem;
  transition: all .2s;
  border-left: 3px solid transparent;
}
.sidebar-nav .nav-link:hover,
.sidebar-nav .nav-link.active {
  color: #fff;
  background: rgba(255,255,255,.06);
  border-left-color: var(--emerald);
}
.main-content {
  margin-left: 260px;
  min-height: 100vh;
  background: var(--gray-50);
}
.topbar {
  background: #fff;
  border-bottom: 1px solid var(--gray-200);
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.kpi-card {
  background: #fff;
  border: 1px solid var(--gray-200);
  border-radius: .875rem;
  padding: 1.5rem;
}
.kpi-value {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -.04em;
}

/* ── Deploy button ── */
.deploy-zone {
  border: 2px dashed var(--gray-200);
  border-radius: 1rem;
  padding: 3rem;
  text-align: center;
  transition: border-color .2s;
}
.deploy-zone:hover { border-color: var(--emerald); }

/* ── Status badges ── */
.badge-pending  { background:#e2e8f0; color:#475569; }
.badge-running  { background:#fef3c7; color:#92400e; }
.badge-success  { background:#d1fae5; color:#065f46; }
.badge-failed   { background:#fee2e2; color:#991b1b; }

/* ── Responsive ── */
@media (max-width: 768px) {
  .sidebar { display: none; }
  .main-content { margin-left: 0; }
  .pricing-card.featured { transform: none; }
}

/* ── Mobile xs (≤575px) — RTL & overflow fixes ── */
@media (max-width: 575.98px) {
  /* Pricing toggle : pile en colonne sur xs pour éviter l'overflow RTL/LTR */
  .pricing-toggle {
    flex-direction: column;
    width: 100%;
    border-radius: .875rem;
    align-items: stretch;
  }
  .toggle-btn {
    text-align: center;
    border-radius: .625rem !important;
    padding: .5rem 1rem;
  }
  .toggle-savings {
    font-size: .6rem;
    padding: .08rem .3rem;
  }

  /* Hero : hauteur auto sur mobile */
  .hero { min-height: 70vh; }

  /* Auth card : padding réduit */
  .auth-card { padding: 1.5rem 1.25rem; }

  /* Pricing cards : enlever le scale sur featured */
  .pricing-card.featured { transform: none; }

  /* Section paddings réduits */
  .cta-final { padding: 3rem 0; }
}
