:root {
  --primary: #2454ff;
  --primary-dark: #173bb0;
  --success: #1a9e5c;
  --danger: #d6392e;
  --bg: #f4f6fb;
  --card-bg: #ffffff;
  --text: #1c2230;
  --muted: #667085;
  --border: #e2e6ee;
  --radius: 10px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
}

nav {
  background: var(--card-bg);
  border-bottom: 1px solid var(--border);
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 50;
}

nav .brand {
  font-weight: 700;
  font-size: 18px;
  color: var(--primary-dark);
  text-decoration: none;
  letter-spacing: -0.3px;
}

nav .links a {
  margin-left: 18px;
  text-decoration: none;
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  padding-bottom: 3px;
  border-bottom: 2px solid transparent;
}

nav .links a:hover,
nav .links a.active { color: var(--primary); border-bottom-color: var(--primary); }

.container {
  max-width: 620px;
  margin: 40px auto;
  padding: 0 20px;
}

.wide { max-width: 960px; }

.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: 0 2px 10px rgba(20, 30, 60, 0.04);
  margin-bottom: 20px;
}

h1 { font-size: 24px; margin-top: 0; }
h2 { font-size: 19px; margin-top: 0; }
p.subtitle { color: var(--muted); margin-top: -8px; }

.hero {
  text-align: center;
  margin-bottom: 30px;
  background: linear-gradient(135deg, #eaf0ff 0%, #f4f6fb 70%);
  border-radius: var(--radius);
  padding: 40px 24px;
  border: 1px solid var(--border);
}

.hero h1 { font-size: 30px; }
.hero p { color: var(--muted); font-size: 15px; max-width: 520px; margin: 8px auto 0; }

.action-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.action-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
  text-decoration: none;
  color: var(--text);
  transition: box-shadow 0.15s, transform 0.15s;
}

.action-card:hover {
  box-shadow: 0 6px 18px rgba(20, 30, 60, 0.08);
  transform: translateY(-2px);
}

.action-card .icon { font-size: 32px; margin-bottom: 10px; }
.action-card h3 { margin: 6px 0; font-size: 16px; }
.action-card p { margin: 0; color: var(--muted); font-size: 13px; }

label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin: 14px 0 6px;
  color: var(--text);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
input[type="number"],
input[type="password"],
input[type="file"],
select,
textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  background: #fbfcfe;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--primary);
  background: #fff;
}

button, .btn {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 11px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  margin-top: 18px;
  text-decoration: none;
  text-align: center;
  transition: background 0.15s;
}

button:hover, .btn:hover { background: var(--primary-dark); }
button:disabled { background: #a9b7d9; cursor: not-allowed; }

button.secondary, .btn.secondary {
  background: transparent;
  color: var(--primary);
  border: 1px solid var(--primary);
}

button.danger { background: var(--danger); }

.msg {
  margin-top: 14px;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13.5px;
  display: none;
}

.msg.show { display: block; }
.msg.success { background: #e6f6ed; color: var(--success); border: 1px solid #b9e6cc; }
.msg.error { background: #fdecea; color: var(--danger); border: 1px solid #f6c6c2; }
.msg.info { background: #eaf0ff; color: var(--primary-dark); border: 1px solid #c9d8ff; }

.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
}

.badge.active { background: #e6f6ed; color: var(--success); }
.badge.expired { background: #fdecea; color: var(--danger); }
.badge.pending { background: #fff4e0; color: #a86400; }

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  margin-top: 6px;
}

th, td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
}

th { color: var(--muted); font-weight: 600; font-size: 12.5px; text-transform: uppercase; }
tbody tr:hover { background: #fafbfe; }

.detail-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}

.detail-row span:first-child { color: var(--muted); }
.detail-row span:last-child { font-weight: 600; }

.top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}

.hidden { display: none !important; }

.footer-note {
  text-align: center;
  color: var(--muted);
  font-size: 12.5px;
  margin-top: 24px;
}

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(20, 26, 40, 0.45);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 40px 16px;
  overflow-y: auto;
  z-index: 100;
}

.modal {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 26px;
  width: 100%;
  max-width: 520px;
  box-shadow: 0 10px 40px rgba(20, 30, 60, 0.2);
}

.offer-box {
  background: #eaf0ff;
  border: 1px solid #c9d8ff;
  border-radius: 8px;
  padding: 14px;
  margin-top: 16px;
}

.offer-box .offer-title {
  font-weight: 600;
  font-size: 13.5px;
  margin-bottom: 8px;
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 20px;
}

@media (max-width: 640px) {
  .action-grid, .two-col { grid-template-columns: 1fr; }
  nav .links a { margin-left: 12px; font-size: 13px; }
}
