@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=Space+Grotesk:wght@500;600;700&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  --font-body: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-display: 'Space Grotesk', 'Plus Jakarta Sans', -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;
}

:root {
  --primary: #fa7268;
  --primary-hover: #f95e52;
  --primary-dark: #e64a3f;
  --primary-light: #ffd4cf;
  --card: #ffffff;
  --bg: #ffffff;
  --bg-soft: #f8f9fb;
  --text: #1f2233;
  --text-soft: #6b6f80;
  --border: #ececf2;
  --success: #34d399;
  --warning: #fbbf24;
  --danger: #ef4444;
  --shadow: 0 4px 18px rgba(20, 20, 50, 0.06);
  --radius: 12px;
}

[data-theme="dark"] {
  --bg: #0f1117;
  --bg-soft: #181b24;
  --card: #1c1f2a;
  --text: #f1f1f5;
  --text-soft: #c5c8d4;
  --border: #2a2e3d;
  --shadow: 0 4px 18px rgba(0, 0, 0, 0.4);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  font-family: var(--font-body);
  font-feature-settings: "ss01","cv11";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, select, textarea { font-family: inherit; }

h1, h2, h3, h4, h5, h6,
.section-title, .section-heading,
.hero h1, .pricing-card h3, .api-card h3, .stat-num,
.footer-logo, .nav-logo, .logo,
.feature-name, .card-title {
  font-family: var(--font-display);
  letter-spacing: -0.02em;
  font-feature-settings: "ss02","ss05";
}

code, pre, kbd, samp,
.mono, .code, .endpoint-url, .api-url,
.copy-url, .endpoint-code {
  font-family: var(--font-mono);
  font-feature-settings: "calt","liga";
}

/* ===== NAVBAR ===== */
.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 6%;
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid transparent;
}
.brand {
  font-weight: 800;
  font-size: 22px;
  letter-spacing: -0.3px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: inherit;
}
.brand-logo {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  display: block;
}
.brand .accent { color: var(--primary); }
.nav-links {
  display: flex;
  gap: 32px;
  align-items: center;
}
.nav-links a {
  font-weight: 600;
  color: var(--text-soft);
  font-size: 15px;
  transition: color .2s;
}
.nav-links a.active, .nav-links a:hover { color: var(--primary); }
.nav-actions {
  display: flex;
  gap: 14px;
  align-items: center;
}
.nav-actions a.login-link {
  color: var(--text);
  font-weight: 600;
  font-size: 15px;
}
.nav-mobile-actions { display: none; }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 26px;
  background: var(--primary);
  color: #fff;
  border-radius: 999px;
  font-weight: 700;
  font-size: 14px;
  transition: background .2s, transform .1s;
  border: none;
  cursor: pointer;
}
.btn:hover { background: var(--primary-hover); }
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .6; cursor: not-allowed; }
.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 1.5px solid var(--primary);
}
.btn-outline:hover { background: var(--primary-light); }
.btn-block { width: 100%; }
.btn-sm { padding: 7px 16px; font-size: 13px; }

/* ===== HERO ===== */
.hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  padding: 60px 6% 90px;
  max-width: 1300px;
  margin: 0 auto;
}
.hero h1 {
  font-size: 54px;
  font-weight: 800;
  color: var(--primary);
  line-height: 1.05;
  letter-spacing: -1.5px;
  margin-bottom: 22px;
}
.hero p {
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 30px;
  font-size: 17px;
  max-width: 480px;
}
.hero-image {
  display: flex;
  justify-content: center;
  align-items: center;
}
.hero-image svg {
  width: 100%;
  max-width: 460px;
  height: auto;
}

/* ===== SECTIONS ===== */
.section {
  padding: 70px 6%;
  max-width: 1300px;
  margin: 0 auto;
}
.section-title {
  text-align: center;
  font-size: 40px;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 8px;
}
.section-subtitle {
  text-align: center;
  color: var(--text-soft);
  margin-bottom: 50px;
}
.section-heading {
  font-size: 36px;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 16px;
}

/* ===== PRICING ===== */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
  max-width: 1100px;
  margin: 0 auto;
}
.pricing-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.pricing-head {
  background: var(--primary);
  color: #fff;
  text-align: center;
  padding: 28px 20px;
  font-weight: 700;
}
.pricing-head .plan-name { font-size: 20px; margin-bottom: 6px; }
.pricing-head .plan-price { font-size: 26px; font-weight: 800; }
.pricing-features {
  list-style: none;
  padding: 12px 22px 22px;
}
.pricing-features li {
  display: flex;
  justify-content: space-between;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  color: var(--text-soft);
}
.pricing-features li:last-child { border-bottom: none; }
.pricing-features li span:last-child { color: var(--text); font-weight: 600; }
.pricing-pay {
  display: flex;
  justify-content: center;
  gap: 14px;
  padding: 14px;
  border-top: 1px solid var(--border);
  color: var(--text-soft);
  font-weight: 700;
  font-size: 14px;
  align-items: center;
}
.pricing-actions { padding: 0 22px 22px; display: flex; flex-direction: column; gap: 10px; }

/* ===== STATS ===== */
/* ===== STATS BAND ===== */
.stats-band {
  padding: 56px 6% 24px;
  max-width: 1300px;
  margin: 0 auto;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.stat-card {
  position: relative;
  padding: 24px 22px;
  border-radius: 18px;
  background: var(--card);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.stat-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(250,114,104,.08), rgba(250,114,104,0) 60%);
  pointer-events: none;
}
.stat-card:hover {
  transform: translateY(-4px);
  border-color: rgba(250,114,104,.4);
  box-shadow: 0 16px 36px -18px rgba(250,114,104,.55);
}
.stat-icon {
  position: relative;
  width: 40px; height: 40px;
  border-radius: 12px;
  display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, rgba(250,114,104,.18), rgba(250,114,104,.08));
  color: var(--primary);
  margin-bottom: 14px;
}
.stat-icon svg { width: 20px; height: 20px; }
.stat-num {
  position: relative;
  font-size: 34px; font-weight: 800;
  color: var(--text);
  letter-spacing: -.5px;
  line-height: 1.1;
}
.stat-label {
  position: relative;
  margin-top: 4px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-soft);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ===== API EXPLAINER ===== */
