:root {
  --bg-primary: #050505;
  --bg-secondary: #0a0px;
  --bg-card: #0f1012;
  --bg-hover: #16171a;
  --border: #1f2025;
  --border-light: #16171a;
  --text-primary: #f3f4f6;
  --text-secondary: #a1a1aa;
  --text-muted: #52525b;
  --accent: #ff4500;
  --accent-hover: #ff3300;
  --accent-glow: rgba(255, 69, 0, 0.15);
  --accent-glow-strong: rgba(255, 69, 0, 0.4);
  --danger: #ef4444;
  --danger-hover: #dc2626;
  --success: #10b981;
  --warning: #f59e0b;
  --orange: #ff4500;
  --purple: #8b5cf6;
  --green: #10b981;
  --teal: #14b8a6;
  --pink: #ec4899;
  --yellow: #eab308;
  --sidebar-w: 260px;
  --radius: 16px;
  --radius-sm: 8px;
  --shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.4);
  --card-glow: 0 0 24px rgba(255, 69, 0, 0.08);
}


*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', -apple-system, sans-serif;
  background: var(--bg-primary);
  background-image:
    radial-gradient(ellipse at top right, rgba(255, 69, 0, 0.08) 0%, transparent 45%),
    radial-gradient(ellipse at bottom left, rgba(220, 38, 38, 0.05) 0%, transparent 45%);
  background-attachment: fixed;
  color: var(--text-primary);
  font-size: 14px;
  line-height: 1.6;
  min-height: 100vh;
}

/* ====== Auth Page ====== */
.auth-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: radial-gradient(ellipse at 50% -20%, rgba(255, 69, 0, .15) 0%, transparent 60%),
    radial-gradient(ellipse at 20% 80%, rgba(239, 68, 68, .08) 0%, transparent 50%),
    var(--bg-primary);
}

.auth-container {
  width: 100%;
  max-width: 420px;
  padding: 20px;
}

.auth-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 40px 36px;
  box-shadow: var(--shadow);
}

.auth-logo {
  text-align: center;
  margin-bottom: 36px;
}

.auth-logo-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background: linear-gradient(135deg, #ff4500, #dc2626);
  color: #fff;
  margin-bottom: 16px;
  box-shadow: 0 8px 32px rgba(255, 69, 0, .35);
}

.auth-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 4px;
}

