/**
 * FreeHosting247 - Client Area Dashboard CSS
 * Extracted from site-mockups/dashboard-design.html
 * Phase 1 of new client area design rollout (2026-07-18).
 *
 * Notes:
 * - Pure CSS, no Tailwind / no Font Awesome. Uses Google Fonts (Outfit, Sora).
 * - Designed for use with includes/layout-v2/header.php + footer.php.
 * - All chrome (sidebar, topbar, cards, charts) lives here.
 */

:root {
  --bg: #F6F7FA;
  --card: #FFFFFF;
  --ink: #0B1220;
  --muted: #5D6C85;
  --line: #E8ECF2;
  --accent: #FF6A00;
  --accent-2: #FF8E30;
  --accent-soft: #FFF2E6;
  --success: #10B981;
  --warning: #F59E0B;
  --danger: #EF4444;
  --info: #3B82F6;
  --sidebar: #0B0E14;
  --sidebar-hover: #151922;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 14px 34px rgba(11, 18, 32, 0.06);
  --shadow-lg: 0 24px 60px rgba(11, 18, 32, 0.12);
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: 'Outfit', sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

.dashboard { display: flex; height: 100vh; overflow: hidden; }

/* SIDEBAR */
.sidebar {
  width: 250px;
  background: var(--sidebar);
  display: flex;
  flex-direction: column;
  padding: 22px 14px 16px;
  flex-shrink: 0;
  overflow-y: auto;
  overflow-x: hidden;
}
.sidebar::-webkit-scrollbar { width: 6px; }
.sidebar::-webkit-scrollbar-thumb { background: #1F2530; border-radius: 3px; }
.brand { display: flex; align-items: center; gap: 12px; padding: 0 8px 18px; }
.brand-mark {
  width: 38px; height: 38px; border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  display: grid; place-items: center;
  box-shadow: 0 8px 22px rgba(255, 106, 0, 0.35);
}
.brand-mark svg { width: 22px; height: 22px; color: #fff; }
.brand-text h1 {
  font-family: 'Sora', sans-serif;
  font-size: 18px; font-weight: 700;
  color: #fff; margin: 0; letter-spacing: -0.3px;
}
.brand-text span {
  font-size: 11px; color: #8B94A7;
  text-transform: uppercase; letter-spacing: 1.5px;
}
.brand-link {
  display: inline-flex; align-items: center; text-decoration: none;
  border-radius: 8px;
  transition: opacity 0.18s ease;
}
.brand-link:hover { opacity: 0.85; }
.brand-logo {
  display: block;
  height: auto;
  max-width: 180px;
  width: 100%;
}

nav { flex: 1; display: flex; flex-direction: column; gap: 4px; min-height: 0; }
nav a {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 12px; border-radius: 9px;
  color: #9CA3AF; text-decoration: none;
  font-size: 13.5px; font-weight: 500;
  transition: 0.18s ease;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}
nav a > span:first-child,
nav a > b:first-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
nav a > svg:first-of-type { flex-shrink: 0; }
nav a:hover { background: var(--sidebar-hover); color: #fff; }

/* Nav count badge (e.g., "0/1" next to Request Hosting). Sized small,
   right-aligned via margin-left:auto, and highlighted when the user is
   at the plan's hosting-account limit so it acts as a visual nudge. */
nav a .nav-label-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
nav a .nav-count {
  margin-left: auto;
  flex-shrink: 0;
  font-size: 10.5px;
  font-weight: 600;
  font-family: 'SFMono-Regular', Consolas, monospace;
  letter-spacing: 0.2px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  padding: 2px 7px;
  border-radius: 10px;
  line-height: 1.4;
}
nav a:hover .nav-count { color: #C9CED8; }
nav a.active .nav-count { background: rgba(255, 106, 0, 0.18); color: #fff; }
nav a .nav-count--at-limit {
  background: rgba(239, 68, 68, 0.18);
  color: #FCA5A5;
}
nav a.active .nav-count--at-limit { background: rgba(239, 68, 68, 0.30); color: #fff; }
nav a.active { background: rgba(255, 106, 0, 0.12); color: #fff; }
nav a.active svg { color: var(--accent); }
nav a svg { width: 18px; height: 18px; color: #6B7280; transition: 0.18s ease; }
nav a:hover svg { color: #C9CED8; }

.nav-section-label {
  font-size: 10.5px; color: #6B7280;
  text-transform: uppercase; letter-spacing: 1.2px;
  padding: 14px 12px 6px;
  font-weight: 600;
}

/* Admin Panel link: visually distinct from user nav, only renders for admin/support roles */
.nav-admin-link { color: #FFB98C; }
.nav-admin-link:hover { color: #fff; background: rgba(255, 106, 0, 0.10); }
.nav-admin-link svg { color: var(--accent); }
.nav-admin-link.active { background: rgba(255, 106, 0, 0.18); color: #fff; }
.nav-admin-link.active svg { color: var(--accent); }

.promo {
  margin-top: auto;
  background: linear-gradient(145deg, #171B26, #0E121A);
  border: 1px solid #222836;
  border-radius: var(--radius-sm);
  padding: 14px;
  position: relative;
  overflow: hidden;
}
.promo::before {
  content: ''; position: absolute; right: -30px; top: -30px;
  width: 100px; height: 100px;
  background: radial-gradient(circle, rgba(255, 106, 0, 0.22), transparent 70%);
}
.promo-icon {
  width: 34px; height: 34px; border-radius: 9px;
  background: rgba(255, 106, 0, 0.15);
  display: grid; place-items: center; margin-bottom: 10px;
}
.promo-icon svg { color: var(--accent); width: 18px; height: 18px; }
.promo h3 { font-size: 14px; color: #fff; margin: 0 0 4px; font-weight: 600; }
.promo p { font-size: 12px; color: #8B94A7; margin: 0 0 12px; line-height: 1.5; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px; border: none; cursor: pointer;
  font-family: inherit; font-weight: 600; font-size: 13px;
  padding: 10px 18px; border-radius: 9px;
  transition: 0.18s ease;
}
.btn-primary {
  background: var(--accent); color: #fff;
  box-shadow: 0 6px 18px rgba(255, 106, 0, 0.28);
}
.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active,
.btn-primary:visited {
  background: #E85F00; color: #fff;
  transform: translateY(-1px);
}
.btn-ghost { background: transparent; color: var(--muted); border: 1px solid var(--line); }
.btn-ghost:hover,
.btn-ghost:focus,
.btn-ghost:active { background: #F6F7FA; color: var(--muted); }
.btn-sm { padding: 7px 13px; font-size: 12px; }

.support-mini {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 8px; padding: 11px 12px;
  border-radius: 9px; background: #151922;
  border: 1px solid #222836;
  color: #9CA3AF; font-size: 13px;
  text-decoration: none;
  transition: 0.18s ease;
}
.support-mini:hover { background: #1B2030; color: #fff; }
.support-mini svg { width: 18px; height: 18px; color: #6B7280; }

/* MAIN */
.main { flex: 1; display: flex; flex-direction: column; overflow: hidden; }
.topbar {
  height: 74px; background: var(--card);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 30px; flex-shrink: 0;
}
.search {
  display: flex; align-items: center; gap: 10px;
  background: var(--bg); border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 14px; width: 340px;
}
.search svg { color: var(--muted); width: 18px; height: 18px; }
.search input {
  border: none; background: transparent;
  font-size: 14px; color: var(--ink);
  outline: none; width: 100%; font-family: inherit;
}
.search input::placeholder { color: #9CA4B2; }
.search kbd {
  font-size: 11px; color: #9CA4B2;
  background: #fff; border: 1px solid var(--line);
  padding: 3px 7px; border-radius: 5px; font-family: inherit;
}
.topbar-actions { display: flex; align-items: center; gap: 18px; }
.icon-btn {
  width: 42px; height: 42px; border-radius: 12px;
  background: var(--bg); border: 1px solid var(--line);
  display: grid; place-items: center;
  position: relative; cursor: pointer;
  transition: 0.18s ease;
}
.icon-btn:hover { background: #fff; box-shadow: var(--shadow); }
.icon-btn svg { width: 20px; height: 20px; color: var(--muted); }
.badge {
  position: absolute; top: -3px; right: -3px;
  min-width: 20px; height: 20px;
  background: var(--danger); color: #fff;
  font-size: 11px; font-weight: 700;
  display: grid; place-items: center;
  border-radius: 50%; border: 2px solid var(--card);
  padding: 0 5px;
}
.profile {
  display: flex; align-items: center; gap: 12px;
  cursor: pointer;
  padding: 6px 8px 6px 6px; border-radius: 12px;
  transition: 0.18s ease;
}
.profile:hover { background: var(--bg); }
.avatar {
  width: 40px; height: 40px; border-radius: 50%;
  object-fit: cover; background: #E8ECF2;
}
.profile-info { line-height: 1.2; }
.profile-info strong { font-size: 14px; font-weight: 600; }
.profile-info span { display: block; font-size: 12px; color: var(--accent); font-weight: 600; }
.profile svg { color: var(--muted); width: 16px; height: 16px; }

/* Profile dropdown (topbar) */
.profile-dropdown { position: relative; }
.profile-trigger {
  display: flex; align-items: center; gap: 12px;
  cursor: pointer;
  padding: 6px 8px 6px 6px; border-radius: 12px;
  border: none; background: transparent;
  color: inherit; font: inherit;
  transition: 0.18s ease;
}
.profile-trigger:hover { background: var(--bg); }
.profile-trigger:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.profile-trigger[aria-expanded="true"] { background: var(--bg); }
.profile-trigger .chevron {
  width: 14px; height: 14px;
  flex-shrink: 0;
  color: var(--muted);
  transition: transform 0.18s ease;
}
.profile-trigger[aria-expanded="true"] .chevron { transform: rotate(180deg); }

.profile-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 240px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 12px 32px rgba(11, 14, 20, 0.12), 0 4px 8px rgba(11, 14, 20, 0.06);
  padding: 6px;
  z-index: 100;
  opacity: 0; transform: translateY(-4px);
  transition: opacity 0.18s ease, transform 0.18s ease;
  pointer-events: none;
}
.profile-menu:not([hidden]) {
  opacity: 1; transform: translateY(0);
  pointer-events: auto;
}
.profile-menu-header {
  display: flex; align-items: center; gap: 12px;
  padding: 10px;
}
.profile-menu-header .avatar { width: 36px; height: 36px; }
.profile-menu-meta { min-width: 0; flex: 1; }
.profile-menu-meta strong {
  display: block; font-size: 13px; font-weight: 600;
  color: var(--ink); line-height: 1.3;
}
.profile-menu-meta span {
  display: block; font-size: 12px; color: var(--muted);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  line-height: 1.3;
}
.profile-menu-divider {
  height: 1px;
  background: var(--line);
  margin: 4px 0;
}
.profile-menu-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 10px;
  border-radius: 8px;
  color: var(--ink);
  font-size: 13px; font-weight: 500;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}
.profile-menu-item:hover { background: var(--bg); }
.profile-menu-item i {
  color: var(--muted); font-size: 16px; width: 16px;
  flex-shrink: 0; text-align: center;
}
.profile-menu-item-danger { color: #B91C1C; }
.profile-menu-item-danger i { color: #B91C1C; }
.profile-menu-item-danger:hover { background: #FEF2F2; }

/* Notifications dropdown (topbar) */
.notifications-dropdown { position: relative; }
.notifications-trigger .badge {
  position: absolute; top: -2px; right: -2px;
  min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 9999px;
  background: var(--accent); color: #fff;
  font-size: 11px; font-weight: 700; line-height: 18px;
  text-align: center;
  border: 2px solid var(--card);
}
.notifications-trigger[aria-expanded="true"] { background: var(--bg); }

.notifications-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 380px; max-width: calc(100vw - 24px);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 12px 32px rgba(11, 14, 20, 0.12), 0 4px 8px rgba(11, 14, 20, 0.06);
  z-index: 100;
  opacity: 0; transform: translateY(-4px);
  transition: opacity 0.18s ease, transform 0.18s ease;
  pointer-events: none;
  overflow: hidden;
}
.notifications-menu:not([hidden]) {
  opacity: 1; transform: translateY(0);
  pointer-events: auto;
}
.notifications-menu-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
}
.notifications-menu-header strong {
  font-family: 'Sora', sans-serif;
  font-size: 14px; font-weight: 700; color: var(--ink);
}
.notifications-unread-count {
  font-size: 11px; font-weight: 600;
  background: rgba(255, 106, 0, 0.10); color: var(--accent);
  padding: 3px 8px; border-radius: 9999px;
}
.notifications-menu-list {
  max-height: 420px; overflow-y: auto;
}
.notifications-empty {
  text-align: center;
  padding: 40px 20px 32px;
  color: var(--muted);
}
.notifications-empty i { font-size: 32px; opacity: 0.4; display: block; margin-bottom: 10px; }
.notifications-empty p { margin: 0; font-weight: 600; color: var(--ink); font-size: 13px; }
.notifications-empty small { font-size: 12px; display: block; margin-top: 4px; }

.notification-item {
  position: relative;
  display: flex; align-items: flex-start; gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  transition: background 0.15s ease;
}
.notification-item:last-child { border-bottom: none; }
.notification-item:hover { background: var(--bg); }
.notification-icon {
  width: 32px; height: 32px; border-radius: 9px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 16px; flex-shrink: 0;
  background: rgba(255, 106, 0, 0.10); color: var(--accent);
}
.notification-item.severity-medium .notification-icon { background: rgba(245, 158, 11, 0.10); color: #B45309; }
.notification-item.severity-high .notification-icon,
.notification-item.severity-critical .notification-icon { background: rgba(239, 68, 68, 0.10); color: #B91C1C; }
.notification-body { flex: 1; min-width: 0; }
.notification-title {
  font-size: 13px; font-weight: 600; color: var(--ink);
  line-height: 1.35;
}
.notification-meta {
  display: flex; flex-wrap: wrap; gap: 10px;
  margin-top: 3px; font-size: 11px; color: var(--muted);
  line-height: 1.3;
}
.notification-meta span { display: inline-flex; align-items: center; gap: 4px; }
.notification-meta i { font-size: 12px; }
.notification-unread-dot {
  position: absolute; top: 16px; right: 14px;
  width: 8px; height: 8px; border-radius: 9999px;
  background: var(--accent);
  flex-shrink: 0;
}
.notification-item:not(.unread) .notification-unread-dot { display: none; }

.scroll { flex: 1; overflow-y: auto; padding: 30px; }
.scroll::-webkit-scrollbar { width: 8px; }
.scroll::-webkit-scrollbar-thumb { background: #D2D7DE; border-radius: 4px; }

.page-header { margin-bottom: 26px; }
.page-header h2 {
  font-family: 'Sora', sans-serif;
  font-size: 26px; font-weight: 700;
  margin: 0 0 4px; letter-spacing: -0.5px;
}
.page-header p { color: var(--muted); margin: 0; font-size: 14px; }

/* GRID */
.grid { display: grid; gap: 20px; }
.stats-row { grid-template-columns: repeat(5, 1fr); margin: 20px 0; }
.stats-row-six { grid-template-columns: repeat(6, 1fr); margin: 20px 0; gap: 14px; }
@media (max-width: 1500px) {
  .stats-row { grid-template-columns: repeat(3, 1fr); }
  .stats-row-six { grid-template-columns: repeat(3, 1fr); }
  .charts-row { grid-template-columns: 1fr; }
}
@media (max-width: 1100px) {
  .stats-row { grid-template-columns: repeat(2, 1fr); }
  .stats-row-six { grid-template-columns: repeat(2, 1fr); }
  .bottom-row { grid-template-columns: 1fr; }
}
.stat-card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px;
  display: flex; gap: 14px;
  box-shadow: var(--shadow);
  position: relative; overflow: hidden;
}
.stat-icon {
  width: 48px; height: 48px; border-radius: 12px;
  display: grid; place-items: center; flex-shrink: 0;
}
.stat-icon.orange { background: var(--accent-soft); color: var(--accent); }
.stat-icon.blue { background: #EFF6FF; color: var(--info); }
.stat-icon.green { background: #ECFDF5; color: var(--success); }
.stat-icon.purple { background: #F5F3FF; color: #8B5CF6; }
.stat-icon.red { background: #FEF2F2; color: var(--danger); }
.stat-icon.violet { background: #F5F3FF; color: #7C3AED; }
.stat-icon.cyan { background: #ECFEFF; color: #0891B2; }
.stat-icon.muted { background: #F2F5F9; color: var(--muted); }
.stat-icon svg { width: 24px; height: 24px; }
.stat-body { flex: 1; }
.stat-label { font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.stat-value { font-size: 24px; font-weight: 700; font-family: 'Sora', sans-serif; }
.stat-meta {
  display: flex; align-items: center; gap: 8px;
  margin-top: 8px; font-size: 12px; color: var(--muted);
}
.stat-meta .bar {
  flex: 1; height: 5px;
  background: #EDF0F5; border-radius: 3px; overflow: hidden;
}
.stat-meta .bar span {
  display: block; height: 100%;
  border-radius: 3px; background: var(--accent);
  width: 0%; transition: 1.2s ease;
}

.charts-row { grid-template-columns: 1.6fr 0.7fr 0.7fr; margin-bottom: 20px; }
.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px;
  box-shadow: var(--shadow);
  display: flex; flex-direction: column;
}
.card-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 18px;
}
.card-title { font-size: 16px; font-weight: 700; margin: 0; }
.card-sub { font-size: 12px; color: var(--muted); margin-top: 2px; font-weight: 400; }
.card-actions { display: flex; align-items: center; gap: 8px; }
.pill {
  font-size: 11px; font-weight: 600;
  padding: 5px 10px; border-radius: 20px;
  border: 1px solid var(--line);
  color: var(--muted); background: #fff;
  display: inline-flex; align-items: center; gap: 6px;
}
.pill.live {
  border-color: rgba(16, 185, 129, 0.25);
  color: var(--success); background: #ECFDF5;
}

.chart-area { flex: 1; position: relative; min-height: 210px; }
.line-chart { position: absolute; inset: 0; }
.line-chart svg { width: 100%; height: 100%; }
.donut-wrap {
  position: relative;
  width: 180px; height: 180px; margin: 0 auto;
}
.donut-center {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
}
.donut-center b { font-size: 26px; font-weight: 700; font-family: 'Sora', sans-serif; }
.donut-center span { font-size: 12px; color: var(--muted); }
.chart-legend {
  display: flex; justify-content: center; gap: 24px;
  margin-top: 18px; font-size: 13px; color: var(--muted);
}
.chart-legend i {
  width: 10px; height: 10px; border-radius: 50%;
  display: inline-block; margin-right: 7px;
}

.resource-row {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px;
}
.resource-row:last-child { margin-bottom: 0; }
.resource-label {
  display: flex; align-items: center; gap: 10px;
  font-size: 14px; font-weight: 500;
}
.resource-label svg { width: 18px; height: 18px; color: var(--muted); }
.resource-value { font-size: 14px; font-weight: 700; }
.resource-track {
  width: 100%; height: 8px;
  background: #EDF0F5; border-radius: 4px;
  overflow: hidden; margin-top: 8px;
}
.resource-track span {
  display: block; height: 100%;
  border-radius: 4px; width: 0%;
  transition: 1.2s ease;
}

.quick-list { display: flex; flex-direction: column; gap: 10px; }
.quick-item {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 14px; border-radius: 12px;
  background: #FAFBFD; border: 1px solid var(--line);
  cursor: pointer; transition: 0.18s ease;
}
.quick-item:hover {
  background: #fff; border-color: #D8DEE7;
  transform: translateX(2px);
}
.quick-icon {
  width: 34px; height: 34px; border-radius: 9px;
  background: var(--accent-soft); color: var(--accent);
  display: grid; place-items: center;
}
.quick-icon svg { width: 18px; height: 18px; }
.quick-text { flex: 1; }
.quick-text b { display: block; font-size: 13px; font-weight: 600; }
.quick-text span { font-size: 11px; color: var(--muted); }
.quick-item > svg { color: #B9C0CC; width: 16px; height: 16px; }

.table-row { grid-template-columns: 1.3fr 0.7fr; margin: 20px 0; }
.table-card { overflow: auto; }
table { width: 100%; border-collapse: collapse; min-width: 520px; }
th {
  text-align: left; font-size: 11px;
  text-transform: uppercase; letter-spacing: 1px;
  color: var(--muted); padding: 12px 14px;
  border-bottom: 1px solid var(--line); font-weight: 600;
}
td {
  padding: 14px; border-bottom: 1px solid var(--line);
  font-size: 13px; vertical-align: middle;
}
tr:last-child td { border-bottom: none; }
.site-cell { display: flex; align-items: center; gap: 12px; }
.site-avatar {
  width: 36px; height: 36px; border-radius: 10px;
  background: linear-gradient(135deg, #E8ECF2, #F2F5F9);
  display: grid; place-items: center;
  font-weight: 700; font-size: 14px; color: var(--muted);
}
.site-name { font-weight: 600; }
.site-url { font-size: 12px; color: var(--muted); }
.status-dot {
  width: 8px; height: 8px; border-radius: 50%;
  display: inline-block; margin-right: 6px;
}
.status-dot.green {
  background: var(--success);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.14);
}
.tag {
  font-size: 12px; font-weight: 600;
  color: var(--success); background: #ECFDF5;
  padding: 5px 10px; border-radius: 20px;
}
.tag.warn { color: var(--warning); background: #FEF3C7; }
.actions { display: flex; gap: 8px; }
.action-icon {
  width: 32px; height: 32px; border-radius: 8px;
  background: #FAFBFD; border: 1px solid var(--line);
  display: grid; place-items: center;
  color: var(--muted); cursor: pointer;
  transition: 0.18s ease;
}
.action-icon:hover {
  background: var(--accent-soft); color: var(--accent);
  border-color: rgba(255, 106, 0, 0.15);
}
.action-icon svg { width: 16px; height: 16px; }

.security-list { display: flex; flex-direction: column; gap: 14px; }
.security-item { display: flex; align-items: center; justify-content: space-between; }
.security-left { display: flex; align-items: center; gap: 12px; }
.security-icon {
  width: 34px; height: 34px; border-radius: 9px;
  background: #ECFDF5; color: var(--success);
  display: grid; place-items: center;
}
.security-icon.orange { background: var(--accent-soft); color: var(--accent); }
.security-icon.red { background: #FEF2F2; color: var(--danger); }
.security-icon svg { width: 18px; height: 18px; }
.security-title { font-size: 14px; font-weight: 600; }
.security-sub { font-size: 12px; color: var(--muted); }

.bottom-row { grid-template-columns: 1.1fr 1fr 1fr; margin: 20px 0; }
.account-card {
  background: linear-gradient(135deg, #0B0E14, #1A1F2D);
  color: #fff; border: none;
  position: relative; overflow: hidden;
}
.account-card::before {
  content: ''; position: absolute; right: -40px; top: -40px;
  width: 160px; height: 160px;
  background: radial-gradient(circle, rgba(255, 106, 0, 0.18), transparent 70%);
}
.account-card .card-title { color: #fff; position: relative; z-index: 1; }
.plan-block { position: relative; z-index: 1; }
.plan-name {
  font-size: 22px; font-weight: 700;
  font-family: 'Sora', sans-serif;
  margin: 10px 0 4px;
}
.plan-price { font-size: 14px; color: #9CA3AF; }
.plan-price b { color: #fff; }
.plan-limits { display: flex; gap: 20px; margin: 18px 0 22px; }
.limit { font-size: 13px; color: #9CA3AF; }
.limit b {
  display: block; color: #fff;
  font-size: 16px; font-family: 'Sora', sans-serif;
}
.btn-white {
  background: #fff; color: var(--ink);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
}
.btn-white:hover,
.btn-white:focus,
.btn-white:active { background: #F6F7FA; color: var(--ink); }

.timeline { display: flex; flex-direction: column; gap: 16px; }
.timeline-item { display: flex; gap: 14px; }
.timeline-dot {
  width: 32px; height: 32px; border-radius: 50%;
  background: #F2F5F9;
  display: grid; place-items: center; flex-shrink: 0;
}
.timeline-dot svg { width: 15px; height: 15px; color: var(--muted); }
.timeline-content { flex: 1; }
.timeline-title { font-size: 13px; font-weight: 600; margin-bottom: 2px; }
.timeline-time { font-size: 11px; color: var(--muted); }

.support-card .card-title { margin-bottom: 4px; }
.support-status {
  display: flex; align-items: center; gap: 10px;
  padding: 14px; border-radius: 12px;
  background: #ECFDF5; color: var(--success);
  font-size: 13px; font-weight: 600; margin-bottom: 18px;
}
.support-status svg { width: 18px; height: 18px; }
.support-link {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 12px 0; border-bottom: 1px solid var(--line);
  cursor: pointer; transition: 0.18s ease;
  text-decoration: none; color: inherit;
}
.support-link:last-child { border-bottom: none; padding-bottom: 0; }
.support-link:hover { color: var(--accent); }
.support-link b { font-size: 13px; font-weight: 600; display: block; }
.support-link span { font-size: 12px; color: var(--muted); }
.support-link svg {
  width: 18px; height: 18px; color: var(--muted);
  flex-shrink: 0; margin-top: 2px;
}

.footer-row {
  display: flex; align-items: center; justify-content: space-between;
  color: var(--muted); font-size: 12px;
  margin-top: 6px; padding: 0 4px;
}

/* reveal animation */
.reveal { opacity: 0; transform: translateY(16px); animation: reveal 0.7s ease forwards; }
.reveal:nth-child(1) { animation-delay: 80ms; }
.reveal:nth-child(2) { animation-delay: 160ms; }
.reveal:nth-child(3) { animation-delay: 240ms; }
.reveal:nth-child(4) { animation-delay: 320ms; }
.reveal:nth-child(5) { animation-delay: 400ms; }
.reveal:nth-child(6) { animation-delay: 480ms; }
@keyframes reveal { to { opacity: 1; transform: none; } }

/* Form elements (for future use) */
input, button, select, textarea { font-family: inherit; }
button { cursor: pointer; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: #E85F00; }

/* Toast / flash (for Phase 2) */
.toast {
  position: fixed; bottom: 20px; right: 20px;
  background: var(--ink); color: #fff;
  padding: 14px 20px; border-radius: 12px;
  box-shadow: var(--shadow-lg);
  display: flex; align-items: center; gap: 10px;
  font-size: 14px; font-weight: 500;
  z-index: 1000;
  animation: slideUp 0.3s ease;
}
.toast.success { background: var(--success); }
.toast.error { background: var(--danger); }
.toast.warning { background: var(--warning); }
@keyframes slideUp { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* =========================================================
   Admin settings / form helpers (Phase: settings page mockup)
   ========================================================= */

/* Alerts */
.alert {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 18px; border-radius: var(--radius-sm);
  font-size: 14px; font-weight: 500;
  margin-bottom: 20px;
}
.alert-success { background: #ECFDF5; color: #065F46; border: 1px solid rgba(16, 185, 129, 0.25); }
.alert-error { background: #FEF2F2; color: #991B1B; border: 1px solid rgba(239, 68, 68, 0.25); }
.alert svg { flex-shrink: 0; }

/* Tabs */
.tabs {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-bottom: 22px;
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 10px;
  box-shadow: var(--shadow);
}
.tab {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 14px; border-radius: 10px;
  font-size: 13px; font-weight: 600; color: var(--muted);
  text-decoration: none; transition: 0.18s ease;
  border: 1px solid transparent; background: transparent;
}
.tab:hover { background: var(--bg); color: var(--ink); }
.tab.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.tab.active svg { color: #fff; }
.tab i { font-size: 14px; }

/* Two-column page layout */
.dashboard-grid.two-col {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 22px;
  align-items: start;
}
@media (max-width: 1200px) {
  .dashboard-grid.two-col { grid-template-columns: 1fr; }
  .sidebar-column { order: 2; }
}
.content-column { display: flex; flex-direction: column; gap: 22px; }
.sidebar-column { display: flex; flex-direction: column; gap: 22px; }

/* Cards tweaks */
.card { overflow: visible; }
.card-header.compact { margin-bottom: 12px; }
.card-title {
  display: inline-flex; align-items: center; gap: 10px;
}
.text-subtitle { font-size: 13px; color: var(--muted); margin: 4px 0 0; }
.card-footer.compact { padding-top: 16px; margin-top: 8px; border-top: 1px solid var(--line); }

/* Forms */
.form-stack { display: flex; flex-direction: column; gap: 18px; }
.form-row {
  display: grid; gap: 16px;
}
.form-row.two-col { grid-template-columns: 1fr 1fr; }
.form-row.three-col { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) {
  .form-row.two-col,
  .form-row.three-col { grid-template-columns: 1fr; }
}
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label {
  font-size: 13px; font-weight: 600; color: var(--ink);
  display: inline-flex; align-items: center; gap: 8px;
}
.form-group input,
.form-group select,
.form-group textarea,
.form-stack input[type="text"],
.form-stack input[type="email"],
.form-stack input[type="url"],
.form-stack input[type="password"],
.form-stack input[type="number"],
.form-stack select,
.form-stack textarea {
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #FAFBFD;
  color: var(--ink);
  font-size: 14px;
  outline: none;
  transition: 0.18s ease;
  width: 100%;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus,
.form-stack input:focus,
.form-stack select:focus,
.form-stack textarea:focus,
input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(255, 106, 0, 0.10);
}
.form-group textarea { resize: vertical; min-height: 90px; }
.help-text {
  font-size: 12px; color: var(--muted);
  margin: 0; line-height: 1.45;
}
.help-text a { color: var(--accent); }
.help-text code {
  background: #F2F5F9; padding: 2px 6px; border-radius: 5px;
  font-size: 12px; color: var(--ink);
}

/* Form actions */
.form-actions {
  display: flex; justify-content: flex-end; gap: 12px;
  padding-top: 10px;
}
.form-actions.split { justify-content: space-between; flex-wrap: wrap; }
.form-actions .btn { min-width: 140px; }

.btn-secondary {
  background: var(--ink); color: #fff;
  box-shadow: 0 6px 18px rgba(11, 18, 32, 0.18);
}
.btn-secondary:hover,
.btn-secondary:focus,
.btn-secondary:active { background: #1F2A3D; color: #fff; }
.btn-primary.danger { background: var(--danger); box-shadow: 0 6px 18px rgba(239, 68, 68, 0.28); }
.btn-primary.danger:hover { background: #DC2626; }

/* Checkbox cards */
.checkbox-card,
.checkbox-row {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 14px 16px; border-radius: 12px;
  background: #FAFBFD; border: 1px solid var(--line);
  cursor: pointer; transition: 0.18s ease;
}
.checkbox-card:hover,
.checkbox-row:hover { border-color: #D8DEE7; background: #fff; }
.checkbox-card input[type="checkbox"],
.checkbox-row input[type="checkbox"],
.checkbox-row input[type="radio"] {
  width: 18px; height: 18px; accent-color: var(--accent);
  margin-top: 2px; flex-shrink: 0;
}
.checkbox-card > div,
.checkbox-row > span { flex: 1; }
.checkbox-card span,
.checkbox-row span { font-size: 14px; font-weight: 600; color: var(--ink); }
.checkbox-card p,
.checkbox-row p { font-size: 13px; color: var(--muted); margin: 2px 0 0; }
.checkbox-card.info { background: #EFF6FF; border-color: rgba(59, 130, 246, 0.20); }
.checkbox-card.success { background: #ECFDF5; border-color: rgba(16, 185, 129, 0.20); }
.checkbox-card.warning { background: #FEF3C7; border-color: rgba(245, 158, 11, 0.20); }
.checkbox-card.danger { background: #FEF2F2; border-color: rgba(239, 68, 68, 0.20); }
.checkbox-card.info span { color: #1E40AF; }
.checkbox-card.success span { color: #065F46; }
.checkbox-card.warning span { color: #92400E; }
.checkbox-card.danger span { color: #991B1B; }
.checkbox-card.info p,
.checkbox-card.success p,
.checkbox-card.warning p,
.checkbox-card.danger p { color: var(--muted); }
.checkbox-row.compact { align-items: center; padding: 10px 12px; }

.checkbox-list,
.checkbox-grid { display: flex; flex-direction: column; gap: 10px; }
.checkbox-grid { display: grid; grid-template-columns: 1fr 1fr; }
@media (max-width: 700px) { .checkbox-grid { grid-template-columns: 1fr; } }

/* Section labels inside cards */
.section-label {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 700; color: var(--ink);
  margin: 6px 0 2px;
}

/* Info / hint boxes */
.info-box {
  padding: 18px; border-radius: 12px;
  background: #FAFBFD; border: 1px solid var(--line);
}
.info-box .info-title {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 700; margin: 0 0 10px;
}
.info-box .help-text { margin-bottom: 8px; }
.info-box .help-text:last-child { margin-bottom: 0; }
.info-box.blue { background: #EFF6FF; border-color: rgba(59, 130, 246, 0.20); color: #1E3A8A; }
.info-box.blue .info-title { color: #1E40AF; }
.info-box.violet { background: #F5F3FF; border-color: rgba(139, 92, 246, 0.20); color: #4C1D95; }
.info-box.violet .info-title { color: #5B21B6; }
.info-box.amber { background: #FFFBEB; border-color: rgba(245, 158, 11, 0.20); color: #78350F; }
.info-box.amber .info-title { color: #92400E; }
.info-box.orange { background: #FFF7ED; border-color: rgba(249, 115, 22, 0.20); color: #7C2D12; }
.info-box.orange .info-title { color: #9A3412; }
.info-box .compact-list { padding-left: 18px; margin: 0; }
.info-box .compact-list li { margin-bottom: 6px; }
.info-box .compact-list li:last-child { margin-bottom: 0; }

/* Inline form (test buttons next to inputs) */
.inline-form { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-start; }
.inline-form input { flex: 1; min-width: 200px; }

/* Encrypted badge */
.encrypted-tag {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 11px; font-weight: 600;
  color: var(--success); background: #ECFDF5;
  padding: 2px 7px; border-radius: 20px;
}
.encrypted-tag svg { width: 11px; height: 11px; }

/* Provider grid (CAPTCHA) */
.provider-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px;
}
@media (max-width: 700px) { .provider-grid { grid-template-columns: 1fr; } }
.provider-card {
  display: flex; align-items: center; gap: 12px;
  padding: 16px; border-radius: 12px;
  border: 2px solid var(--line); background: var(--card);
  cursor: pointer; transition: 0.18s ease;
}
.provider-card:hover { border-color: #D8DEE7; }
.provider-card.selected {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.provider-card input { display: none; }
.provider-card i { font-size: 20px; color: var(--muted); flex-shrink: 0; }
.provider-card.selected i { color: var(--accent); }
.provider-card span { font-size: 14px; font-weight: 600; }

/* Hidden helper (replaces Tailwind .hidden) */
.hidden { display: none !important; }

/* Stat list (API stats etc) */
.stat-list { display: flex; flex-direction: column; gap: 10px; }
.stat-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px; border-radius: 10px;
  background: #FAFBFD; border: 1px solid var(--line);
}
.stat-row.success { background: #ECFDF5; border-color: rgba(16, 185, 129, 0.20); }
.stat-row.danger { background: #FEF2F2; border-color: rgba(239, 68, 68, 0.20); }
.stat-row .stat-label { font-size: 13px; color: var(--muted); font-weight: 500; margin: 0; }
.stat-row.success .stat-label { color: #065F46; }
.stat-row.danger .stat-label { color: #991B1B; }
.stat-row .stat-value { font-size: 18px; font-weight: 700; font-family: 'Sora', sans-serif; }
.stat-row.success .stat-value { color: var(--success); }
.stat-row.danger .stat-value { color: var(--danger); }

/* Quick links sidebar */
.quick-links { display: flex; flex-direction: column; gap: 6px; }
.quick-link {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 12px; border-radius: 10px;
  font-size: 14px; font-weight: 500; color: var(--ink);
  text-decoration: none; transition: 0.18s ease;
}
.quick-link:hover { background: var(--bg); color: var(--accent); }
.quick-link i { font-size: 16px; color: var(--muted); width: 20px; text-align: center; }

/* =========================================================
   Tickets page mockup (Phase: admin/tickets.php)
   ========================================================= */

.flex-1 { flex: 1; min-width: 0; }

.back-link {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 600; color: var(--muted);
  text-decoration: none; margin-bottom: 18px;
  transition: 0.18s ease;
}
.back-link:hover { color: var(--accent); }

.alert-warning { background: #FFFBEB; color: #92400E; border: 1px solid rgba(245, 158, 11, 0.25); }
.alert-info    { background: #EFF6FF; color: #1E40AF; border: 1px solid rgba(59, 130, 246, 0.25); }

/* Tag variants */
.tag-default { color: var(--muted); background: #F2F5F9; }
.tag-success { color: #065F46; background: #ECFDF5; }
.tag-danger  { color: #991B1B; background: #FEF2F2; }
.tag-warn    { color: #9A3412; background: #FFF7ED; }
.tag-amber   { color: #92400E; background: #FEF3C7; }
.tag-info    { color: #1E40AF; background: #EFF6FF; }
.tag-cyan    { color: #155E75; background: #ECFEFF; }
.tag-violet  { color: #5B21B6; background: #F5F3FF; }

/* Ticket view badges */
.ticket-badges { display: flex; gap: 8px; flex-wrap: wrap; }

/* Ticket description */
.ticket-description {
  background: var(--bg); border-radius: 12px;
  padding: 16px; font-size: 14px; line-height: 1.6; color: var(--ink);
  white-space: pre-wrap; word-wrap: break-word;
}
.text-muted-italic { color: var(--muted); font-style: italic; }

/* Conversation thread */
.conversation-thread {
  display: flex; flex-direction: column; gap: 16px;
  max-height: 500px; overflow-y: auto;
}
.empty-state {
  text-align: center; color: var(--muted);
  padding: 32px 0; font-size: 13px;
}
.message-bubble {
  display: flex; gap: 12px;
  align-items: flex-start;
}
.message-bubble.admin { flex-direction: row-reverse; }
.message-bubble.admin .message-content { text-align: right; }
.message-avatar {
  width: 40px; height: 40px; border-radius: 50%;
  background: #F2F5F9; color: var(--muted);
  display: grid; place-items: center; flex-shrink: 0;
}
.message-bubble.admin .message-avatar {
  background: var(--accent-soft); color: var(--accent);
}
.message-content {
  flex: 1; min-width: 0;
  background: var(--bg); border: 1px solid var(--line);
  border-radius: 12px; padding: 14px 16px;
  text-align: left;
}
.message-bubble.admin .message-content {
  background: var(--accent-soft); border-color: rgba(255, 106, 0, 0.18);
}
.message-meta {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 6px;
  justify-content: flex-start;
}
.message-bubble.admin .message-meta { justify-content: flex-end; }
.message-author { font-size: 13px; font-weight: 600; color: var(--ink); }
.staff-badge {
  font-size: 10px; font-weight: 700;
  background: var(--accent); color: #fff;
  padding: 2px 6px; border-radius: 10px;
  text-transform: uppercase; letter-spacing: 0.4px;
}
.message-text {
  font-size: 14px; line-height: 1.55; color: var(--ink);
  white-space: pre-wrap; word-wrap: break-word;
}
.message-time {
  font-size: 11px; color: var(--muted); margin-top: 8px;
}

/* Reply form */
.reply-actions {
  display: flex; justify-content: space-between;
  align-items: center; gap: 16px; flex-wrap: wrap;
  padding-top: 8px;
}
.status-inline { display: flex; align-items: center; gap: 8px; }
.status-inline label {
  font-size: 13px; font-weight: 600; color: var(--ink);
}
.status-inline select { min-width: 160px; }

.shortcut-hint {
  margin-top: 8px; font-size: 13px;
  background: #FFFBEB; border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: 8px; padding: 8px 12px; color: #92400E;
}

/* Customer card */
.customer-card { display: flex; flex-direction: column; gap: 14px; }
.customer-head { display: flex; align-items: center; gap: 14px; }
.customer-avatar {
  width: 48px; height: 48px; border-radius: 50%;
  background: #F2F5F9; color: var(--muted);
  display: grid; place-items: center; flex-shrink: 0;
}
.customer-name { font-size: 14px; font-weight: 600; margin: 0; color: var(--ink); }
.customer-email { font-size: 13px; color: var(--accent); text-decoration: none; }
.customer-email:hover { text-decoration: underline; }

/* Info list (Ticket Information sidebar) */
.info-list { display: flex; flex-direction: column; gap: 10px; }
.info-row {
  display: flex; justify-content: space-between;
  gap: 12px; font-size: 13px;
  padding: 8px 0; border-bottom: 1px solid var(--line);
}
.info-row:last-child { border-bottom: none; }
.info-row > span { color: var(--muted); }
.info-row > b { color: var(--ink); font-weight: 600; text-align: right; }
.info-sub { font-size: 11px; color: var(--muted); font-weight: 400; display: block; }

/* Buttons */
.btn-block { width: 100%; }
.btn-danger {
  background: #FEF2F2; color: var(--danger);
  border: 1px solid rgba(239, 68, 68, 0.25);
}
.btn-danger:hover { background: var(--danger); color: #fff; border-color: var(--danger); }
.action-icon.danger:hover {
  background: #FEF2F2; color: var(--danger); border-color: rgba(239, 68, 68, 0.25);
}

/* Inline form variants */
.inline-form.compact { margin-bottom: 10px; }
.inline-form.compact:last-child { margin-bottom: 0; }

/* Ticket filters */
.ticket-filters {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
}
.search-inline {
  display: flex; align-items: center; gap: 10px;
  background: var(--bg); border: 1px solid var(--line);
  border-radius: 10px; padding: 9px 12px;
  min-width: 220px;
}
.search-inline svg { color: var(--muted); flex-shrink: 0; }
.search-inline input {
  border: none; background: transparent; outline: none;
  padding: 0;
  font-size: 14px; font-family: inherit;
  color: var(--ink); width: 100%; min-width: 0;
}
.search-inline input:focus { box-shadow: none; }
.search-inline input::placeholder { color: #9CA4B2; }
.ticket-filters select { min-width: 140px; }

/* Tickets table */
.table-card { padding: 0; }
.table-card .card-header { padding: 18px 22px; margin: 0; border-bottom: 1px solid var(--line); }
.table-scroll { overflow-x: auto; }
.ticket-cell { display: flex; flex-direction: column; gap: 4px; }
.ticket-subject {
  font-weight: 600; color: var(--ink); text-decoration: none;
}
.ticket-subject:hover { color: var(--accent); }
.ticket-meta { display: flex; gap: 10px; font-size: 11px; color: var(--muted); }
.ticket-meta i { font-size: 11px; }
.user-link { color: var(--accent); font-size: 13px; font-weight: 500; text-decoration: none; }
.user-link:hover { text-decoration: underline; }
.actions-cell {
  display: flex; gap: 6px; justify-content: flex-end; align-items: center;
}
.actions-cell form { display: inline; }
.actions-cell .action-icon { width: 30px; height: 30px; }
.actions-cell .action-icon svg { width: 14px; height: 14px; }
.empty-cell { padding: 40px 20px; text-align: center; }
.empty-icon {
  width: 48px; height: 48px; border-radius: 12px;
  background: #F2F5F9; color: var(--muted);
  display: inline-grid; place-items: center; margin-bottom: 10px;
}
.empty-cell p { color: var(--muted); font-size: 14px; margin: 0; }

/* Stat card active state */
.stat-card.active { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255, 106, 0, 0.10); }

/* Pagination */
.pagination {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 22px; border-top: 1px solid var(--line);
  flex-wrap: wrap; gap: 12px;
}
.pagination-info { font-size: 13px; color: var(--muted); margin: 0; }
.pagination-actions { display: flex; gap: 8px; }

/* =========================================================
   Canned Responses page mockup (Phase: admin/canned-responses.php)
   ========================================================= */

.card.sticky { position: sticky; top: 16px; }

.required-mark { color: var(--danger); margin-left: 2px; }

.count-pill {
  display: inline-flex; align-items: center;
  font-size: 11px; font-weight: 700;
  color: var(--muted); background: var(--bg);
  padding: 2px 9px; border-radius: 20px;
  margin-left: 6px;
}

.empty-state.large {
  padding: 48px 24px; text-align: center;
}
.empty-state.large .empty-icon {
  width: 64px; height: 64px; border-radius: 16px;
  margin: 0 auto 14px; font-size: 24px;
}
.empty-state.large h4 {
  font-size: 16px; font-weight: 700; color: var(--ink);
  margin: 0 0 6px;
}
.empty-state.large p {
  font-size: 13px; color: var(--muted);
  margin: 0; max-width: 280px; margin-left: auto; margin-right: auto;
}
.empty-actions {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 10px;
  margin-top: 22px;
}

/* =========================================================
   Hosting details mockup helpers
   ========================================================= */

.page-back-link {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--muted); font-size: 14px; font-weight: 500;
  margin-bottom: 18px;
}
.page-back-link:hover { color: var(--accent); }

.two-col-dashboard {
  display: grid; grid-template-columns: 1fr 320px; gap: 22px;
}
@media (max-width: 900px) {
  .two-col-dashboard { grid-template-columns: 1fr; }
}
.main-col { display: flex; flex-direction: column; gap: 22px; }
.side-col { display: flex; flex-direction: column; gap: 22px; }

.metric-grid {
  display: grid; gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}
.metric-grid.four {
  grid-template-columns: repeat(4, 1fr);
}
@media (max-width: 700px) {
  .metric-grid.four { grid-template-columns: repeat(2, 1fr); }
}
.metric .metric-label {
  font-size: 12px; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.4px; color: var(--muted); margin: 0 0 6px;
}
.metric .metric-value {
  font-size: 15px; font-weight: 600; color: var(--ink); margin: 0;
}
.metric .metric-value .tag { font-size: 12px; }

.server-location-box {
  display: flex; gap: 18px; align-items: center;
  padding: 18px; border-radius: var(--radius);
  background: linear-gradient(135deg, #EFF6FF, #EEF2FF);
  border: 1px solid #DBEAFE;
}
.flag-large { font-size: 48px; line-height: 1; }
.server-location-meta { flex: 1; }
.server-name { font-family: 'Sora', sans-serif; font-size: 18px; font-weight: 700; color: var(--ink); margin: 0; }
.server-location { font-size: 13px; color: var(--muted); margin: 4px 0 10px; }
.server-detail {
  font-size: 13px; color: var(--muted); margin: 0;
  display: flex; align-items: center; gap: 6px;
}
.server-detail.mono { font-family: 'SFMono-Regular', Consolas, monospace; }
.server-detail i { color: var(--muted); }

.help-note {
  display: flex; gap: 10px; align-items: flex-start;
  font-size: 12px; color: var(--muted);
  background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 12px 14px;
}
.help-note.info {
  background: #EFF6FF; border-color: #DBEAFE; color: #1E40AF;
}
.help-note.info i { color: #3B82F6; }
.help-note p { margin: 0; }
.help-note i { margin-top: 1px; flex-shrink: 0; }

/* form-stack read-only helpers */
.form-stack.compact { gap: 16px; }
.form-group.read-only .form-label {
  font-size: 12px; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.4px; color: var(--muted); margin: 0 0 6px; display: block;
}
.form-group.read-only .form-value {
  font-size: 15px; font-weight: 600; color: var(--ink);
}

.copyable-row {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.mono-chip {
  font-family: 'SFMono-Regular', Consolas, monospace;
  background: var(--bg); border: 1px solid var(--line);
  border-radius: 8px; padding: 8px 12px; font-size: 13px; font-weight: 600;
}
.btn-icon {
  width: 34px; height: 34px; border-radius: 8px;
  display: inline-grid; place-items: center;
  border: 1px solid var(--line); background: var(--card);
  color: var(--muted); cursor: pointer; transition: 0.15s ease;
}
.btn-icon:hover { color: var(--accent); background: var(--accent-soft); border-color: var(--accent); }

.preview-domain-section { margin-bottom: 20px; }
.preview-domain-row {
  padding: 12px 14px; background: var(--bg); border: 1px solid var(--line);
  border-radius: 10px; margin-bottom: 10px;
}
.mono-link {
  font-family: 'SFMono-Regular', Consolas, monospace;
  font-size: 14px; font-weight: 600; color: var(--accent);
  text-decoration: none;
}
.mono-link:hover { text-decoration: underline; }

.screenshot-section { border-top: 1px solid var(--line); padding-top: 20px; }
.section-subheader {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 10px; margin-bottom: 12px;
}
.screenshot-frame {
  position: relative; overflow: hidden; border-radius: var(--radius);
  background: var(--bg); aspect-ratio: 16 / 9; border: 1px solid var(--line);
}
.screenshot-frame img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.screenshot-placeholder {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; min-height: 150px; background: var(--bg);
  border: 1px dashed var(--line); border-radius: var(--radius);
  color: var(--muted);
}
.screenshot-placeholder i { font-size: 28px; margin-bottom: 10px; opacity: 0.5; }
.screenshot-placeholder p { font-size: 13px; margin: 0; }
.screenshot-placeholder small { font-size: 12px; opacity: 0.8; margin-top: 4px; }

.usage-row { margin-bottom: 18px; }
.usage-row:last-child { margin-bottom: 0; }
.usage-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 8px;
}
.usage-label {
  font-size: 13px; font-weight: 600; color: var(--muted);
  display: inline-flex; align-items: center; gap: 8px;
}
.usage-label i { font-size: 14px; color: var(--muted); }
.usage-value {
  font-size: 13px; font-weight: 600; color: var(--ink);
}
.progress-bar {
  width: 100%; height: 8px; background: var(--bg); border-radius: 4px;
  overflow: hidden;
}
.progress-fill { height: 100%; border-radius: 4px; transition: width 0.3s ease; }
.progress-fill.success { background: var(--success); }
.progress-fill.warning { background: var(--warning); }
.progress-fill.danger { background: var(--danger); }

.resource-mini-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 14px;
  padding-top: 18px; border-top: 1px solid var(--line);
}
.resource-mini-grid > .resource-mini:nth-child(3):last-child,
.resource-mini-grid.three-col,
.resource-mini-grid:has(> :nth-child(3):last-child) {
  grid-template-columns: 1fr 1fr 1fr;
}
.resource-mini {
  text-align: center; background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px 12px;
}
.resource-mini-icon {
  width: 38px; height: 38px; margin: 0 auto 10px;
  background: var(--accent-soft); border-radius: 10px;
  display: grid; place-items: center; color: var(--accent); font-size: 16px;
}
.resource-mini-value {
  font-family: 'Sora', sans-serif; font-size: 26px; font-weight: 700; color: var(--ink); margin: 0;
}
.resource-mini-label {
  font-size: 13px; color: var(--muted); margin: 4px 0 0;
}
.resource-mini-label small { color: var(--muted); font-weight: 500; }

/* Bandwidth chart (Phase 1 enhancement, 2026-07-20) */
.bandwidth-chart-wrap {
  padding-top: 18px; border-top: 1px solid var(--line);
}
.bandwidth-chart-header {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: 8px; gap: 12px; flex-wrap: wrap;
}
.bandwidth-chart-header .form-label { margin: 0; }
.bandwidth-chart-stats {
  display: flex; gap: 14px; font-size: 12px; color: var(--muted);
}
.bandwidth-chart-stats strong { color: var(--ink); font-weight: 600; }
.bandwidth-chart {
  width: 100%; height: 140px; display: block;
  color: var(--muted);
  background: var(--bg);
  border-radius: 10px;
  border: 1px solid var(--line);
}
.bandwidth-chart-foot { margin: 0; }

/* Domains & SSL list (Phase 1 enhancement, 2026-07-20) */
.domain-list {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-direction: column;
}
.domain-row {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 16px; padding: 14px 0;
  border-top: 1px solid var(--line);
}
.domain-row:first-child { border-top: none; padding-top: 0; }
.domain-row:last-child { padding-bottom: 0; }
.domain-row-name {
  display: flex; align-items: center; gap: 8px;
  font-family: 'SFMono-Regular', Consolas, monospace; font-size: 13px;
  color: var(--ink);
}
.domain-row-root { margin: 4px 0 0; }
.domain-row-ssl {
  display: flex; align-items: center; gap: 8px; flex-shrink: 0;
  flex-wrap: wrap; justify-content: flex-end;
}

/* Apps list (Phase 1 enhancement, 2026-07-20) */
.app-list {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-direction: column; gap: 12px;
}
.app-row {
  display: flex; align-items: center; gap: 14px;
  padding: 14px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.app-row-icon {
  width: 38px; height: 38px; flex-shrink: 0;
  background: var(--accent-soft); border-radius: 10px;
  display: grid; place-items: center; color: var(--accent); font-size: 16px;
}
.app-row-main { flex: 1; min-width: 0; }
.app-row-name {
  margin: 0; font-weight: 600; color: var(--ink); font-size: 14px;
}
.app-row-version {
  color: var(--muted); font-weight: 500; font-size: 12px;
}
.app-row-path { margin: 2px 0 0; }

/* DB list (Phase 1 enhancement, 2026-07-20) */
.db-list { padding-top: 18px; border-top: 1px solid var(--line); }
.db-list .form-label { margin: 0 0 8px; }
.db-list .kv-list {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px 14px;
}

.kv-list { display: flex; flex-direction: column; gap: 10px; }
.kv-row {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 13px; color: var(--ink);
}
.kv-row span:first-child { color: var(--muted); }
.kv-row .mono { font-family: 'SFMono-Regular', Consolas, monospace; font-size: 12px; }

.info-card .card-title { color: #1E3A8A; }
.info-card .card-header { background: #EFF6FF; border-bottom-color: #DBEAFE; }
.info-card .card-body { background: #F8FAFC; }

.btn.w-full { display: flex; justify-content: center; }


.response-list { display: flex; flex-direction: column; }
.response-category {
  background: var(--bg); padding: 10px 22px;
  border-top: 1px solid var(--line);
}
.response-category span {
  font-size: 11px; font-weight: 700;
  color: var(--muted); text-transform: uppercase; letter-spacing: 0.8px;
}
.response-item {
  display: flex; gap: 16px; padding: 18px 22px;
  border-top: 1px solid var(--line);
  align-items: flex-start;
  transition: background 0.15s ease;
}
.response-item:hover { background: var(--bg); }
.response-item.inactive { opacity: 0.6; }
.response-main { flex: 1; min-width: 0; }
.response-head {
  display: flex; align-items: center; gap: 10px;
  flex-wrap: wrap; margin-bottom: 6px;
}
.response-head h4 {
  font-size: 14px; font-weight: 600; color: var(--ink);
  margin: 0;
}
.shortcut-chip {
  font-family: 'Sora', monospace;
  font-size: 11px; font-weight: 600;
  background: #FFFBEB; color: #92400E;
  padding: 2px 8px; border-radius: 6px;
}
.response-preview {
  font-size: 13px; color: var(--muted);
  margin: 0 0 10px; line-height: 1.5;
  white-space: pre-wrap; word-wrap: break-word;
  display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden;
}
.response-meta {
  display: flex; gap: 14px; flex-wrap: wrap;
  font-size: 11px; color: var(--muted);
}
.response-meta i { margin-right: 4px; }
.response-actions {
  display: flex; gap: 6px; align-items: center; flex-shrink: 0;
}
.response-actions form { display: inline; }
.response-actions .action-icon { width: 30px; height: 30px; }

.inline { display: inline; }

/* =========================================================
   Knowledge Base page mockup (Phase: admin/knowledgebase.php)
   ========================================================= */

.card.narrow { max-width: 720px; }
.text-right { text-align: right; }
.font-mono { font-family: 'JetBrains Mono', 'SFMono-Regular', Menlo, Consolas, monospace; font-size: 13px; line-height: 1.55; }

.kb-editor-grid {
  display: grid; grid-template-columns: 1fr 320px;
  gap: 24px; align-items: start;
}
@media (max-width: 1100px) { .kb-editor-grid { grid-template-columns: 1fr; } }

.checkbox-bottom { display: flex; align-items: flex-end; padding-bottom: 11px; }

.seo-block {
  border-top: 1px solid var(--line); padding-top: 18px; margin-top: 4px;
  display: flex; flex-direction: column; gap: 14px;
}

.kb-filter-bar {
  display: flex; flex-wrap: wrap; gap: 14px;
  align-items: center; justify-content: space-between;
  padding: 16px 22px; border-bottom: 1px solid var(--line);
}
.kb-filter-bar .ticket-filters { flex: 1; min-width: 0; }
.filter-spacer { flex: 1; }

/* Articles table */
.kb-article-cell { display: flex; align-items: flex-start; gap: 10px; }
.kb-article-cell > i { margin-top: 4px; }
.kb-article-title {
  font-size: 14px; font-weight: 600; color: var(--ink);
  margin: 0; line-height: 1.35;
}
.kb-article-slug {
  font-size: 11px; color: var(--muted);
  font-family: 'Sora', monospace; margin: 3px 0 0;
}

/* Category chips (in articles table) */
.kb-cat-chip {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; font-weight: 600;
  padding: 4px 9px; border-radius: 14px;
  background: var(--bg); color: var(--muted);
}
.kb-cat-chip i { font-size: 11px; }
.kb-cat-chip.brand { background: var(--accent-soft); color: var(--accent); }
.kb-cat-chip.blue { background: #EFF6FF; color: var(--info); }
.kb-cat-chip.purple { background: #F5F3FF; color: #8B5CF6; }
.kb-cat-chip.emerald { background: #ECFDF5; color: var(--success); }
.kb-cat-chip.amber { background: #FEF3C7; color: #92400E; }
.kb-cat-chip.red { background: #FEF2F2; color: var(--danger); }
.kb-cat-chip.default { background: #F2F5F9; color: var(--muted); }

/* Categories table */
.kb-cat-cell { display: flex; align-items: center; gap: 12px; }
.kb-cat-icon {
  width: 40px; height: 40px; border-radius: 10px;
  display: grid; place-items: center; flex-shrink: 0;
  background: var(--bg); color: var(--muted);
}
.kb-cat-icon.brand { background: var(--accent-soft); color: var(--accent); }
.kb-cat-icon.blue { background: #EFF6FF; color: var(--info); }
.kb-cat-icon.purple { background: #F5F3FF; color: #8B5CF6; }
.kb-cat-icon.emerald { background: #ECFDF5; color: var(--success); }
.kb-cat-icon.amber { background: #FEF3C7; color: #92400E; }
.kb-cat-icon.red { background: #FEF2F2; color: var(--danger); }
.kb-cat-name { font-size: 14px; font-weight: 600; color: var(--ink); margin: 0; }
.kb-cat-desc {
  font-size: 12px; color: var(--muted); margin: 3px 0 0;
  max-width: 360px;
}

.empty-cta {
  display: inline-block; margin-top: 10px;
  font-size: 13px; font-weight: 600; color: var(--accent);
}
.empty-cta:hover { text-decoration: underline; }

/* =========================================================
   API Logs page mockup (Phase: admin/api-logs.php)
   ========================================================= */

.clear-logs-card { padding: 18px 22px; }
.clear-logs-row {
  display: flex; flex-wrap: wrap;
  align-items: center; justify-content: space-between;
  gap: 16px;
}
.clear-logs-title {
  font-size: 15px; font-weight: 700; color: var(--ink);
  margin: 0 0 4px;
}
.clear-logs-sub {
  font-size: 12px; color: var(--muted); margin: 0;
}
.clear-logs-actions {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
}

.mono-time {
  font-family: 'Sora', monospace;
  font-size: 12px; color: var(--muted);
  white-space: nowrap;
}

.action-code {
  font-family: 'Sora', monospace;
  font-size: 11px; font-weight: 500;
  background: var(--bg); color: var(--ink);
  padding: 3px 8px; border-radius: 6px;
  border: 1px solid var(--line);
  white-space: nowrap;
}

.status-pill {
  display: inline-flex; align-items: center;
  font-family: 'Sora', monospace;
  font-size: 11px; font-weight: 700;
  padding: 4px 9px; border-radius: 14px;
}
.status-pill.status-success {
  background: #ECFDF5; color: #065F46;
}
.status-pill.status-error {
  background: #FEF2F2; color: #991B1B;
}

.error-text {
  font-size: 12px; color: var(--danger);
  font-family: 'Sora', monospace;
  display: inline-block; max-width: 360px;
}

.details-link {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 12px; font-weight: 600;
  color: var(--accent); background: transparent;
  border: none; cursor: pointer;
  padding: 4px 8px; border-radius: 6px;
  transition: 0.18s ease;
}
.details-link:hover {
  background: var(--accent-soft); color: var(--accent);
}

/* Modal */
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(11, 14, 20, 0.55);
  backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  z-index: 1000; padding: 16px;
}
.modal-card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: 18px; width: 100%; max-width: 800px;
  max-height: 80vh; display: flex; flex-direction: column;
  box-shadow: 0 24px 60px rgba(11, 18, 32, 0.18);
  overflow: hidden;
}
.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 22px; border-bottom: 1px solid var(--line);
}
.modal-title {
  font-size: 16px; font-weight: 700; color: var(--ink); margin: 0;
}
.modal-close {
  width: 34px; height: 34px; border-radius: 8px;
  background: transparent; border: none;
  color: var(--muted); cursor: pointer;
  display: grid; place-items: center;
  transition: 0.18s ease;
}
.modal-close:hover { background: var(--bg); color: var(--ink); }
.modal-body {
  padding: 22px; overflow: auto;
}
.modal-section-title {
  font-size: 13px; font-weight: 700; color: var(--ink);
  margin: 0 0 8px;
}
.modal-section-title:not(:first-child) { margin-top: 14px; }
.modal-pre {
  background: var(--bg); border: 1px solid var(--line);
  border-radius: 10px; padding: 14px;
  font-family: 'Sora', monospace;
  font-size: 12px; line-height: 1.55;
  color: var(--ink);
  white-space: pre-wrap; word-wrap: break-word;
  overflow: auto; max-height: 50vh;
  margin: 0;
}

/* =========================================================
   Security Dashboard page mockup (Phase: admin/security-dashboard.php)
   ========================================================= */

.page-actions {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 18px; flex-wrap: wrap; gap: 12px;
}
.page-context {
  font-size: 13px; color: var(--muted);
  margin: 0; padding-left: 4px;
}

.stat-sub {
  font-size: 13px; font-weight: 500; color: var(--muted);
  font-family: inherit; margin-left: 4px;
}

.text-center { text-align: center; }
.text-truncate {
  max-width: 280px; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis;
}

.scrollable { max-height: 380px; overflow-y: auto; }

.card-list { display: flex; flex-direction: column; }
.list-row {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 14px 18px;
  border-top: 1px solid var(--line);
  transition: background 0.15s ease;
}
.list-row:first-child { border-top: none; }
.list-row:hover { background: var(--bg); }
.list-row form { flex-shrink: 0; }
.list-title {
  font-size: 13px; font-weight: 600; color: var(--ink);
  margin: 0 0 4px;
}
.list-meta {
  font-size: 11px; color: var(--muted);
  margin: 2px 0 0; line-height: 1.4;
}

.empty-state.small {
  text-align: center; color: var(--muted);
  font-size: 13px; padding: 28px 18px;
}

/* =========================================================
   Upgrade page mockup (Phase: upgrade.php)
   ========================================================= */

.current-plan-card { border-left: 4px solid var(--accent); }
.current-plan-row {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 16px;
}
.current-plan-name {
  display: flex; align-items: center; gap: 12px;
  margin-top: 4px; flex-wrap: wrap;
}
.current-plan-price {
  font-family: 'Sora', sans-serif;
  font-size: 28px; font-weight: 700; color: var(--ink);
}
.current-plan-price.free { color: var(--success); }
.current-plan-price small {
  font-size: 14px; font-weight: 500; color: var(--muted);
  margin-left: 2px;
}
.current-plan-status {
  font-size: 16px; font-weight: 600; color: var(--success);
  margin: 4px 0 0;
}

.upgrade-form { display: flex; flex-direction: column; gap: 22px; }

.plans-grid {
  display: grid; gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}
@media (min-width: 1100px) {
  .plans-grid { grid-template-columns: repeat(<?php echo min(count($availablePlans ?? []), 2); ?>, 1fr); }
}

.plan-card {
  position: relative;
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px 22px;
  display: flex; flex-direction: column; gap: 16px;
  box-shadow: var(--shadow); transition: 0.18s ease;
}
.plan-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.plan-card-featured {
  border-color: var(--accent);
  box-shadow: 0 14px 34px rgba(255, 106, 0, 0.12);
}
.plan-card-current { opacity: 0.7; }

.plan-badge {
  position: absolute; top: -10px; right: 16px;
  background: var(--accent); color: #fff;
  font-size: 11px; font-weight: 700; letter-spacing: 0.5px;
  padding: 4px 10px; border-radius: 20px;
  box-shadow: 0 6px 18px rgba(255, 106, 0, 0.30);
  display: inline-flex; align-items: center; gap: 4px;
}
.plan-badge.muted { background: var(--muted); box-shadow: none; }

.plan-card-head { text-align: center; margin-top: 4px; }
.plan-name {
  font-family: 'Sora', sans-serif;
  font-size: 22px; font-weight: 700; color: var(--ink);
  margin: 0;
}
.plan-desc {
  font-size: 13px; color: var(--muted);
  margin: 6px 0 0;
}
.plan-price-block {
  text-align: center;
  display: flex; align-items: baseline; justify-content: center;
  gap: 4px;
}
.plan-price {
  font-family: 'Sora', sans-serif;
  font-size: 40px; font-weight: 700; color: var(--accent);
}
.plan-card-featured .plan-price { color: var(--accent); }
.plan-period {
  font-size: 14px; font-weight: 500; color: var(--muted);
}
.plan-yearly-hint {
  text-align: center; font-size: 12px; font-weight: 600;
  color: var(--success);
  margin: -6px 0 0;
  display: flex; align-items: center; justify-content: center; gap: 5px;
}
.plan-features { display: flex; flex-direction: column; gap: 12px; }
.plan-feature {
  display: flex; gap: 10px; align-items: flex-start;
}
.plan-feature > i {
  color: var(--success); font-size: 14px; flex-shrink: 0;
  width: 18px; height: 18px;
  display: grid; place-items: center;
  background: #ECFDF5; border-radius: 50%;
  margin-top: 2px;
}
.plan-feature-title {
  font-size: 14px; font-weight: 600; color: var(--ink);
  margin: 0; line-height: 1.3;
}
.plan-feature-sub {
  font-size: 12px; color: var(--muted); margin: 2px 0 0;
}

.plan-radio-label { display: block; cursor: pointer; }
.plan-radio {
  position: absolute; opacity: 0; pointer-events: none;
}
.plan-cta {
  display: flex; align-items: center; justify-content: center;
  padding: 13px 18px; border-radius: 10px;
  font-size: 14px; font-weight: 600;
  background: var(--bg); color: var(--ink);
  border: 1px solid var(--line);
  transition: 0.18s ease;
  width: 100%;
}
.plan-radio:checked + .plan-cta {
  background: var(--accent); color: #fff;
  border-color: var(--accent);
  box-shadow: 0 6px 18px rgba(255, 106, 0, 0.28);
}
.plan-cta.featured { background: var(--accent); color: #fff; border-color: var(--accent); }
.plan-cta.current { background: var(--bg); color: var(--muted); cursor: not-allowed; }
.plan-radio-label:hover .plan-cta:not(.current):not(.featured) { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.plan-radio-label:hover .plan-cta.featured { background: #E85F00; border-color: #E85F00; color: #fff; }
.plan-radio:checked + .plan-cta.featured { background: var(--accent); }

/* btn-text: small accent link button for inline actions like "Capture New" / "Sync Usage".
   Was previously undefined, leaving buttons to render as browser-default <button>
   (grey system look) which clashed with the mockup. */
.btn-text {
  display: inline-flex; align-items: center; gap: 6px;
  background: transparent; border: none; padding: 6px 8px;
  font-family: inherit; font-size: 13px; font-weight: 600;
  color: var(--accent); cursor: pointer; border-radius: 8px;
  transition: 0.18s ease;
}
.btn-text:hover { background: var(--accent-soft); }
.btn-text:disabled { color: var(--muted); cursor: not-allowed; }

.billing-card { max-width: 720px; margin: 0 auto; }
.billing-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 14px;
}
@media (max-width: 700px) { .billing-grid { grid-template-columns: 1fr; } }
.billing-option {
  position: relative;
  display: flex; align-items: center; gap: 12px;
  padding: 16px 18px; border-radius: 12px;
  background: var(--bg); border: 2px solid var(--line);
  cursor: pointer; transition: 0.18s ease;
}
.billing-option:hover { border-color: var(--accent); }
.billing-option.recommended {
  background: #ECFDF5; border-color: rgba(16, 185, 129, 0.30);
}
.billing-option input { accent-color: var(--accent); width: 18px; height: 18px; }
.billing-option-content { flex: 1; }
.billing-option-title {
  font-size: 14px; font-weight: 700; color: var(--ink);
  margin: 0;
  display: flex; align-items: center; gap: 8px;
}
.billing-option-sub {
  font-size: 12px; color: var(--muted); margin: 2px 0 0;
}
.discount-tag {
  background: var(--success); color: #fff;
  font-size: 10px; font-weight: 700;
  padding: 2px 7px; border-radius: 10px;
}
.billing-checkmark {
  color: var(--success);
  position: absolute; top: 12px; right: 14px;
}

.upgrade-submit {
  text-align: center; padding-top: 8px;
}
.btn-upgrade {
  padding: 16px 40px; font-size: 16px;
  min-width: 220px;
}
.upgrade-guarantees {
  font-size: 13px; color: var(--muted);
  margin: 14px 0 0;
  display: inline-flex; align-items: center; gap: 6px;
}

.compare-card { max-width: 920px; margin: 32px auto 0; }
.compare-card .card-header {
  flex-direction: column; align-items: flex-start; gap: 4px;
}
.compare-featured { color: var(--accent); font-weight: 700; }
.compare-card th small { font-weight: 500; color: var(--muted); display: block; }
.compare-card td.muted { color: var(--muted); font-weight: 500; }
.compare-card .check-yes { color: var(--success); font-size: 16px; }


.quick-link.compact {
  padding: 0; font-size: 13px; font-weight: 500;
}
.quick-link.compact:hover { background: transparent; }

.settings-link {
  display: flex; align-items: center; gap: 16px;
  flex-wrap: wrap;
}
.settings-link-icon {
  width: 48px; height: 48px; border-radius: 12px;
  background: rgba(30, 64, 175, 0.10); color: #1E40AF;
  display: grid; place-items: center; flex-shrink: 0;
}
.settings-link-text { flex: 1; min-width: 200px; }
.settings-link-text h4 {
  font-size: 16px; font-weight: 700; color: var(--ink);
  margin: 0 0 4px;
}
.settings-link-text p {
  font-size: 13px; color: var(--muted);
  margin: 0;
}

/* =========================================================
   IP Blocking page mockup (Phase: admin/ip-blocking.php)
   ========================================================= */

.card-tabs { margin: 0; border: none; padding: 8px; box-shadow: none; background: transparent; }
.tab-content { padding: 18px 22px; }

.sub-card { padding: 0; }
.sub-card.wide { flex: 1; }
.sub-card .card-header {
  padding: 18px 22px 14px;
  margin: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
}
/* Stack title above subtitle only when a subtitle is present. Title + tag combos stay inline. */
.sub-card .card-header:has(.text-subtitle) {
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}
.sub-card .card-header:has(.text-subtitle) .card-title { width: 100%; }
.sub-card .card-body { padding: 18px 22px 22px; }

.ip-tab-grid {
  display: grid;
  grid-template-columns: minmax(280px, 360px) 1fr;
  gap: 18px;
  align-items: start;
}
.ip-tab-grid.two-col-balanced { grid-template-columns: 1fr 1fr; }
@media (max-width: 900px) {
  .ip-tab-grid,
  .ip-tab-grid.two-col-balanced { grid-template-columns: 1fr; }
}

.ip-list { display: flex; flex-direction: column; gap: 8px; padding: 4px 0; }
.ip-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 12px 14px;
  border-radius: 10px; border: 1px solid var(--line);
  background: var(--card);
  transition: 0.15s ease;
}
.ip-row:hover { border-color: #D8DEE7; }
.ip-row.danger {
  background: #FEF2F2; border-color: rgba(239, 68, 68, 0.20);
}
.ip-row.danger .ip-row-main i { color: var(--danger); }
.ip-row.success {
  background: #ECFDF5; border-color: rgba(16, 185, 129, 0.20);
}
.ip-row.success .ip-row-main i { color: var(--success); }
.ip-row-main {
  display: flex; align-items: center; gap: 12px; min-width: 0;
}
.ip-row-main i { font-size: 14px; }
.ip-row form { flex-shrink: 0; }








/* =========================================================
   My Websites page (my-websites.php)
   ========================================================= */

.stats-row-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) { .stats-row-4 { grid-template-columns: repeat(2, 1fr); } }

.sites-filter {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; margin-bottom: 16px;
}
.filter-tabs {
  display: flex; align-items: center; gap: 6px;
  flex-wrap: wrap;
}
.filter-tab {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: 10px;
  background: var(--bg); border: 1px solid var(--line);
  color: var(--muted); font-size: 13px; font-weight: 600;
  text-decoration: none; transition: 0.18s ease;
}
.filter-tab:hover { background: #fff; border-color: #D8DEE7; color: var(--ink); }
.filter-tab.active {
  background: var(--accent); border-color: var(--accent); color: #fff;
  box-shadow: 0 6px 18px rgba(255, 106, 0, 0.28);
}
.filter-tab-count {
  font-size: 11px; font-weight: 700;
  padding: 2px 8px; border-radius: 10px;
  background: rgba(11, 18, 32, 0.08); color: inherit;
}
.filter-tab.active .filter-tab-count {
  background: rgba(255, 255, 255, 0.20);
}

.sites-search {
  display: flex; align-items: center; gap: 8px;
  background: var(--bg); border: 1px solid var(--line);
  border-radius: 10px; padding: 6px 8px 6px 12px;
  flex: 1; max-width: 360px; min-width: 220px;
}
.sites-search svg { width: 16px; height: 16px; color: var(--muted); flex-shrink: 0; }
.sites-search input[type=search] {
  border: none; background: transparent; outline: none;
  font-family: inherit; font-size: 13px; color: var(--ink); flex: 1;
  min-width: 0; padding: 6px 0;
}
.sites-search input[type=search]::placeholder { color: #9CA4B2; }

.table-usage {
  display: flex; flex-direction: column; gap: 6px; min-width: 120px;
}
.table-usage-value {
  font-size: 13px; font-weight: 600; color: var(--ink);
}
.table-usage-limit {
  font-size: 11px; color: var(--muted); font-weight: 500;
}

.bandwidth-cell {
  display: flex; flex-direction: column; gap: 6px; min-width: 130px;
}
.bandwidth-text {
  font-size: 13px; font-weight: 600; color: var(--ink);
}

.tag.danger { color: var(--danger); background: #FEF2F2; }
.tag.muted { color: var(--muted); background: #F2F5F9; }

.status-dot.red {
  background: var(--danger);
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.14);
}
.status-dot.orange {
  background: var(--warning);
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.14);
}
.status-dot.gray {
  background: #9CA4B2;
  box-shadow: 0 0 0 3px rgba(156, 164, 178, 0.14);
}

/* =========================================================
   Support page (support.php)
   ========================================================= */

.quick-help-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 18px; margin-bottom: 22px;
}
@media (max-width: 900px) { .quick-help-grid { grid-template-columns: 1fr; } }

.quick-help-card {
  display: flex; flex-direction: column; align-items: center;
  text-align: center; gap: 10px;
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 22px; text-decoration: none; color: inherit;
  box-shadow: var(--shadow);
  transition: 0.18s ease;
}
.quick-help-card:hover {
  transform: translateY(-2px); box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}
.quick-help-card-disabled {
  opacity: 0.65; cursor: not-allowed;
}
.quick-help-card-disabled:hover {
  transform: none; box-shadow: var(--shadow); border-color: var(--line);
}
.quick-help-card h4 {
  font-family: 'Sora', sans-serif; font-size: 18px; font-weight: 700;
  color: var(--ink); margin: 0;
}
.quick-help-card p {
  font-size: 13px; color: var(--muted); margin: 0;
}
.quick-help-icon {
  width: 44px; height: 44px; border-radius: 12px;
  background: var(--accent-soft); color: var(--accent);
  display: grid; place-items: center;
}
.quick-help-icon svg { width: 22px; height: 22px; }
.quick-help-icon-blue { background: #EFF6FF; color: var(--info); }
.quick-help-icon-purple { background: #F5F3FF; color: #8B5CF6; }
.quick-help-cta {
  margin-top: 4px;
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 600; color: var(--accent);
}
.quick-help-cta svg { width: 14px; height: 14px; }
.quick-help-card:hover .quick-help-cta svg { transform: translateX(2px); }
.quick-help-cta svg { transition: 0.18s ease; }

.ticket-list { display: flex; flex-direction: column; gap: 10px; }
.ticket-row {
  display: flex; flex-direction: column; gap: 8px;
  padding: 14px; border: 1px solid var(--line);
  border-radius: 12px; background: var(--bg);
  transition: 0.18s ease; position: relative;
}
.ticket-row:hover {
  border-color: var(--accent); background: #fff;
}
.ticket-row-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 10px;
}
.ticket-row-title {
  font-size: 13px; font-weight: 600; color: var(--ink);
  line-height: 1.4;
  word-break: break-word;
  flex: 1; min-width: 0;
}
.ticket-row-head .tag { flex-shrink: 0; }
.ticket-row-meta {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; flex-wrap: wrap;
  font-size: 12px; color: var(--muted);
}
.ticket-row-meta > span { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ticket-row-priority {
  margin-left: 4px;
}
.ticket-row-cta {
  display: inline-flex; align-items: center; gap: 6px;
  align-self: flex-start;
  font-size: 12px; font-weight: 600; color: var(--accent);
  text-decoration: none;
  margin-top: 2px;
}
.ticket-row-cta i { font-size: 11px; transition: 0.18s ease; }
.ticket-row-cta:hover i { transform: translateX(2px); }

.tag.tag-info { color: #1E40AF; background: #DBEAFE; }
.tag.tag-warn { color: #92400E; background: #FEF3C7; }
.tag.tag-muted { color: var(--muted); background: #F2F5F9; }
.tag.tag-success { color: #065F46; background: #ECFDF5; }
.tag.tag-danger { color: var(--danger); background: #FEF2F2; }

/* Knowledge Base category grid (used on support.php) */
.kb-cat-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
@media (max-width: 1100px) { .kb-cat-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 700px) { .kb-cat-grid { grid-template-columns: 1fr; } }

.kb-cat-card {
  display: flex; flex-direction: column; gap: 14px;
  background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px;
  transition: 0.18s ease;
}
.kb-cat-card:hover {
  border-color: var(--accent); background: #fff;
  box-shadow: var(--shadow);
}
.kb-cat-card-head {
  display: flex; align-items: center; gap: 12px;
  text-decoration: none; color: inherit;
}
.kb-cat-card-icon {
  width: 38px; height: 38px; border-radius: 10px;
  background: var(--accent-soft); color: var(--accent);
  display: grid; place-items: center;
  flex-shrink: 0;
}
.kb-cat-card-icon svg, .kb-cat-card-icon i { font-size: 16px; width: 18px; height: 18px; }
.kb-cat-card-meta { flex: 1; min-width: 0; }
.kb-cat-card-title {
  font-size: 14px; font-weight: 700; color: var(--ink);
  margin: 0; line-height: 1.3;
}
.kb-cat-card-meta small {
  font-size: 11px; color: var(--muted); font-weight: 500;
}
.kb-cat-card-list {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-direction: column; gap: 6px;
}
.kb-cat-card-list a {
  display: flex; align-items: center; gap: 8px;
  font-size: 12px; color: var(--muted);
  text-decoration: none; padding: 4px 0;
  transition: 0.18s ease;
}
.kb-cat-card-list a i {
  font-size: 9px; color: #B9C0CC; flex-shrink: 0;
  transition: 0.18s ease;
}
.kb-cat-card-list a:hover { color: var(--accent); }
.kb-cat-card-list a:hover i { color: var(--accent); transform: translateX(2px); }
.kb-cat-card-more {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 12px; font-weight: 600; color: var(--accent);
  text-decoration: none; margin-top: auto;
}
.kb-cat-card-more i { font-size: 10px; transition: 0.18s ease; }
.kb-cat-card-more:hover i { transform: translateX(2px); }
.kb-cat-card-empty {
  font-size: 12px; color: var(--muted); font-style: italic; margin: 0;
}

.contact-row {
  display: flex; flex-wrap: wrap; gap: 14px;
  margin-top: 6px;
}
.contact-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; min-width: 220px; flex: 1;
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); text-decoration: none; color: inherit;
  transition: 0.18s ease;
}
a.contact-item:hover {
  border-color: var(--accent); transform: translateY(-1px);
  box-shadow: var(--shadow);
}
.contact-icon {
  width: 38px; height: 38px; border-radius: 10px;
  background: var(--accent-soft); color: var(--accent);
  display: grid; place-items: center; flex-shrink: 0;
}
.contact-icon i { font-size: 16px; }
.contact-icon-purple { background: #F5F3FF; color: #8B5CF6; }
.contact-icon-success { background: #ECFDF5; color: var(--success); }
.contact-meta { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.contact-meta small {
  font-size: 10px; text-transform: uppercase; letter-spacing: 0.5px;
  color: var(--muted); font-weight: 600;
}
.contact-meta span {
  font-size: 13px; font-weight: 600; color: var(--ink);
  word-break: break-word;
}

/* =========================================================
   Domains + Databases pages
   ========================================================= */

.muted { color: var(--muted); }

.alert-content { flex: 1; min-width: 0; }
.alert-content p { margin: 0; }

.domain-expiry {
  display: flex; align-items: center; gap: 6px;
  font-size: 12px;
}

.btn.btn-sm { padding: 6px 12px; font-size: 12px; }
.actions .btn { margin-left: 4px; }

/* DNS management page styles (dns.php) */
.dns-add-form {
  background: var(--surface, #FAFBFC);
  border: 1px solid var(--border, #E5E7EB);
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 16px;
}
.dns-add-form.hidden,
.dns-edit-row.hidden { display: none !important; }
.dns-form-grid {
  display: grid;
  grid-template-columns: 110px 200px 1fr 110px 130px;
  gap: 10px;
  align-items: end;
}
.dns-form-grid .form-group-wide { grid-column: 3 / span 1; }
.dns-form-grid .form-group-actions {
  grid-column: 5 / span 1;
  display: flex;
  gap: 6px;
  justify-content: flex-end;
}
.dns-form-grid .form-label { display: block; font-size: 11px; color: var(--muted, #6B7280); margin-bottom: 4px; font-weight: 500; }
.dns-form-grid .form-input {
  width: 100%;
  padding: 6px 10px;
  border: 1px solid var(--border, #E5E7EB);
  border-radius: 6px;
  background: #fff;
  font-size: 13px;
  color: var(--text, #111827);
  font-family: inherit;
}
.dns-form-grid .form-input.mono { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 12px; }
.dns-edit-row > td {
  background: var(--surface, #FAFBFC);
  padding: 12px 16px !important;
}
.action-icon-danger { color: var(--danger, #DC2626); }
.action-icon-danger:hover { background: rgba(220, 38, 38, 0.08); }

@media (max-width: 768px) {
  .dns-form-grid {
    grid-template-columns: 1fr 1fr;
  }
  .dns-form-grid .form-group-wide,
  .dns-form-grid .form-group-actions { grid-column: 1 / -1; }
}

/* Onboarding tour modal (dashboard.php, 2026-07-20) */
.onboarding-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  backdrop-filter: blur(2px);
  animation: onboarding-fade-in 0.18s ease-out;
}
@keyframes onboarding-fade-in {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}
.onboarding-card {
  background: #fff;
  border-radius: 16px;
  width: 100%;
  max-width: 480px;
  padding: 24px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.20);
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.onboarding-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--muted, #6B7280);
  font-weight: 500;
}
.onboarding-step-counter span:first-child { color: var(--accent, #FF6A00); font-weight: 600; }
.onboarding-close {
  background: none;
  border: 0;
  font-size: 24px;
  line-height: 1;
  color: var(--muted, #6B7280);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
}
.onboarding-close:hover { background: rgba(0, 0, 0, 0.05); color: var(--text, #111827); }
.onboarding-body { min-height: 200px; }
.onboarding-step.hidden { display: none !important; }
.onboarding-step {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}
.onboarding-step h2 {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  color: var(--text, #111827);
  line-height: 1.25;
}
.onboarding-step p {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-secondary, #4B5563);
}
.onboarding-icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.onboarding-icon-welcome {
  background: linear-gradient(135deg, rgba(255, 106, 0, 0.10), rgba(255, 106, 0, 0.20));
  color: var(--accent, #FF6A00);
}
.onboarding-icon-action {
  background: rgba(255, 106, 0, 0.08);
  color: var(--accent, #FF6A00);
}
.onboarding-icon-done {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.10), rgba(16, 185, 129, 0.20));
  color: rgb(16, 185, 129);
}
.onboarding-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
}
.onboarding-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.15);
  cursor: pointer;
  transition: width 0.18s ease, background 0.18s ease;
}
.onboarding-dot.active {
  width: 18px;
  border-radius: 3px;
  background: var(--accent, #FF6A00);
}
.onboarding-actions {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}
.onboarding-actions .btn { min-width: 88px; }
.onboarding-actions .btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* Quick Actions card (hosting-details.php Phase 2, 2026-07-21) */
.quick-actions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}
.quick-action { display: contents; }
.quick-action-btn {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  width: 100%;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  color: inherit;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}
.quick-action-btn:hover {
  border-color: rgba(255, 106, 0, 0.45);
  box-shadow: 0 6px 18px rgba(255, 106, 0, 0.08);
  transform: translateY(-1px);
}
.quick-action-btn i {
  font-size: 22px;
  color: var(--accent);
  line-height: 1;
}
.quick-action-title {
  font-weight: 600;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.3;
}
.quick-action-sub {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}