.api-explain {
  padding: 30px 6% 70px;
  max-width: 1300px;
  margin: 0 auto;
}
.api-explain-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}
.api-card {
  position: relative;
  padding: 28px;
  border-radius: 20px;
  background: var(--card);
  border: 1px solid var(--border);
  transition: transform .25s ease, box-shadow .25s ease;
  overflow: hidden;
}
.api-card::after {
  content: "";
  position: absolute;
  width: 220px; height: 220px;
  right: -80px; top: -80px;
  background: radial-gradient(circle, rgba(250,114,104,.12), rgba(250,114,104,0) 70%);
  pointer-events: none;
}
.api-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 48px -24px rgba(15,17,23,.18);
}
.api-card-icon {
  width: 48px; height: 48px;
  border-radius: 14px;
  display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--primary), #ff9b8a);
  color: #fff;
  box-shadow: 0 10px 24px -10px rgba(250,114,104,.7);
  margin-bottom: 16px;
}
.api-card-icon svg { width: 22px; height: 22px; }
.api-card h3 {
  font-size: 20px; font-weight: 800;
  margin: 0 0 10px;
  color: var(--text);
  letter-spacing: -.3px;
}
.api-card p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.7;
  color: var(--text-soft);
}

/* ===== FOOTER (modernized) ===== */
.footer {
  position: relative;
  margin-top: 24px;
  padding: 48px 6% 28px;
  background: var(--bg-soft);
  border-top: 1px solid var(--border);
  color: var(--text-soft);
  font-size: 14px;
}
.footer-top {
  max-width: 1300px;
  margin: 0 auto 28px;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 36px;
  align-items: start;
}
.footer-brand .footer-logo {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 20px; font-weight: 800; color: var(--text);
  margin-bottom: 12px;
}
.footer-brand .footer-logo .accent { color: var(--primary); }
.footer-brand p { font-size: 13.5px; line-height: 1.6; max-width: 360px; }
.footer-col h4 {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--text);
  margin: 0 0 14px;
}
.footer-contact {
  display: flex; flex-direction: column; gap: 10px;
}
.footer-contact a {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--text-soft);
  text-decoration: none;
  font-size: 13.5px;
  transition: color .15s, transform .15s;
}
.footer-contact a:hover { color: var(--primary); transform: translateX(2px); }
.footer-contact .ico {
  width: 28px; height: 28px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--primary);
  flex-shrink: 0;
}
.footer-contact .ico svg { width: 14px; height: 14px; }
.footer-socials { display: flex; gap: 10px; flex-wrap: wrap; }
.footer-socials a {
  width: 38px; height: 38px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text-soft);
  transition: all .2s ease;
}
.footer-socials a:hover {
  color: #fff;
  background: var(--primary);
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 8px 18px -8px rgba(250,114,104,.6);
}
.footer-socials a svg { width: 16px; height: 16px; }
.footer-bottom {
  max-width: 1300px;
  margin: 0 auto;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px;
  font-size: 13px;
}
.footer-bottom strong { color: var(--primary); }
.footer-bottom .footer-mini-nav { display: flex; gap: 18px; }
.footer-bottom .footer-mini-nav a {
  color: var(--text-soft);
  text-decoration: none;
  transition: color .15s;
}
.footer-bottom .footer-mini-nav a:hover { color: var(--primary); }