.auth-subtitle {
  color: var(--text-muted);
  font-size: 13px;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.auth-footer {
  text-align: center;
  color: var(--text-muted);
  font-size: 12px;
  margin-top: 16px;
}

/* ====== Layout ====== */
.sidebar {
  position: fixed;
  top: 16px;
  left: 16px;
  bottom: 16px;
  width: var(--sidebar-w);
  background: rgba(10, 10, 10, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: transform .25s ease;
  box-shadow: var(--shadow);
}

.sidebar-header {
  padding: 24px 20px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
}

.sidebar-logo svg {
  color: var(--accent);
}

.sidebar-nav {
  flex: 1;
  padding: 12px 8px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nav-section {
  margin-top: 8px;
}

.nav-label {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: .08em;
  padding: 6px 8px 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  transition: all .15s;
}

.nav-item:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.nav-item.active {
  background: linear-gradient(90deg, var(--accent-glow), transparent);
  color: #fff;
  border-left: 3px solid var(--accent);
}

.nav-item.active svg {
  color: var(--accent);
}

.sidebar-footer {
  padding: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  gap: 8px;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff4500, #dc2626);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  color: #fff;
  flex-shrink: 0;
}

.user-avatar-sm {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff4500, #dc2626);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 11px;
  color: #fff;
  flex-shrink: 0;
}

.user-meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.user-name {
  font-weight: 600;
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-role {
  font-size: 11px;
  color: var(--text-muted);
}

.btn-logout {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 7px;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  text-decoration: none;
  transition: all .15s;
}

.btn-logout:hover {
  background: rgba(239, 68, 68, .12);
  color: var(--danger);
}

.main-content {
  margin-left: calc(var(--sidebar-w) + 32px);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.topbar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 24px 32px;
  background: transparent;
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.topbar-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -.02em;
  background: linear-gradient(135deg, #fff, #a1a1aa);
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

.sidebar-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 4px;
}

.content-area {
  padding: 24px;
  flex: 1;
  max-width: 1400px;
  width: 100%;
}

/* ====== Cards ====== */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-left: 1px solid rgba(255, 255, 255, 0.03);
  border-radius: var(--radius);
  margin-bottom: 24px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  position: relative;
  transition: all 0.25s ease;
}

.card:hover {
  border-color: rgba(255, 69, 0, 0.3);
  box-shadow: var(--card-glow);
  transform: translateY(-2px);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  background: linear-gradient(180deg, rgba(255, 69, 0, 0.03) 0%, transparent 100%);
}

.card-title {
  font-size: 15px;
  font-weight: 600;
}

.card-subtitle {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

.card-body {
  padding: 20px;
}

/* ====== Stats ====== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: border-color .15s;
}

.stat-card:hover {
  border-color: var(--accent);
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.stat-icon--blue {
  background: rgba(255, 69, 0, .15);
  color: var(--accent);
}

.stat-icon--green {
  background: rgba(220, 38, 38, .15);
  color: var(--danger);
}

.stat-icon--orange {
  background: rgba(239, 68, 68, .12);
  color: #f87171;
}

.stat-content {
  display: flex;
  flex-direction: column;
}

.stat-value {
  font-size: 26px;
  font-weight: 700;
  line-height: 1.1;
}

.stat-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ====== Grid ====== */
.grid-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

/* ====== Tables ====== */
.table {
  width: 100%;
  border-collapse: collapse;
}

.table th {
  text-align: left;
  padding: 12px 16px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-muted);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.table td {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
}

.table tr:last-child td {
  border-bottom: none;
}

.table tbody tr {
  transition: background 0.2s;
}

.table tbody tr:hover {
  background: rgba(255, 69, 0, 0.03);
}

.table-footer {
  padding: 10px 20px;
  font-size: 12px;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
}

.dns-table .dns-name {
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dns-table .dns-content {
  max-width: 280px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: monospace;
  font-size: 12px;
}

/* ====== DNS Types ====== */
.dns-type {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  font-family: monospace;
  letter-spacing: .03em;
}

.dns-type--blue {
  background: rgba(37, 99, 235, .2);
  color: #60a5fa;
}

.dns-type--purple {
  background: rgba(168, 85, 247, .2);
  color: #c084fc;
}

.dns-type--green {
  background: rgba(34, 197, 94, .2);
  color: #4ade80;
}

.dns-type--orange {
  background: rgba(249, 115, 22, .2);
  color: #fb923c;
}

.dns-type--yellow {
  background: rgba(234, 179, 8, .2);
  color: #facc15;
}

.dns-type--teal {
  background: rgba(20, 184, 166, .2);
  color: #2dd4bf;
}

.dns-type--pink {
  background: rgba(236, 72, 153, .2);
  color: #f472b6;
}

.dns-type--red {
  background: rgba(239, 68, 68, .2);
  color: #f87171;
}

.dns-type--gray {
  background: rgba(107, 114, 128, .2);
  color: #9ca3af;
}

.proxy-badge {
  font-size: 11px;
}

.proxied {
  color: var(--orange);
}

.dns-only {
  color: var(--text-muted);
}

/* ====== Buttons ====== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  border: 1px solid transparent;
  transition: all .15s;
  white-space: nowrap;
}

.btn:disabled {
  opacity: .5;
  cursor: not-allowed;
  pointer-events: none;
}

.btn-primary {
  background: linear-gradient(135deg, #ff4500, #dc2626);
  color: #fff;
  border: none;
  box-shadow: 0 4px 15px rgba(255, 69, 0, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #f97316, #ef4444);
  box-shadow: 0 6px 20px rgba(255, 69, 0, 0.4);
  transform: translateY(-1px);
}

.btn-danger {
  background: rgba(239, 68, 68, .15);
  color: #fca5a5;
  border-color: rgba(239, 68, 68, .3);
}

.btn-danger:hover {
  background: var(--danger);
  color: #fff;
  box-shadow: 0 4px 15px rgba(220, 38, 38, 0.3);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border-color: rgba(255, 255, 255, 0.1);
}

.btn-ghost:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
}

.btn-secondary {
  background: rgba(255, 69, 0, 0.1);
  color: #ff4500;
  border-color: rgba(255, 69, 0, 0.3);
}

.btn-secondary:hover {
  background: rgba(255, 69, 0, 0.2);
  color: #fff;
}

.btn-block {
  width: 100%;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
}

.btn-xs {
  padding: 4px 8px;
  font-size: 11px;
}

/* ====== Forms ====== */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
}

.form-input {
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  transition: all .2s;
  width: 100%;
  font-family: inherit;
}

.form-input:focus {
  border-color: var(--accent);
  background: rgba(0, 0, 0, 0.4);
  box-shadow: 0 0 0 3px rgba(255, 69, 0, 0.15);
}

.form-input[readonly] {
  color: var(--text-muted);
  cursor: default;
}

.form-select {
  appearance: none;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236e7681' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 32px;
}

.form-input-sm {
  padding: 6px 10px;
  font-size: 12px;
}

.form-hint {
  font-size: 11px;
  color: var(--text-muted);
}

.form-row {
  display: flex;
  gap: 14px;
}

.form-row .form-group {
  flex: 1;
}

.form-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.required {
  color: var(--danger);
}

.link {
  color: var(--accent);
  text-decoration: none;
}

.link:hover {
  text-decoration: underline;
}

/* Input with icon */
.input-wrapper {
  position: relative;
}

.input-wrapper .form-input {
  padding-left: 36px;
}

.input-icon {
  position: absolute;
  left: 11px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

.input-eye {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px;
}

.input-eye:hover {
  color: var(--text-primary);
}

.input-wrapper .form-input {
  padding-right: 36px;
}

/* Toggle */
.toggle-label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}

.toggle-label input {
  display: none;
}

.toggle {
  width: 38px;
  height: 20px;
  background: var(--border);
  border-radius: 10px;
  position: relative;
  transition: background .2s;
  flex-shrink: 0;
}

.toggle::after {
  content: '';
  position: absolute;
  left: 2px;
  top: 2px;
  width: 16px;
  height: 16px;
  background: #fff;
  border-radius: 50%;
  transition: left .2s;
}

.toggle-label input:checked+.toggle {
  background: var(--accent);
}

.toggle-label input:checked+.toggle::after {
  left: 20px;
}

/* ====== Alerts ====== */
.alert {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  font-size: 13px;
}

.alert-success {
  background: rgba(34, 197, 94, .1);
  color: var(--success);
  border: 1px solid rgba(34, 197, 94, .25);
}

.alert-danger {
  background: rgba(239, 68, 68, .1);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, .25);
}

.alert-warning {
  background: rgba(245, 158, 11, .1);
  color: var(--warning);
  border: 1px solid rgba(245, 158, 11, .25);
}

.alert-close {
  margin-left: auto;
  background: none;
  border: none;
  color: inherit;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  opacity: .6;
}

.alert-close:hover {
  opacity: 1;
}

/* ====== Badges ====== */
.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
  background: var(--bg-hover);
  color: var(--text-secondary);
}

.badge-domain {
  background: rgba(255, 69, 0, .15);
  color: #ff4500;
  font-family: monospace;
  font-size: 12px;
}

.status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
}

.status-active {
  background: rgba(34, 197, 94, .12);
  color: var(--success);
}

.status-inactive {
  background: rgba(239, 68, 68, .12);
  color: var(--danger);
}

.status-pending {
  background: rgba(245, 158, 11, .12);
  color: var(--warning);
}

/* ====== Modal ====== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  backdrop-filter: blur(4px);
}

.modal-overlay.open {
  display: flex;
}

.modal {
  background: var(--bg-primary);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  width: 90%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.8), 0 0 40px rgba(255, 69, 0, 0.05);
  animation: modalIn .25s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-lg {
  max-width: 680px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
}

.modal-header h3 {
  font-size: 16px;
  font-weight: 600;
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
}

.modal-close:hover {
  color: var(--text-primary);
}

.modal-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.modal-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

@keyframes modalIn {
  from {
    opacity: 0;
    transform: scale(.96) translateY(-8px);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ====== Steps (Domain Ekle) ====== */
.step-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px;
}

.step-header {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  margin-bottom: 14px;
  font-size: 13px;
}

.step-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}

