:root {
  --navy: #071a33;
  --navy-2: #0b2f60;
  --blue: #1463ff;
  --blue-dark: #0a4bcc;
  --cyan: #58d8ff;
  --ink: #172033;
  --muted: #64748b;
  --line: #dfe7f2;
  --bg: #f6f9fd;
  --white: #fff;
  --danger: #c93636;
  --success: #087a55;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Pretendard, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
}
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
.wrap { width: min(1120px, calc(100% - 40px)); margin: auto; }

header { background: var(--navy); color: #fff; }
.nav { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { font-size: 22px; font-weight: 850; letter-spacing: .08em; white-space: nowrap; }
.brand i { color: var(--cyan); font-style: normal; }
.navlinks { display: flex; gap: 24px; align-items: center; }
.navlinks > a:not(.button) { color: #d5e1f2; }
.navlinks > a:not(.button):hover { color: #fff; }

.button {
  display: inline-flex;
  min-height: 44px;
  padding: 10px 18px;
  border: 0;
  border-radius: 10px;
  align-items: center;
  justify-content: center;
  background: var(--blue);
  color: #fff;
  font-weight: 750;
  cursor: pointer;
  transition: background .18s ease, transform .18s ease;
}
.button:hover { background: var(--blue-dark); transform: translateY(-1px); }
.button.ghost { background: transparent; border: 1px solid #ffffff55; }
.button.ghost:hover { background: #ffffff12; }
.button.light { background: #fff; color: var(--navy); }
.button.danger { background: var(--danger); }
.button.small { min-height: 34px; padding: 6px 11px; font-size: 13px; }
.button.full { width: 100%; }

.hero {
  padding: 92px 0;
  overflow: hidden;
  background:
    radial-gradient(circle at 85% 20%, #1c68c980 0, transparent 34%),
    linear-gradient(135deg, var(--navy), var(--navy-2));
  color: #fff;
}
.hero-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr); gap: 64px; align-items: center; }
.hero h1 { margin: 12px 0 22px; font-size: clamp(42px, 6vw, 70px); line-height: 1.08; letter-spacing: -.04em; }
.hero p { max-width: 690px; margin: 0; color: #c7d8f2; font-size: 19px; }
.eyebrow { color: var(--cyan); font-size: 12px; font-weight: 850; letter-spacing: .16em; }
.eyebrow.dark { color: var(--blue); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero-panel {
  padding: 8px;
  border: 1px solid #ffffff24;
  border-radius: 22px;
  background: #071a3390;
  box-shadow: 0 30px 80px #0000002b;
  backdrop-filter: blur(14px);
}
.hero-panel div { display: grid; grid-template-columns: 42px 1fr; padding: 20px; border-bottom: 1px solid #ffffff18; align-items: center; }
.hero-panel div:last-child { border-bottom: 0; }
.hero-panel span { grid-row: span 2; color: var(--cyan); font-size: 13px; font-weight: 800; }
.hero-panel strong { font-size: 19px; }
.hero-panel small { color: #9fb5d3; }

section { padding: 72px 0; }
.compact-section { padding: 22px 0; }
.section-title { margin: 10px 0 12px; font-size: clamp(30px, 4vw, 42px); line-height: 1.2; letter-spacing: -.03em; }
.lead { margin: 0 0 32px; color: var(--muted); }
.section-tint { background: #edf4fc; }
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.card {
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 12px 35px #1122440d;
}
.card h2, .card h3 { margin-top: 0; }
.card p:last-child { margin-bottom: 0; }
.tag {
  display: inline-block;
  padding: 5px 10px;
  border-radius: 999px;
  background: #eaf2ff;
  color: #0753cc;
  font-size: 13px;
  font-weight: 750;
}
.notice { margin: 24px 0 0; color: var(--muted); text-align: center; }
.split { display: grid; grid-template-columns: .9fr 1.1fr; gap: 64px; align-items: start; }
.feature-list { display: grid; gap: 12px; }
.feature-list div { display: grid; gap: 3px; padding: 20px 22px; border-left: 4px solid var(--blue); background: #fff; border-radius: 0 12px 12px 0; }
.feature-list span { color: var(--muted); }
.cta { display: flex; justify-content: space-between; gap: 32px; align-items: center; padding: 44px; border-radius: 22px; background: linear-gradient(135deg, var(--navy), var(--navy-2)); color: #fff; }
.cta h2 { margin: 8px 0; font-size: 34px; }
.cta p { margin: 0; color: #c7d8f2; }

.shell { display: grid; grid-template-columns: 250px minmax(0, 1fr); min-height: 100vh; }
.sidebar { display: flex; flex-direction: column; min-width: 0; padding: 26px; background: var(--navy); color: #fff; }
.sidebar nav { display: grid; gap: 8px; margin-top: 24px; }
.sidebar nav a { padding: 10px 12px; border-radius: 8px; color: #cad6e8; }
.sidebar nav a.active, .sidebar nav a:hover { background: #ffffff17; color: #fff; }
.sidebar-user { margin: 26px 0 0; color: #fff; font-weight: 700; overflow-wrap: anywhere; }
.sidebar-user small { display: block; color: #91a8c7; font-size: 12px; font-weight: 400; }
.sidebar-logout { margin-top: auto; padding-top: 24px; }
.link-button { padding: 8px 0; border: 0; background: none; color: #9fb5d3; cursor: pointer; }
.link-button:hover { color: #fff; }
.main { min-width: 0; padding: 38px; }
.main > h1 { margin-bottom: 4px; font-size: clamp(30px, 4vw, 42px); letter-spacing: -.03em; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.stat strong { display: block; font-size: 30px; }
.stat span { color: var(--muted); }

table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 12px; overflow: hidden; }
th, td { padding: 14px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
th { background: #f0f5fb; color: #3a4960; font-size: 13px; white-space: nowrap; }
td { font-size: 14px; }
.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: 13px; }
.table-scroll table { border-radius: 0; }
.table-scroll tr:last-child td { border-bottom: 0; }
code { padding: 2px 6px; border-radius: 5px; background: #edf2f8; overflow-wrap: anywhere; }
pre { overflow-x: auto; margin-bottom: 0; padding: 18px; border-radius: 12px; background: #101d31; color: #d9e9ff; }
pre code { padding: 0; background: transparent; }
.text-link { color: var(--blue); font-weight: 700; }

form label { display: grid; gap: 7px; color: #334158; font-size: 14px; font-weight: 700; }
input, select {
  width: 100%;
  min-height: 44px;
  padding: 9px 12px;
  border: 1px solid #cfd9e7;
  border-radius: 9px;
  outline: none;
  background: #fff;
  color: var(--ink);
}
input:focus, select:focus { border-color: var(--blue); box-shadow: 0 0 0 3px #1463ff18; }
.inline-form { display: grid; grid-template-columns: minmax(220px, 420px) auto; gap: 12px; align-items: end; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: end; }
.auth-page { display: grid; min-height: 100vh; padding: 24px; place-items: center; background: linear-gradient(145deg, #edf4fc, #f9fbfe); }
.auth-card { width: min(440px, 100%); padding: 36px; border: 1px solid var(--line); border-radius: 20px; background: #fff; box-shadow: 0 24px 70px #10213b1a; }
.auth-card h1 { margin: 28px 0 6px; }
.auth-card form { display: grid; gap: 16px; }
.dark-brand { color: var(--navy); }
.auth-note { margin: 24px 0 0; color: var(--muted); font-size: 13px; text-align: center; }
.alert { display: grid; gap: 7px; margin: 18px 0; padding: 15px 17px; border-radius: 10px; }
.alert.error { border: 1px solid #f1c5c5; background: #fff1f1; color: #8d2424; }
.alert.success { border: 1px solid #b9e2d2; background: #ecfbf5; color: #075d42; }
.secret-key { display: block; padding: 11px; background: #fff; color: #19365a; }
.status { display: inline-block; padding: 3px 8px; border-radius: 999px; background: #e9eef5; color: #4c5b70; font-size: 12px; font-weight: 750; }
.status.active, .status.completed, .status.trial { background: #e4f8ef; color: var(--success); }
.status.revoked, .status.blocked, .status.failed, .status.cancelled { background: #fdeaea; color: var(--danger); }
.status.pending, .status.draft, .status.queued { background: #fff4d7; color: #8b6100; }
.plan-card { max-width: 860px; }
.plan-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 24px 0; }
.plan-metrics div { padding: 16px; border-radius: 12px; background: #f3f7fc; }
.plan-metrics strong, .plan-metrics span { display: block; }
.plan-metrics strong { font-size: 22px; }
.plan-metrics span { color: var(--muted); font-size: 13px; }
.empty-state { max-width: 680px; text-align: center; }

footer { padding: 28px 0; background: var(--navy); color: #9db0ca; }
.footer-row { display: flex; justify-content: space-between; gap: 20px; align-items: center; }

@media (max-width: 900px) {
  .hero-layout, .split { grid-template-columns: 1fr; gap: 38px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .shell { grid-template-columns: 1fr; }
  .sidebar { display: block; padding: 20px; }
  .sidebar nav { display: flex; margin-top: 18px; overflow-x: auto; }
  .sidebar nav a { white-space: nowrap; }
  .sidebar-user { margin: 14px 0 0; }
  .sidebar-logout { position: absolute; top: 18px; right: 20px; padding: 0; }
}

@media (max-width: 680px) {
  .wrap { width: min(100% - 28px, 1120px); }
  .navlinks > a:not(.button) { display: none; }
  .hero { padding: 68px 0; }
  .grid, .stats, .form-grid, .plan-metrics { grid-template-columns: 1fr; }
  .inline-form { grid-template-columns: 1fr; }
  .main { padding: 24px 18px; }
  .cta, .footer-row { align-items: flex-start; flex-direction: column; }
  .cta { padding: 30px 24px; }
  .auth-card { padding: 28px 22px; }
}