/* ===== AUTH ===== */
.auth-wrapper {
  min-height: calc(100vh - 100px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}
.auth-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  width: 100%;
  max-width: 440px;
  box-shadow: var(--shadow);
}
.auth-card h2 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 22px;
}
.form-group { margin-bottom: 16px; }
.form-group label {
  display: block;
  font-weight: 600;
  font-size: 13px;
  margin-bottom: 6px;
}
.form-control {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  transition: border-color .2s;
}
.form-control:focus {
  outline: none;
  border-color: var(--primary);
}
.pw-field { position: relative; }
.pw-field .form-control { padding-right: 44px; }
.pw-toggle {
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  border-radius: 6px;
  color: var(--text-soft);
  cursor: pointer;
  padding: 0;
  transition: color .15s, background .15s;
}
.pw-toggle:hover { color: var(--primary); background: var(--bg-soft); }
.pw-toggle svg { width: 18px; height: 18px; pointer-events: none; }
.pw-toggle .pw-icon-off { display: none; }
.pw-toggle.is-on .pw-icon-on { display: none; }
.pw-toggle.is-on .pw-icon-off { display: inline-block; }
.oauth-divider {
  display: flex; align-items: center; gap: 12px;
  margin: 18px 0 14px;
  font-size: 12px; color: var(--text-soft); text-transform: uppercase; letter-spacing: 1px;
}
.oauth-divider::before, .oauth-divider::after {
  content: ""; flex: 1; height: 1px; background: var(--border);
}
.btn-oauth {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; padding: 11px 14px;
  border-radius: 8px; border: 1px solid var(--border);
  background: var(--bg); color: var(--text);
  font-weight: 600; font-size: 14px; cursor: pointer;
  transition: background .15s, border-color .15s, transform .1s;
  text-decoration: none;
}
.btn-oauth:hover { background: var(--bg-soft); border-color: var(--text-soft); }
.btn-oauth:active { transform: scale(.99); }
.btn-oauth svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn-github { color: #fff; background: #24292f; border-color: #24292f; }
.btn-github:hover { background: #32383f; border-color: #32383f; color: #fff; }
.auth-link {
  text-align: center;
  margin-top: 16px;
  font-size: 14px;
  color: var(--text-soft);
}
.auth-link a { color: var(--primary); font-weight: 700; }
.auth-link.spread { display: flex; justify-content: space-between; padding: 8px 6px 0; }
.auth-msg {
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 14px;
  display: none;
}
.auth-msg.error { background: #fde7e7; color: #b91c1c; display: block; }
.auth-msg.success { background: #d1fae5; color: #065f46; display: block; }

/* ===== DASHBOARD LAYOUT ===== */
.app-layout {
  display: grid;
  grid-template-columns: 250px 1fr;
  min-height: 100vh;
}
.sidebar {
  background: var(--bg);
  border-right: 1px solid var(--border);
  padding: 24px 0 0;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.sidebar .brand { padding: 0 24px 22px; font-size: 22px; flex-shrink: 0; }
.sidebar nav {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding-bottom: 16px;
  -webkit-overflow-scrolling: touch;
}
.sidebar nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 24px;
  color: var(--text-soft);
  font-weight: 600;
  font-size: 14px;
  transition: all .15s;
  border-left: 3px solid transparent;
}
.sidebar nav a:hover { color: var(--text); background: var(--bg-soft); }
.sidebar nav a.active {
  color: #fff;
  background: var(--primary);
}
.sidebar nav a svg { width: 18px; height: 18px; flex-shrink: 0; }
.nav-divider {
  height: 1px;
  background: var(--border);
  margin: 12px 20px;
}

.main {
  background: var(--bg-soft);
  min-height: 100vh;
  padding: 24px 32px;
  min-width: 0;
}
.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  gap: 14px;
  flex-wrap: wrap;
}
.topbar-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}
.sidebar-toggle { display: none; }
.page-title {
  font-size: 24px;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.topbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.search-box {
  position: relative;
  width: 280px;
  max-width: 100%;
}
.search-box input {
  width: 100%;
  padding: 9px 14px 9px 38px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
}
.search-box svg {
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: var(--text-soft);
}
.user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 6px 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg);
  transition: background .15s, border-color .15s;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}
.user-chip:hover { background: var(--bg-soft); border-color: var(--primary); }
.user-meta { text-align: right; line-height: 1.2; }
.user-chip .name { font-weight: 700; font-size: 14px; }
.user-chip .email { font-size: 12px; color: var(--text-soft); }
.user-menu-wrap { position: relative; }
.user-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 200px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(20,20,50,0.12);
  padding: 8px;
  display: none;
  z-index: 250;
}
.user-menu.open { display: block; }
.user-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  color: var(--text);
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  transition: background .15s, color .15s;
}
.user-menu-item svg { width: 18px; height: 18px; flex-shrink: 0; }
.user-menu-item:hover { background: var(--bg-soft); }
.user-menu-item.danger { color: var(--danger); }
.user-menu-item.danger:hover { background: rgba(239,68,68,.08); }
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.4);
  z-index: 150;
}
.sidebar-overlay.open { display: block; }
.avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
}
.theme-toggle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ===== CARDS / STATS ===== */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}
.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.stat-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 20px;
}
.stat-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.stat-icon svg { width: 22px; height: 22px; }
.stat-body { display: flex; flex-direction: column; min-width: 0; }
.stat-label { color: var(--text-soft); font-size: 13px; font-weight: 600; margin-bottom: 2px; }
.stat-value { font-size: 22px; font-weight: 800; color: var(--text); line-height: 1.2; }
.card-title {
  color: var(--text-soft);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.card-value {
  font-size: 26px;
  font-weight: 800;
  color: var(--primary);
}
.panel {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  margin-bottom: 24px;
}
.panel h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 14px;
}