/* ====== Domain Grid (User Dashboard) ====== */
.domain-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.domain-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.04);
  background: rgba(255, 255, 255, 0.01);
  text-decoration: none;
  color: var(--text-primary);
  transition: all .2s ease;
}

.domain-card:hover {
  border-color: rgba(255, 69, 0, 0.3);
  background: rgba(255, 69, 0, 0.04);
  box-shadow: 0 4px 20px rgba(255, 69, 0, 0.05);
  transform: translateY(-1px);
}

.domain-card-icon {
  color: var(--accent);
  flex-shrink: 0;
}

.domain-card-info {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.domain-name {
  font-weight: 600;
  font-size: 14px;
}

.domain-status {
  font-size: 11px;
}

/* ====== Domain Switcher (DNS) ====== */
.domain-switcher {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}

.domain-tab {
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid var(--border);
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
  color: var(--text-secondary);
  transition: all .15s;
}

.domain-tab:hover {
  border-color: #ff4500;
  color: #ff4500;
  background: rgba(255, 69, 0, 0.05);
}

.domain-tab.active {
  background: var(--accent-glow);
  border-color: var(--accent);
  color: var(--accent);
}

/* ====== Empty States ====== */
.empty-state {
  color: var(--text-muted);
  text-align: center;
  padding: 24px;
}

.empty-state-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 48px;
  color: var(--text-muted);
  text-align: center;
}