/* ===== TABLE ===== */
.table-wrap {
  overflow-x: auto;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
table.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  min-width: 700px;
}
.data-table thead th {
  background: var(--bg);
  text-align: left;
  padding: 14px 18px;
  color: var(--text-soft);
  font-weight: 700;
  font-size: 13px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.data-table tbody td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.data-table tbody tr:last-child td { border-bottom: none; }
.data-table tbody tr:hover { background: var(--bg-soft); }
.badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}
.badge.active { background: #d1fae5; color: #047857; }
.badge.blocked { background: #fee2e2; color: #b91c1c; }
.badge.unpaid, .badge.pending { background: #fef3c7; color: #92400e; }
.badge.paid { background: #d1fae5; color: #047857; }
.badge.cancelled { background: #fee2e2; color: #b91c1c; }
.badge.get { background: #dbeafe; color: #1d4ed8; }
.badge.post { background: #dcfce7; color: #166534; }
.badge.free { background: #e5e7eb; color: #374151; }
.badge.premium { background: #ffd4cf; color: #b91c1c; }
.badge.vip { background: #fde68a; color: #92400e; }
.badge.admin { background: #1f2233; color: #fff; }
.btn-danger { background: var(--danger); }
.btn-danger:hover { background: #dc2626; }
.btn-success { background: var(--success); color: #fff; }
.btn-success:hover { background: #10b981; }
.action-bar { display: flex; flex-wrap: wrap; gap: 8px; }
.action-bar .btn { white-space: nowrap; }
.muted { color: var(--text-soft); font-size: 13px; }
.kv-row { display: flex; justify-content: space-between; gap: 14px; padding: 10px 0; border-bottom: 1px dashed var(--border); font-size: 14px; }
.kv-row:last-child { border-bottom: none; }
.kv-row .k { color: var(--text-soft); font-weight: 600; }
.kv-row .v { color: var(--text); font-weight: 700; word-break: break-all; text-align: right; }

/* ===== JAKARTA CLOCK ===== */
.jakarta-clock {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.jakarta-clock .clock-tz { color: var(--primary); font-size: 11px; }

/* Plan Card (dashboard active plan) — credit card style */
.plan-card {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background:
    radial-gradient(120% 80% at 0% 0%, rgba(255,255,255,.28) 0%, rgba(255,255,255,0) 55%),
    radial-gradient(80% 100% at 100% 100%, rgba(0,0,0,.18) 0%, rgba(0,0,0,0) 55%),
    linear-gradient(135deg, #ff8579 0%, #fa7268 55%, #ef5d51 100%);
  color: #fff;
  border-radius: 22px;
  padding: 20px 22px 18px;
  margin: 4px auto 24px;
  width: 100%;
  max-width: 520px;
  aspect-ratio: 16 / 10;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow:
    0 1px 0 rgba(255,255,255,.45) inset,
    0 -1px 0 rgba(0,0,0,.18) inset,
    0 24px 50px -20px rgba(239, 93, 81, .6),
    0 8px 18px -8px rgba(0,0,0,.25);
  transform: perspective(1000px) rotateX(2deg);
  transition: transform .35s ease, box-shadow .35s ease;
}
.plan-card:hover {
  transform: perspective(1000px) rotateX(0deg) translateY(-2px);
  box-shadow:
    0 1px 0 rgba(255,255,255,.45) inset,
    0 -1px 0 rgba(0,0,0,.18) inset,
    0 30px 60px -20px rgba(239, 93, 81, .7),
    0 10px 22px -8px rgba(0,0,0,.3);
}
.plan-card-shine {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(115deg, transparent 30%, rgba(255,255,255,.18) 45%, transparent 60%),
    repeating-linear-gradient(45deg, rgba(255,255,255,.04) 0 2px, transparent 2px 8px);
  pointer-events: none;
  mix-blend-mode: screen;
  z-index: 0;
}
.plan-card-watermark {
  position: absolute;
  right: -20px;
  bottom: -20px;
  width: 200px;
  height: 200px;
  color: rgba(255, 255, 255, .12);
  pointer-events: none;
  z-index: 0;
}
.plan-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  position: relative;
  z-index: 1;
}
.plan-card-top-left { display: flex; align-items: center; gap: 10px; }
.plan-card-top-right { display: flex; align-items: center; gap: 12px; }
.plan-active-pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255, 255, 255, .22);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.28);
}
.plan-active-pill svg { width: 14px; height: 14px; }
.plan-chip {
  display: inline-block;
  width: 38px;
  height: 28px;
  border-radius: 6px;
  background:
    linear-gradient(135deg, #f4d27a 0%, #c99a3e 50%, #a07724 100%);
  box-shadow:
    0 1px 0 rgba(255,255,255,.5) inset,
    0 -1px 0 rgba(0,0,0,.25) inset,
    0 2px 4px rgba(0,0,0,.22);
  position: relative;
  padding: 4px;
}
.plan-chip-inner {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(2, 1fr);
  gap: 2px;
  width: 100%;
  height: 100%;
}
.plan-chip-inner span {
  background: linear-gradient(135deg, rgba(0,0,0,.25), rgba(255,255,255,.15));
  border-radius: 1.5px;
}
.plan-active-dot {
  width: 8px; height: 8px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, .25);
  animation: planPulse 1.6s ease-in-out infinite;
}
@keyframes planPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, .35); }
  50% { box-shadow: 0 0 0 6px rgba(255, 255, 255, 0); }
}
.plan-tier-badge {
  background: #fff;
  color: var(--primary);
  font-size: 13px;
  font-weight: 800;
  padding: 8px 16px;
  border-radius: 999px;
  letter-spacing: .5px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .08);
}
.plan-card[data-tier="vip"] {
  background: linear-gradient(135deg, #6d5cff 0%, #5b3df6 55%, #4827d4 100%);
  box-shadow: 0 18px 40px -18px rgba(91, 61, 246, .55);
}
.plan-card[data-tier="vip"] .plan-tier-badge { color: #5b3df6; }
.plan-card[data-tier="vip"] .plan-cd-num,
.plan-card[data-tier="vip"] .plan-cd-num small { color: #5b3df6; }
.plan-card-name {
  position: relative;
  z-index: 1;
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -.5px;
  margin: 4px 0 6px;
  line-height: 1;
  color: #fff;
  text-shadow: 0 2px 6px rgba(0,0,0,.18);
}
.plan-row {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 0;
  font-size: 12px;
}
.plan-row + .plan-row { border-top: 1px dashed rgba(255, 255, 255, .3); }
.plan-row-icon {
  width: 22px; height: 22px;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, .2);
  border-radius: 6px;
  color: #fff;
  flex-shrink: 0;
}
.plan-row-icon svg { width: 12px; height: 12px; }
.plan-row-label { color: rgba(255, 255, 255, .9); font-weight: 600; }
.plan-row-value { color: #fff; font-weight: 700; margin-left: auto; font-size: 12px; }
.plan-countdown {
  position: relative;
  z-index: 1;
  margin-top: 6px;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(4px);
  border-radius: 12px;
  padding: 8px 6px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2px;
  box-shadow:
    0 1px 0 rgba(255,255,255,.7) inset,
    0 4px 12px rgba(0, 0, 0, .15);
}
.plan-cd-cell { text-align: center; padding: 2px 4px; }
.plan-cd-cell + .plan-cd-cell { border-left: 1px solid rgba(0, 0, 0, .06); }
.plan-cd-num {
  color: var(--primary);
  font-size: 22px;
  font-weight: 800;
  line-height: 1;
  display: inline-flex;
  align-items: baseline;
  gap: 1px;
}
.plan-cd-num small {
  font-size: 11px;
  font-weight: 700;
  color: var(--primary);
  opacity: .85;
}
.plan-cd-lbl {
  margin-top: 3px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .6px;
  color: #9aa0ad;
}
@media (max-width: 560px) {
  .plan-card {
    padding: 16px 16px 14px;
    border-radius: 18px;
    aspect-ratio: 16 / 11;
    max-width: 100%;
  }
  .plan-card-name { font-size: 26px; }
  .plan-card-watermark { width: 150px; height: 150px; }
  .plan-tier-badge { padding: 5px 10px; font-size: 11px; }
  .plan-chip { width: 32px; height: 24px; }
  .plan-active-pill { font-size: 11px; padding: 5px 10px; }
  .plan-cd-num { font-size: 18px; }
  .plan-cd-num small { font-size: 10px; }
  .plan-cd-lbl { font-size: 8px; letter-spacing: .4px; }
  .plan-countdown { padding: 6px 4px; border-radius: 10px; }
  .plan-row { font-size: 11px; padding: 3px 0; }
  .plan-row-value { font-size: 11px; }
}

/* ===== TRY FEATURE MODAL (API Playground) =====
   Robust responsive layout:
   - Overlay = block-level scroll container (works in every browser, incl. iframes)
   - Card centered with margin: auto
   - Sticky header & footer keep actions always visible while body scrolls
   - No fixed heights or hidden overflow on the card; nothing can be clipped
*/
/* CONTAINER — fixed to viewport, flex-centers the card. Does NOT scroll. */
.try-modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 17, 23, .65);
  z-index: 9000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  overflow: hidden;
  overscroll-behavior: contain;
}
.try-modal.is-open { display: flex; animation: tryFadeIn .18s ease-out both; }
@keyframes tryFadeIn { from { opacity: 0; } to { opacity: 1; } }

/* CONTENT — flex column, capped at 90vh so it can never overflow the viewport */
.try-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  width: 100%;
  max-width: 640px;
  max-height: 90vh;
  margin: 0;
  box-shadow: 0 24px 60px rgba(0,0,0,.3);
  color: var(--text);
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  animation: tryCardIn .22s cubic-bezier(.2,.8,.2,1) both;
}
.try-head {
  display: flex; justify-content: space-between; align-items: flex-start;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-soft);
  border-radius: 16px 16px 0 0;
  flex: 0 0 auto;
}
.try-head > div:first-child { min-width: 0; flex: 1; }
.try-head h3 { margin: 6px 0 0; font-size: 18px; line-height: 1.3; word-break: break-word; }
.try-head p { font-size: 13px; word-break: break-word; }
.try-method {
  font-family: monospace; font-size: 12px; color: var(--text-soft);
  display: flex; align-items: center; gap: 8px;
  flex-wrap: wrap; word-break: break-all;
}
.try-close {
  background: transparent; border: none; font-size: 26px; line-height: 1;
  color: var(--text-soft); cursor: pointer; padding: 0 4px;
  flex: 0 0 auto;
}
.try-close:hover { color: var(--danger); }

/* BODY — the only scrollable area inside the modal */
.try-body {
  padding: 18px 20px;
  flex: 1 1 auto;
  min-height: 0;
  min-width: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
/* FOOTER — always visible, never scrolled */
.try-foot {
  padding: 14px 20px 16px;
  border-top: 1px solid var(--border);
  background: var(--bg-soft);
  border-radius: 0 0 16px 16px;
  flex: 0 0 auto;
}
.try-foot .try-label { margin-top: 0; }
.try-foot .try-actions { margin-top: 12px; }
.try-label {
  display: block;
  font-size: 12px; font-weight: 700; color: var(--text);
  text-transform: uppercase; letter-spacing: .5px;
  margin-bottom: 6px;
}
.try-params { display: flex; flex-direction: column; gap: 12px; }
.try-param { min-width: 0; }
.try-param input.form-control { width: 100%; max-width: 100%; }
.try-param-head {
  display: flex; justify-content: space-between; align-items: center;
  gap: 8px; flex-wrap: wrap;
  margin-bottom: 4px;
}
.try-param-head code {
  background: var(--bg-soft); padding: 2px 8px; border-radius: 6px;
  font-size: 13px; color: var(--primary); font-weight: 700;
  word-break: break-all;
}
.try-param-head .req { color: var(--danger); font-size: 11px; font-weight: 700; }
.try-param-head .opt { color: var(--text-soft); font-size: 11px; font-weight: 600; }
.try-param small { display: block; margin-top: 4px; font-size: 12px; color: var(--text); opacity: .85; word-break: break-word; }
.try-url-row {
  display: flex; gap: 8px; align-items: stretch;
  flex-wrap: nowrap;
}
.try-url-row input {
  font-family: monospace; font-size: 12px;
  flex: 1 1 auto; min-width: 0;
}
.try-url-row .btn { flex: 0 0 auto; white-space: nowrap; }
.try-actions {
  display: flex; gap: 10px; margin-top: 14px;
  flex-wrap: wrap;
}
.try-actions .btn { flex: 1 1 140px; min-width: 0; text-align: center; white-space: nowrap; }
.try-result {
  margin-top: 18px;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}
.try-result-head {
  display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap;
  padding: 8px 14px; background: var(--bg-soft);
  font-size: 12px; font-weight: 700;
}
.try-result pre {
  margin: 0; padding: 14px; background: #0f1117; color: #e0e6ed;
  font-size: 12px; max-height: 320px; overflow: auto;
  white-space: pre-wrap; word-break: break-word;
}

/* Tablet */
@media (max-width: 900px) {
  .try-card { max-width: 560px; }
}

/* Mobile: fullscreen sheet — modal still fixed, card grows to viewport */
@media (max-width: 720px) {
  .try-modal {
    padding: 0;
    align-items: stretch;
    justify-content: stretch;
  }
  .try-card {
    max-width: 100%;
    width: 100%;
    max-height: 100vh;
    max-height: 100dvh;
    border-radius: 0;
    border: none;
    margin: 0;
    animation: trySheetUp .28s cubic-bezier(.2,.8,.2,1) both;
  }
  .try-head { padding: 12px 14px; border-radius: 0; }
  .try-head h3 { font-size: 16px; }
  .try-body { padding: 14px 14px 16px; }
  .try-foot {
    padding: 12px 14px calc(env(safe-area-inset-bottom, 0px) + 12px);
    border-radius: 0;
  }
  .try-actions { flex-direction: column; }
  .try-actions .btn { flex: 1 1 auto; width: 100%; }
}

/* Very small phones */
@media (max-width: 380px) {
  .try-head { padding: 10px 12px; }
  .try-body { padding: 12px; }
  .try-foot { padding: 10px 12px calc(env(safe-area-inset-bottom, 0px) + 10px); }
  .try-head h3 { font-size: 15px; }
  .try-url-row { flex-wrap: wrap; }
  .try-url-row .btn { width: 100%; }
}

/* Landscape phones (short height) — keep footer visible */
@media (max-height: 520px) and (orientation: landscape) {
  .try-modal { padding: 0; align-items: stretch; }
  .try-card {
    max-height: 100vh;
    max-height: 100dvh;
    width: 100%;
    max-width: 100%;
    border-radius: 0;
    margin: 0;
  }
  .try-head { padding: 10px 16px; }
  .try-head h3 { font-size: 15px; margin-top: 2px; }
  .try-head p { display: none; }
  .try-body { padding: 12px 16px; }
  .try-foot { padding: 10px 16px; }
  .try-foot .try-actions { margin-top: 8px; }
}

@keyframes trySheetUp {
  from { transform: translateY(100%); }
  to   { transform: translateY(0); }
}
@keyframes tryCardIn {
  from { transform: translateY(12px) scale(.98); }
  to   { transform: translateY(0) scale(1); }
}

.toast-pop {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%);
  background: var(--text); color: var(--bg);
  padding: 10px 18px; border-radius: 999px;
  font-weight: 700; font-size: 13px;
  z-index: 700;
  box-shadow: 0 8px 20px rgba(0,0,0,.25);
  animation: pageFadeIn .2s ease both;
}

/* ===== COUNTDOWN ===== */
.countdown {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 999px;
  font-weight: 800;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.countdown.lg { font-size: 18px; padding: 10px 18px; }

/* ===== QRIS PAYMENT MODAL (SocialGo style) ===== */
.pay-modal {
  position: fixed; inset: 0;
  background: rgba(15, 17, 23, .65);
  z-index: 600;
  display: flex; align-items: center; justify-content: center;
  padding: 16px;
  animation: pageFadeIn .25s ease both;
}
.pay-card {
  background: #fff;
  border-radius: 18px;
  width: 100%;
  max-width: 380px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0,0,0,.4);
  font-family: inherit;
  color: #1f2233;
}
.pay-head {
  background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
  color: #047857;
  padding: 14px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 700;
  font-size: 13px;
}
.pay-head .amount { font-weight: 800; font-size: 18px; }
.qris-frame {
  background: linear-gradient(180deg, #ffffff 0%, #fdf2f3 100%);
  padding: 18px 22px 22px;
  text-align: center;
}
.qris-frame .qris-brand {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 12px;
}
.qris-frame .qris-logo {
  font-weight: 900; color: #ed1c24;
  font-style: italic; font-size: 22px; letter-spacing: -1px;
}
.qris-frame .qris-logo small { font-style: normal; font-weight: 700; font-size: 9px; color: #555; display: block; line-height: 1; }
.qris-frame .gpn {
  background: linear-gradient(90deg, #ed1c24, #f59e0b, #10b981, #3b82f6);
  color: #fff; padding: 3px 8px; border-radius: 6px;
  font-weight: 800; font-size: 11px;
}
.qris-frame h4 {
  font-size: 18px; font-weight: 800; margin-bottom: 12px; color: #1f2233;
}
.qris-frame img.qr {
  width: 100%;
  max-width: 240px;
  display: block;
  margin: 0 auto 12px;
  border-radius: 8px;
}
.qris-frame .qris-foot {
  font-size: 11px; color: #444;
  font-weight: 600;
  margin-top: 8px;
}
.qris-frame .qris-foot strong { color: #ed1c24; }
.pay-info-block {
  padding: 14px 20px;
  border-top: 1px solid #f0f0f5;
  font-size: 13px;
}
.pay-info-block .row {
  display: flex; justify-content: space-between;
  padding: 6px 0;
  color: #555;
}
.pay-info-block .row b { color: #1f2233; }
.pay-status {
  text-align: center;
  padding: 12px 20px;
  background: #f8f9fb;
  font-weight: 700;
  font-size: 13px;
  color: #6b6f80;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.pay-status .dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--warning);
  animation: pulse 1.2s ease-in-out infinite;
}
.pay-status.paid .dot { background: var(--success); animation: none; }
.pay-status.expired .dot { background: var(--danger); animation: none; }
.pay-actions {
  display: flex; gap: 10px;
  padding: 12px 20px 18px;
}
.pay-actions .btn { flex: 1; }
@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.4); opacity: .5; }
}
@media (max-width: 520px) {
  .pay-card { max-width: 100%; }
  .qris-frame img.qr { max-width: 200px; }
}

.method-cell { display: inline-flex; gap: 6px; }

/* ===== DETAIL PROFILE ===== */
.profile-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-bottom: 24px;
}
.profile-grid > div .label {
  font-size: 12px;
  color: var(--text-soft);
  margin-bottom: 4px;
}
.profile-grid > div .value {
  font-weight: 700;
  word-break: break-all;
}

/* ===== HAMBURGER ===== */
.hamburger {
  display: none;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--bg);
  border: 1px solid var(--border);
  align-items: center;
  justify-content: center;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1100px) {
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
  .profile-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; padding: 40px 6% 60px; gap: 32px; }
  .hero h1 { font-size: 38px; }
  .hero-image { order: -1; max-width: 320px; margin: 0 auto; }
  .pricing-grid { grid-template-columns: 1fr; max-width: 480px; }
  .stats-band { padding: 40px 6% 16px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .api-explain { padding: 20px 6% 50px; }
  .api-explain-grid { grid-template-columns: 1fr; gap: 16px; }
  .footer-top { grid-template-columns: 1fr; gap: 28px; }
  .pricing-page-grid { grid-template-columns: 1fr !important; max-width: 480px; margin: 0 auto; }
  .dash-bottom { grid-template-columns: 1fr !important; }
  .form-grid-3 { grid-template-columns: 1fr 1fr !important; }
}
@media (max-width: 900px) {
  .app-layout { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed;
    left: -280px;
    top: 0;
    width: 260px;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    transition: left .25s ease;
    z-index: 200;
    box-shadow: 0 0 30px rgba(0,0,0,.18);
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    display: block;
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }
  .sidebar nav {
    overflow: visible;
    flex: none;
    min-height: 0;
    padding-bottom: calc(48px + env(safe-area-inset-bottom, 0px));
  }
  .sidebar.open { left: 0; }
  .sidebar-toggle { display: inline-flex; }
}
@media (max-width: 760px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg);
    flex-direction: column;
    align-items: center;
    padding: 28px 18px 32px;
    gap: 18px;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 8px 24px rgba(0,0,0,.06);
    animation: slideDown .22s ease;
  }
  .nav-links.open { display: flex; }
  .nav-links > a {
    font-size: 20px;
    padding: 2px 10px;
    text-align: center;
    font-weight: 700;
    color: var(--primary);
    line-height: 1.15;
    letter-spacing: -0.3px;
  }
  .nav-links > a:hover, .nav-links > a.active {
    color: var(--primary-hover);
  }
  .nav-mobile-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-top: 8px;
    padding-top: 6px;
  }
  .nav-mobile-actions .login-link {
    color: var(--text);
    font-weight: 600;
    font-size: 14px;
  }
  .nav-mobile-actions .btn {
    font-size: 14px;
    padding: 8px 22px;
    border-radius: 999px;
  }
  .hamburger { display: inline-flex; }
  .nav-actions .login-link { display: none; }
  .nav-actions > .btn { display: none; }
  .navbar { padding: 16px 5%; }
  .main { padding: 16px; }
  .topbar { gap: 10px; }
  .topbar-left { flex: 0 1 auto; }
  .page-title { font-size: 20px; }
  .topbar-actions { width: auto; gap: 10px; margin-left: auto; }
  .search-box { display: none; }
  .user-meta { display: none; }
  .user-chip { padding: 4px; }
  .footer { flex-direction: column; text-align: center; }
  .form-grid-3 { grid-template-columns: 1fr !important; }
  .panel { padding: 16px; }
  .panel h3 { font-size: 15px; margin-bottom: 10px; }
  .panel p, .panel li { font-size: 13px; line-height: 1.7; }
  .panel ol, .panel ul { padding-left: 18px; }
  .hero h1 { font-size: 32px; line-height: 1.2; }
  .hero p { font-size: 14px; }
  .section-title, .section-heading { font-size: 22px; }
  .pricing-card h3 { font-size: 18px; }
  .pricing-card .price { font-size: 28px; }
  .stat-num { font-size: 26px; }
  .stat-card { padding: 18px 16px; }
  .api-card { padding: 22px; }
  .api-card h3 { font-size: 18px; }
  .footer { padding: 36px 6% 22px; font-size: 13px; }
  .footer-bottom { flex-direction: column; text-align: center; }
}
@media (max-width: 520px) {
  .cards-grid, .profile-grid { grid-template-columns: 1fr; gap: 12px; }
  .hero h1 { font-size: 26px; }
  .hero p { font-size: 13px; }
  .section { padding: 40px 5%; }
  .section-title, .section-heading { font-size: 20px; }
  .stat-num { font-size: 30px; }
  .auth-card { padding: 24px 20px; }
  .auth-card h2 { font-size: 20px; }
  .data-table thead th, .data-table tbody td { padding: 10px 12px; font-size: 12px; }
  .card-value { font-size: 20px; }
  .stat-card { padding: 14px 16px; gap: 12px; }
  .stat-icon { width: 36px; height: 36px; }
  .stat-icon svg { width: 18px; height: 18px; }
  .stat-label { font-size: 12px; }
  .stat-value { font-size: 18px; }
  .panel { padding: 14px; }
  .panel h3 { font-size: 14px; }
  .panel p, .panel li { font-size: 12.5px; line-height: 1.65; }
  .page-title { font-size: 18px; }
  .nav-brand { font-size: 18px; }
}

/* loading spinner button */
.spinner {
  width: 18px; height: 18px; border-radius: 50%;
  border: 2px solid #fff; border-top-color: transparent;
  animation: spin .8s linear infinite;
  display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ===== PAGE TRANSITIONS / ANIMATIONS ===== */
@keyframes pageFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes slideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes slideInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes scaleIn {
  from { opacity: 0; transform: scale(.96); }
  to { opacity: 1; transform: scale(1); }
}

body { animation: pageFadeIn .35s ease both; }

.hero > div:first-child { animation: slideInUp .5s ease both; }
.hero-image { animation: scaleIn .6s ease both .1s; }

.panel,
.card,
.pricing-card,
.auth-card,
.feature-card {
  animation: slideInUp .45s ease both;
}
.cards-grid > *:nth-child(1) { animation-delay: .04s; }
.cards-grid > *:nth-child(2) { animation-delay: .10s; }
.cards-grid > *:nth-child(3) { animation-delay: .16s; }
.cards-grid > *:nth-child(4) { animation-delay: .22s; }

.dash-bottom > *:nth-child(1) { animation-delay: .28s; }
.dash-bottom > *:nth-child(2) { animation-delay: .34s; }

.pricing-grid > *:nth-child(1),
.pricing-page-grid > *:nth-child(1) { animation-delay: .05s; }
.pricing-grid > *:nth-child(2),
.pricing-page-grid > *:nth-child(2) { animation-delay: .15s; }
.pricing-grid > *:nth-child(3),
.pricing-page-grid > *:nth-child(3) { animation-delay: .25s; }

.sidebar nav a { transition: background .2s ease, color .2s ease, padding-left .2s ease; }
.sidebar nav a:hover { padding-left: 28px; }

.btn { transition: background .2s ease, transform .15s ease, box-shadow .2s ease; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(250,114,104,.3); }
.btn:active { transform: translateY(0); }

a, button { transition: color .2s ease, background .2s ease, border-color .2s ease; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}

/* ===== UI MODAL / TOAST / FLOATING THEME ===== */
.ui-modal-overlay {
  position: fixed; inset: 0;
  background: rgba(15, 17, 23, .55);
  backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  padding: 20px; z-index: 9999;
  opacity: 0; transition: opacity .18s ease;
}
.ui-modal-overlay.open { opacity: 1; }
.ui-modal {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 16px;
  width: 100%; max-width: 420px;
  padding: 26px 24px 22px;
  box-shadow: 0 24px 60px rgba(10, 14, 30, .35);
  text-align: center;
  transform: translateY(8px) scale(.98);
  transition: transform .22s cubic-bezier(.2,.9,.3,1.4);
}
.ui-modal-overlay.open .ui-modal { transform: translateY(0) scale(1); }
.ui-modal-icon {
  width: 56px; height: 56px;
  margin: 0 auto 14px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: color-mix(in srgb, currentColor 12%, transparent);
}
.ui-modal-title { margin: 0 0 8px; font-size: 18px; font-weight: 700; }
.ui-modal-body { font-size: 14px; color: var(--text-soft); line-height: 1.5; margin-bottom: 20px; }
.ui-modal-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.ui-modal-actions .btn { min-width: 96px; }
.btn-danger { background: #ef4444 !important; color: #fff !important; }
.btn-danger:hover { background: #dc2626 !important; box-shadow: 0 6px 18px rgba(239,68,68,.3) !important; }

.ui-toast {
  position: fixed; left: 50%; bottom: 28px;
  transform: translate(-50%, 24px);
  background: var(--text); color: var(--bg);
  padding: 11px 18px; border-radius: 999px;
  font-size: 13px; font-weight: 600;
  box-shadow: 0 10px 30px rgba(0,0,0,.25);
  opacity: 0; transition: opacity .22s ease, transform .22s ease;
  z-index: 10000;
}
.ui-toast.show { opacity: 1; transform: translate(-50%, 0); }
.ui-toast.success { background: #10b981; color: #fff; }
.ui-toast.error { background: #ef4444; color: #fff; }

.floating-theme-toggle {
  position: fixed; top: 18px; right: 18px;
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--bg);
  border: 1px solid var(--border);
  box-shadow: 0 4px 14px rgba(20, 30, 60, .12);
  display: flex; align-items: center; justify-content: center;
  color: var(--text);
  z-index: 1000;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease;
}
.floating-theme-toggle:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(20, 30, 60, .2); }
.floating-theme-toggle .ico-moon { display: none; }
.floating-theme-toggle .ico-sun { display: block; }
[data-theme="dark"] .floating-theme-toggle .ico-sun { display: none; }
[data-theme="dark"] .floating-theme-toggle .ico-moon { display: block; }

/* Hide floating toggle when an in-page topbar toggle exists */
body:has(.theme-toggle) .floating-theme-toggle { display: none; }

/* On mobile, place the floating toggle just to the LEFT of the hamburger /
   sidebar button (which sits at the right edge of the navbar). */
@media (max-width: 820px) {
  .floating-theme-toggle {
    top: 15px;
    right: 64px;
    left: auto;
    width: 42px;
    height: 42px;
  }
}

/* ===== INTL TEL INPUT THEME ===== */
.iti { width: 100%; }
.iti__country-list {
  background: var(--bg) !important;
  color: var(--text) !important;
  border: 1px solid var(--border) !important;
  box-shadow: 0 12px 30px rgba(0,0,0,.18) !important;
}
.iti__country.iti__highlight { background: var(--bg-soft) !important; }
.iti__divider { border-bottom-color: var(--border) !important; }
.iti--separate-dial-code .iti__selected-flag { background: var(--bg-soft) !important; }
.iti input.form-control { padding-left: 92px !important; }

/* ===== RESEND COUNTDOWN LINK ===== */
.resend-link.disabled {
  color: var(--text-soft) !important;
  pointer-events: none;
  opacity: .7;
}

/* Feature category - card list layout */
.feat-page { padding: 4px 0 32px; max-width: 860px; margin: 0 auto; }
.feat-search {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px 16px;
  margin: 8px 0 22px;
  box-shadow: 0 1px 2px rgba(0,0,0,.03);
  transition: border-color .15s, box-shadow .15s;
}
.feat-search:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(250,114,104,.12);
}
.feat-search svg { width: 20px; height: 20px; color: var(--text-soft); flex-shrink: 0; }
.feat-search input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 15px;
  color: var(--text);
}
.feat-section-title {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text-soft);
  margin: 8px 4px 14px;
}
.feat-list { display: flex; flex-direction: column; gap: 12px; }
.feat-card {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  text-align: left;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 14px 16px;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s, border-color .15s;
  font-family: inherit;
  color: inherit;
}
.feat-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(0,0,0,.06);
  border-color: var(--primary);
}
.feat-card:active { transform: translateY(0); }
.feat-card-no {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-soft);
  color: var(--text-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
}
.feat-card-body { flex: 1; min-width: 0; }
.feat-card-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.feat-card-name { font-weight: 700; font-size: 16px; color: var(--text); }
.feat-card-cat {
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .4px;
  color: var(--primary); background: rgba(250,114,104,.1);
  padding: 2px 8px; border-radius: 999px;
}
.feat-filters {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin: 0 0 18px;
}
.feat-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px; border-radius: 999px;
  background: var(--card); border: 1px solid var(--border);
  font-size: 13px; font-weight: 600; color: var(--text-soft);
  cursor: pointer; transition: all .15s; font-family: inherit;
}
.feat-chip:hover { border-color: var(--primary); color: var(--text); }
.feat-chip span {
  font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 999px;
  background: var(--bg-soft); color: var(--text-soft);
}
.feat-chip.active {
  background: var(--primary); border-color: var(--primary); color: #fff;
}
.feat-chip.active span { background: rgba(255,255,255,.25); color: #fff; }
.feat-card-desc {
  margin-top: 4px;
  color: var(--text-soft);
  font-size: 14px;
  line-height: 1.4;
}
.feat-card-chev {
  width: 22px;
  height: 22px;
  color: var(--text-soft);
  flex-shrink: 0;
  background: var(--bg-soft);
  border-radius: 50%;
  padding: 4px;
}
.feat-empty {
  text-align: center;
  color: var(--text-soft);
  padding: 40px 16px;
  border: 1px dashed var(--border);
  border-radius: 14px;
}
@media (max-width: 600px) {
  .feat-card { padding: 12px 12px; gap: 10px; }
  .feat-card-no { width: 30px; height: 30px; font-size: 13px; }
  .feat-card-name { font-size: 15px; }
  .feat-card-desc { font-size: 13px; }
}