/* ====== Misc ====== */
.code-sm {
  font-family: 'Courier New', monospace;
  font-size: 11px;
  color: var(--text-muted);
}

.actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.user-cell {
  display: flex;
  align-items: center;
  gap: 8px;
}

.spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255, 255, 255, .3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .6s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ====== Responsive ====== */
@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .main-content {
    margin-left: 0;
  }

  .sidebar-toggle {
    display: flex;
  }

  .grid-2col {
    grid-template-columns: 1fr;
  }

  .form-row {
    flex-direction: column;
  }

  .stats-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* ====== SSL/TLS ====== */
.ssl-mode-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.ssl-mode-card {
  background: var(--bg-secondary);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  cursor: pointer;
  transition: border-color .15s;
}

.ssl-mode-card:hover {
  border-color: var(--accent);
}

.ssl-mode-card--active {
  border-color: var(--accent);
  background: var(--accent-glow);
}

.ssl-mode-top {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ssl-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.ssl-dot--red {
  background: var(--danger);
}

.ssl-dot--yellow {
  background: var(--warning);
}

.ssl-dot--blue {
  background: var(--accent);
}

.ssl-dot--green {
  background: var(--success);
}

.ssl-mode-label {
  font-weight: 600;
  font-size: 14px;
}

.ssl-active-badge {
  margin-left: auto;
  font-size: 10px;
  font-weight: 600;
  background: var(--accent);
  color: #fff;
  padding: 2px 7px;
  border-radius: 10px;
}

.ssl-mode-desc {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* SSL toggle button */
.ssl-settings-table td {
  vertical-align: middle;
}

.ssl-desc {
  font-size: 12px;
  color: var(--text-muted);
}

.ssl-toggle-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  width: 42px;
  height: 24px;
  border-radius: 12px;
  background: var(--border);
  border: none;
  cursor: pointer;
  transition: background .2s;
  vertical-align: middle;
  flex-shrink: 0;
  padding: 0;
}

.ssl-toggle-btn--on {
  background: var(--accent);
}

.ssl-toggle-knob {
  position: absolute;
  left: 3px;
  top: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  transition: left .2s;
  box-shadow: 0 1px 4px rgba(0, 0, 0, .3);
}

.ssl-toggle-btn--on .ssl-toggle-knob {
  left: 21px;
}

.ssl-toggle-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-left: 8px;
  vertical-align: middle;
}

/* Cert info */
.cert-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.cert-info-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

.cert-label {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
}

.cert-value {
  display: block;
  font-weight: 600;
  font-size: 14px;
  margin-top: 2px;
}