:root {
  --fh-page-bg: #f5f5f9;
  --fh-card-bg: #fff;
  --fh-card-border: rgba(67, 89, 113, .12);
  --fh-text: #566a7f;
  --fh-heading: #384551;
  --fh-primary: #696cff;
  --fh-sidebar-bg: #fff;
  --fh-navbar-bg: #fff;
  --fh-radius: 8px;
}

/* Refreshed Classic: a cleaner light dashboard with softer surfaces,
   clearer hierarchy and consistent controls across admin and customer pages. */
html[data-site-template="classic"] {
  --fh-page-bg: #f4f7fb;
  --fh-card-bg: #ffffff;
  --fh-card-border: #e4eaf2;
  --fh-text: #5f6b7a;
  --fh-heading: #202938;
  --fh-primary: #6266e8;
  --fh-sidebar-bg: #ffffff;
  --fh-navbar-bg: rgba(255, 255, 255, .94);
  --fh-radius: 14px;
}

html[data-site-template="classic"] body,
html[data-site-template="classic"] .content-wrapper {
  background:
    radial-gradient(circle at 100% 0, rgba(98, 102, 232, .07), transparent 30rem),
    var(--fh-page-bg) !important;
  color: var(--fh-text);
}

html[data-site-template="classic"] h1,
html[data-site-template="classic"] h2,
html[data-site-template="classic"] h3,
html[data-site-template="classic"] h4,
html[data-site-template="classic"] h5,
html[data-site-template="classic"] h6,
html[data-site-template="classic"] .fw-bold,
html[data-site-template="classic"] .fw-semibold {
  color: var(--fh-heading);
}

html[data-site-template="classic"] .layout-menu,
html[data-site-template="classic"] .bg-menu-theme {
  border-right: 1px solid var(--fh-card-border);
  box-shadow: 8px 0 28px rgba(32, 41, 56, .035);
}

html[data-site-template="classic"] .layout-navbar,
html[data-site-template="classic"] .bg-navbar-theme {
  border: 1px solid rgba(228, 234, 242, .9) !important;
  border-radius: var(--fh-radius) !important;
  box-shadow: 0 8px 24px rgba(32, 41, 56, .065) !important;
  backdrop-filter: blur(12px);
}

html[data-site-template="classic"] #layout-navbar,
html[data-site-template="classic"] #layout-navbar .nav-link,
html[data-site-template="classic"] #layout-navbar .nav-link > i,
html[data-site-template="classic"] #layout-navbar .navbar-nav-right,
html[data-site-template="classic"] #layout-navbar .dropdown-toggle {
  color: #384551 !important;
}

html[data-site-template="classic"] #layout-navbar .nav-link:hover,
html[data-site-template="classic"] #layout-navbar .nav-link:focus {
  color: #5155d8 !important;
}

html[data-site-template="classic"] #layout-navbar .nav-link > .badge:not(.bg-danger):not(.bg-warning):not(.bg-info):not(.bg-primary) {
  background: #eef0ff !important;
  color: #5155d8 !important;
}

html[data-site-template="classic"] #layout-navbar .btn-outline-secondary {
  border-color: #d7deea !important;
  color: #4f5d6d !important;
}

html[data-site-template="classic"] #layout-navbar .btn-outline-secondary:hover {
  background: #f1f3f8 !important;
  border-color: #c5cfdd !important;
  color: #293747 !important;
}

html[data-site-template="classic"] .menu-link {
  border-radius: 10px;
  color: #667386;
}

html[data-site-template="classic"] .menu-item.active > .menu-link {
  background: linear-gradient(135deg, rgba(98, 102, 232, .15), rgba(98, 102, 232, .08)) !important;
  color: #5155d8 !important;
  box-shadow: inset 3px 0 0 var(--fh-primary);
}

html[data-site-template="classic"] .menu-link:hover {
  background: #f3f5ff !important;
  color: #5155d8 !important;
}

html[data-site-template="classic"] .card,
html[data-site-template="classic"] .dropdown-menu,
html[data-site-template="classic"] .modal-content {
  background: var(--fh-card-bg);
  border: 1px solid var(--fh-card-border);
  border-radius: var(--fh-radius);
  box-shadow: 0 8px 26px rgba(32, 41, 56, .065) !important;
}

html[data-site-template="classic"] .card {
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

html[data-site-template="classic"] .card-header,
html[data-site-template="classic"] .card-footer {
  background: transparent;
  border-color: var(--fh-card-border);
}

html[data-site-template="classic"] .form-control,
html[data-site-template="classic"] .form-select,
html[data-site-template="classic"] .input-group-text {
  min-height: 42px;
  background-color: #fbfcfe;
  border-color: #dce3ed;
  border-radius: 10px;
  color: var(--fh-heading);
}

html[data-site-template="classic"] .form-control:focus,
html[data-site-template="classic"] .form-select:focus {
  background-color: #fff;
  border-color: rgba(98, 102, 232, .65);
  box-shadow: 0 0 0 .2rem rgba(98, 102, 232, .12);
}

html[data-site-template="classic"] .btn {
  border-radius: 10px;
  font-weight: 500;
}

html[data-site-template="classic"] .btn-primary {
  background: linear-gradient(135deg, #6d70ed, #565bdc) !important;
  border-color: #5d61e2 !important;
  box-shadow: 0 6px 14px rgba(98, 102, 232, .22);
}

html[data-site-template="classic"] .btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(98, 102, 232, .28);
}

html[data-site-template="classic"] .btn-outline-primary {
  border-color: rgba(98, 102, 232, .48) !important;
  color: #5559d9 !important;
}

html[data-site-template="classic"] .btn-outline-primary:hover {
  background: var(--fh-primary) !important;
  color: #fff !important;
}

html[data-site-template="classic"] .table {
  color: var(--fh-text);
}

html[data-site-template="classic"] .table thead th {
  background: #f7f9fc;
  border-bottom-color: var(--fh-card-border);
  color: #687588;
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .025em;
  text-transform: uppercase;
}

html[data-site-template="classic"] .table > :not(caption) > * > * {
  border-bottom-color: #edf1f6;
}

html[data-site-template="classic"] .table-hover > tbody > tr:hover > * {
  background: #f8f9ff;
}

html[data-site-template="classic"] .dropdown-item {
  margin: 2px 6px;
  width: calc(100% - 12px);
  border-radius: 8px;
}

html[data-site-template="classic"] .dropdown-item:hover,
html[data-site-template="classic"] .dropdown-item:focus {
  background: #f1f3ff;
  color: #5054d5;
}

html[data-site-template="classic"] .dashboard-hero,
html[data-site-template="classic"] .create-vps-hero,
html[data-site-template="classic"] .guide-hero,
html[data-site-template="classic"] .docs-hero {
  background: linear-gradient(135deg, #ffffff 0%, #f2f3ff 100%) !important;
  border: 1px solid #e1e4fa !important;
  box-shadow: 0 12px 30px rgba(75, 79, 180, .08) !important;
}

html[data-site-template="classic"] .badge.bg-label-primary,
html[data-site-template="classic"] .bg-label-primary {
  background: rgba(98, 102, 232, .12) !important;
  color: #5256d5 !important;
}

html[data-site-template="classic"] .pagination .page-link {
  border-radius: 8px !important;
  border-color: transparent;
}

/* Template-aware login page */
html[data-site-template] .authentication-wrapper.authentication-basic {
  min-height: 100vh;
  padding: 1.5rem;
}

html[data-site-template] .authentication-wrapper .authentication-inner {
  width: 100%;
  max-width: 440px;
}

html[data-site-template] .authentication-wrapper .login-card {
  overflow: hidden;
  border: 1px solid var(--fh-card-border) !important;
  border-radius: calc(var(--fh-radius) + 4px) !important;
  background: var(--fh-card-bg) !important;
  color: var(--fh-text) !important;
}

html[data-site-template] .authentication-wrapper .login-card .card-body {
  padding: 2rem;
}

html[data-site-template] .authentication-wrapper .login-logo {
  display: block;
  width: auto !important;
  max-width: min(260px, 100%);
  height: auto;
  max-height: 80px;
  object-fit: contain;
}

html[data-site-template] .authentication-wrapper .app-brand {
  margin-bottom: 1.75rem !important;
}

html[data-site-template] .authentication-wrapper .form-label,
html[data-site-template] .authentication-wrapper h4 {
  color: var(--fh-heading) !important;
}

html[data-site-template] .authentication-wrapper .form-control {
  min-height: 46px;
  padding: .75rem 1rem !important;
  line-height: 1.4;
}

html[data-site-template] .authentication-wrapper .input-group > .form-control:first-child {
  padding-left: 1rem !important;
}

html[data-site-template] .authentication-wrapper .input-group-text {
  padding-left: .9rem;
  padding-right: .9rem;
}

html[data-site-template] .authentication-wrapper .login-error {
  color: #dc3545;
  overflow-wrap: anywhere;
}

html[data-site-template] .authentication-wrapper .input-group-text.btn-primary {
  min-width: 44px;
  justify-content: center;
  border-radius: 0 10px 10px 0;
  box-shadow: none;
}

html[data-site-template="classic"] .authentication-wrapper.authentication-basic {
  background:
    radial-gradient(circle at 15% 15%, rgba(98, 102, 232, .18), transparent 28rem),
    radial-gradient(circle at 90% 85%, rgba(74, 184, 198, .11), transparent 25rem),
    #f4f7fb;
}

html[data-site-template="classic"] .authentication-wrapper .login-card {
  box-shadow: 0 24px 60px rgba(32, 41, 56, .12) !important;
}

html[data-site-template="modern-slate"] .authentication-wrapper.authentication-basic {
  background:
    radial-gradient(circle at 15% 15%, rgba(95, 192, 255, .13), transparent 28rem),
    radial-gradient(circle at 90% 85%, rgba(90, 104, 255, .1), transparent 24rem),
    #101318;
}

html[data-site-template="modern-slate"] .authentication-wrapper .login-card {
  box-shadow: 0 24px 70px rgba(0, 0, 0, .4) !important;
}

html[data-site-template="modern-slate"] .authentication-wrapper a {
  color: #8bd2ff;
}

html[data-site-template] .forgot-password-modal .modal-header,
html[data-site-template] .forgot-password-modal .modal-footer {
  border-color: var(--fh-card-border);
}

html[data-site-template] .forgot-password-modal .modal-title {
  color: var(--fh-heading) !important;
}

html[data-site-template="modern-slate"] .forgot-password-modal .btn-close {
  filter: invert(1) grayscale(100%);
}

@media (max-width: 575.98px) {
  html[data-site-template] .authentication-wrapper.authentication-basic {
    padding: 1rem;
  }
  html[data-site-template] .authentication-wrapper .login-card .card-body {
    padding: 1.4rem;
  }
  html[data-site-template] .authentication-wrapper .authentication-inner::before,
  html[data-site-template] .authentication-wrapper .authentication-inner::after {
    display: none !important;
  }
  html[data-site-template] .forgot-password-modal .modal-footer {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 767.98px) {
  html[data-site-template="classic"] .layout-navbar {
    border-radius: 12px !important;
  }
  html[data-site-template="classic"] .card {
    border-radius: 12px;
  }
  html[data-site-template="classic"] .container-p-y {
    padding-left: .85rem !important;
    padding-right: .85rem !important;
  }
}

html[data-site-template="modern-slate"] {
  --fh-page-bg: #101318;
  --fh-card-bg: #181d25;
  --fh-card-border: #2a3340;
  --fh-text: #c6cfda;
  --fh-heading: #f3f6f9;
  --fh-primary: #5fc0ff;
  --fh-sidebar-bg: #151922;
  --fh-navbar-bg: #181d25;
  --fh-radius: 10px;
}

html[data-site-template="aurora"] {
  --fh-page-bg: #080b1a;
  --fh-card-bg: #11162b;
  --fh-card-border: rgba(143, 132, 255, .2);
  --fh-text: #b8c1da;
  --fh-heading: #f7f8ff;
  --fh-primary: #8b7cff;
  --fh-sidebar-bg: #0d1124;
  --fh-navbar-bg: rgba(17, 22, 43, .9);
  --fh-radius: 16px;
}

html[data-site-template="aurora"] body,
html[data-site-template="aurora"] .content-wrapper {
  background:
    radial-gradient(circle at 8% 8%, rgba(111, 91, 255, .18), transparent 30rem),
    radial-gradient(circle at 92% 18%, rgba(0, 211, 255, .11), transparent 27rem),
    radial-gradient(circle at 70% 100%, rgba(235, 79, 255, .08), transparent 28rem),
    var(--fh-page-bg) !important;
  color: var(--fh-text) !important;
}

html[data-site-template="aurora"] h1,
html[data-site-template="aurora"] h2,
html[data-site-template="aurora"] h3,
html[data-site-template="aurora"] h4,
html[data-site-template="aurora"] h5,
html[data-site-template="aurora"] h6,
html[data-site-template="aurora"] .fw-bold,
html[data-site-template="aurora"] .fw-semibold {
  color: var(--fh-heading) !important;
}

html[data-site-template="aurora"] .layout-menu,
html[data-site-template="aurora"] .bg-menu-theme {
  background: linear-gradient(180deg, #10152a 0%, #0a0e20 100%) !important;
  border-right: 1px solid rgba(139, 124, 255, .18);
  box-shadow: 12px 0 40px rgba(0, 0, 0, .22);
}

html[data-site-template="aurora"] .layout-navbar,
html[data-site-template="aurora"] .bg-navbar-theme {
  background: var(--fh-navbar-bg) !important;
  border: 1px solid var(--fh-card-border) !important;
  border-radius: var(--fh-radius) !important;
  box-shadow: 0 12px 34px rgba(0, 0, 0, .24) !important;
  backdrop-filter: blur(16px);
}

html[data-site-template="aurora"] .card,
html[data-site-template="aurora"] .dropdown-menu,
html[data-site-template="aurora"] .modal-content {
  background: linear-gradient(145deg, rgba(20, 26, 51, .98), rgba(14, 19, 39, .98)) !important;
  border: 1px solid var(--fh-card-border) !important;
  border-radius: var(--fh-radius) !important;
  color: var(--fh-text) !important;
  box-shadow: 0 16px 42px rgba(0, 0, 0, .28) !important;
}

html[data-site-template="aurora"] .card-header,
html[data-site-template="aurora"] .card-footer,
html[data-site-template="aurora"] .modal-header,
html[data-site-template="aurora"] .modal-footer {
  background: transparent !important;
  border-color: var(--fh-card-border) !important;
}

html[data-site-template="aurora"] .menu-link,
html[data-site-template="aurora"] .dropdown-item,
html[data-site-template="aurora"] .nav-link,
html[data-site-template="aurora"] .text-body {
  color: var(--fh-text) !important;
}

html[data-site-template="aurora"] .menu-link {
  border-radius: 11px;
}

html[data-site-template="aurora"] .menu-item.active > .menu-link {
  background: linear-gradient(135deg, rgba(139, 124, 255, .25), rgba(58, 205, 255, .1)) !important;
  color: #fff !important;
  box-shadow: inset 3px 0 0 #9f92ff, 0 6px 18px rgba(89, 67, 220, .12);
}

html[data-site-template="aurora"] .menu-link:hover,
html[data-site-template="aurora"] .dropdown-item:hover,
html[data-site-template="aurora"] .dropdown-item:focus {
  background: rgba(139, 124, 255, .13) !important;
  color: #fff !important;
}

html[data-site-template="aurora"] .text-muted,
html[data-site-template="aurora"] small.text-muted,
html[data-site-template="aurora"] .form-text {
  color: #8994b1 !important;
}

html[data-site-template="aurora"] .form-control,
html[data-site-template="aurora"] .form-select,
html[data-site-template="aurora"] .input-group-text {
  min-height: 42px;
  background: rgba(6, 9, 25, .72) !important;
  border-color: rgba(139, 124, 255, .25) !important;
  border-radius: 11px;
  color: #f4f6ff !important;
  -webkit-text-fill-color: #f4f6ff;
}

html[data-site-template="aurora"] .form-control:focus,
html[data-site-template="aurora"] .form-select:focus {
  border-color: #8b7cff !important;
  box-shadow: 0 0 0 .2rem rgba(139, 124, 255, .16);
}

html[data-site-template="aurora"] .form-control::placeholder {
  color: #69738f !important;
  opacity: 1;
}

html[data-site-template="aurora"] .form-select option,
html[data-site-template="aurora"] .form-select optgroup {
  background: #11162b;
  color: #f4f6ff;
}

html[data-site-template="aurora"] .btn {
  border-radius: 11px;
  font-weight: 500;
}

html[data-site-template="aurora"] .btn-primary {
  background: linear-gradient(135deg, #9a86ff 0%, #6858ea 55%, #477fea 100%) !important;
  border-color: transparent !important;
  color: #fff !important;
  box-shadow: 0 8px 22px rgba(105, 87, 235, .3);
}

html[data-site-template="aurora"] .btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 11px 28px rgba(105, 87, 235, .4);
}

html[data-site-template="aurora"] .btn-outline-primary {
  border-color: #8b7cff !important;
  color: #aa9fff !important;
}

html[data-site-template="aurora"] .btn-outline-primary:hover {
  background: #8b7cff !important;
  color: #fff !important;
}

html[data-site-template="aurora"] .table {
  color: var(--fh-text) !important;
}

html[data-site-template="aurora"] .table > :not(caption) > * > * {
  background: transparent;
  border-bottom-color: rgba(139, 124, 255, .13);
  color: var(--fh-text);
}

html[data-site-template="aurora"] .table thead th {
  background: rgba(6, 9, 25, .62);
  color: #e5e8f7;
}

html[data-site-template="aurora"] .table-hover > tbody > tr:hover > * {
  background: rgba(139, 124, 255, .075);
}

html[data-site-template="aurora"] .dashboard-hero,
html[data-site-template="aurora"] .create-vps-hero,
html[data-site-template="aurora"] .guide-hero,
html[data-site-template="aurora"] .docs-hero {
  background:
    linear-gradient(135deg, rgba(103, 82, 224, .28), rgba(13, 18, 40, .92) 55%, rgba(23, 115, 168, .2)) !important;
  border: 1px solid rgba(139, 124, 255, .28) !important;
  box-shadow: 0 18px 44px rgba(0, 0, 0, .25) !important;
}

html[data-site-template="aurora"] .badge.bg-label-primary,
html[data-site-template="aurora"] .bg-label-primary {
  background: rgba(139, 124, 255, .18) !important;
  color: #b7adff !important;
}

html[data-site-template="aurora"] .authentication-wrapper.authentication-basic {
  background:
    radial-gradient(circle at 15% 15%, rgba(133, 93, 255, .24), transparent 30rem),
    radial-gradient(circle at 90% 82%, rgba(0, 202, 255, .16), transparent 28rem),
    #080b1a;
}

html[data-site-template="aurora"] .authentication-wrapper .login-card {
  box-shadow: 0 28px 80px rgba(0, 0, 0, .48) !important;
}

html[data-site-template="aurora"] .authentication-wrapper a {
  color: #a99dff;
}

html[data-site-template="aurora"] .btn-close {
  filter: invert(1) grayscale(100%);
}

.template-preview-classic {
  background: #f4f7fb;
  color: #202938;
}

.template-preview-modern-slate {
  background: #151922;
  border-color: #2a3340 !important;
  color: #f3f6f9;
}

.template-preview-aurora {
  background: linear-gradient(135deg, #171d39, #0b1027);
  border-color: rgba(139, 124, 255, .45) !important;
  color: #f7f8ff;
}

.template-preview-classic .template-preview-primary {
  background: #6266e8;
  color: #fff;
}

.template-preview-modern-slate .template-preview-primary {
  background: #5fc0ff;
  color: #081018;
}

.template-preview-aurora .template-preview-primary {
  background: linear-gradient(135deg, #9a86ff, #586ce8);
  color: #fff;
}

html[data-site-template="aurora"] .btn-check:checked + .template-choice {
  border-color: #8b7cff !important;
  box-shadow: 0 0 0 3px rgba(139, 124, 255, .2) !important;
}

/* Keep Nordic Mint's textured surfaces after the shared fallbacks. */
html[data-site-template="nordic-mint"] body,
html[data-site-template="nordic-mint"] .content-wrapper,
html[data-site-template="nordic-mint"] .create-vps-page {
  background:
    radial-gradient(circle at 95% 5%, rgba(74, 176, 128, .12), transparent 28rem),
    radial-gradient(circle at 10% 95%, rgba(220, 174, 104, .08), transparent 25rem),
    var(--fh-page-bg) !important;
}

html[data-site-template="nordic-mint"] .dashboard-hero,
html[data-site-template="nordic-mint"] .create-vps-hero,
html[data-site-template="nordic-mint"] .guide-hero,
html[data-site-template="nordic-mint"] .docs-hero {
  background: linear-gradient(135deg, #ffffff 0%, #e5f3eb 100%) !important;
}

html[data-site-template="nordic-mint"] .btn-check:checked + .template-choice {
  border-color: #168a61 !important;
  box-shadow: 0 0 0 3px rgba(22, 138, 97, .16) !important;
}

html[data-site-template="nordic-mint"] {
  --fh-page-bg: #f1f6f3;
  --fh-card-bg: #ffffff;
  --fh-card-border: #dce9e2;
  --fh-text: #5a6d63;
  --fh-heading: #183c2d;
  --fh-primary: #168a61;
  --fh-sidebar-bg: #123c2d;
  --fh-navbar-bg: rgba(255, 255, 255, .94);
  --fh-radius: 14px;
}

html[data-site-template="nordic-mint"] body,
html[data-site-template="nordic-mint"] .content-wrapper,
html[data-site-template="nordic-mint"] .create-vps-page {
  background:
    radial-gradient(circle at 95% 5%, rgba(74, 176, 128, .12), transparent 28rem),
    radial-gradient(circle at 10% 95%, rgba(220, 174, 104, .08), transparent 25rem),
    var(--fh-page-bg) !important;
  color: var(--fh-text) !important;
}

html[data-site-template="nordic-mint"] h1,
html[data-site-template="nordic-mint"] h2,
html[data-site-template="nordic-mint"] h3,
html[data-site-template="nordic-mint"] h4,
html[data-site-template="nordic-mint"] h5,
html[data-site-template="nordic-mint"] h6,
html[data-site-template="nordic-mint"] .fw-bold,
html[data-site-template="nordic-mint"] .fw-semibold {
  color: var(--fh-heading) !important;
}

html[data-site-template="nordic-mint"] .layout-menu,
html[data-site-template="nordic-mint"] .bg-menu-theme {
  background: linear-gradient(180deg, #174936 0%, #0f3327 100%) !important;
  border-right: 1px solid rgba(255, 255, 255, .07);
  color: #d7ebe1 !important;
  box-shadow: 10px 0 34px rgba(20, 64, 47, .12);
}

html[data-site-template="nordic-mint"] .layout-menu .app-brand-text,
html[data-site-template="nordic-mint"] .layout-menu .menu-header-text,
html[data-site-template="nordic-mint"] .layout-menu .menu-link {
  color: #cce2d7 !important;
}

html[data-site-template="nordic-mint"] .layout-menu .menu-header-text {
  opacity: .68;
}

html[data-site-template="nordic-mint"] .layout-menu .menu-link {
  border-radius: 10px;
}

html[data-site-template="nordic-mint"] .layout-menu .menu-item.active > .menu-link {
  background: rgba(255, 255, 255, .13) !important;
  color: #fff !important;
  box-shadow: inset 3px 0 0 #75d3aa;
}

html[data-site-template="nordic-mint"] .layout-menu .menu-link:hover {
  background: rgba(255, 255, 255, .08) !important;
  color: #fff !important;
}

html[data-site-template="nordic-mint"] .layout-navbar,
html[data-site-template="nordic-mint"] .bg-navbar-theme {
  background: var(--fh-navbar-bg) !important;
  border: 1px solid var(--fh-card-border) !important;
  border-radius: var(--fh-radius) !important;
  box-shadow: 0 10px 28px rgba(27, 77, 57, .075) !important;
  backdrop-filter: blur(14px);
}

html[data-site-template="nordic-mint"] #layout-navbar,
html[data-site-template="nordic-mint"] #layout-navbar .nav-link,
html[data-site-template="nordic-mint"] #layout-navbar .nav-link > i,
html[data-site-template="nordic-mint"] #layout-navbar .navbar-nav-right,
html[data-site-template="nordic-mint"] #layout-navbar .dropdown-toggle {
  color: #214f3c !important;
}

html[data-site-template="nordic-mint"] #layout-navbar .nav-link:hover,
html[data-site-template="nordic-mint"] #layout-navbar .nav-link:focus {
  color: #0f7451 !important;
}

html[data-site-template="nordic-mint"] #layout-navbar .nav-link > .badge:not(.bg-danger):not(.bg-warning):not(.bg-info):not(.bg-primary) {
  background: #e1f0e8 !important;
  color: #175f46 !important;
}

html[data-site-template="nordic-mint"] #layout-navbar .btn-outline-secondary {
  border-color: #c7d9cf !important;
  color: #365e4d !important;
}

html[data-site-template="nordic-mint"] #layout-navbar .btn-outline-secondary:hover {
  background: #e8f3ed !important;
  border-color: #a9c9b8 !important;
  color: #174e39 !important;
}

html[data-site-template="nordic-mint"] .card,
html[data-site-template="nordic-mint"] .dropdown-menu,
html[data-site-template="nordic-mint"] .modal-content {
  background: var(--fh-card-bg) !important;
  border: 1px solid var(--fh-card-border) !important;
  border-radius: var(--fh-radius) !important;
  color: var(--fh-text) !important;
  box-shadow: 0 10px 30px rgba(27, 77, 57, .07) !important;
}

html[data-site-template="nordic-mint"] .card-header,
html[data-site-template="nordic-mint"] .card-footer,
html[data-site-template="nordic-mint"] .modal-header,
html[data-site-template="nordic-mint"] .modal-footer {
  background: transparent !important;
  border-color: var(--fh-card-border) !important;
}

html[data-site-template="nordic-mint"] .form-control,
html[data-site-template="nordic-mint"] .form-select,
html[data-site-template="nordic-mint"] .input-group-text {
  min-height: 42px;
  background: #f9fcfa !important;
  border-color: #d4e3da !important;
  border-radius: 10px;
  color: #214636 !important;
}

html[data-site-template="nordic-mint"] .form-control:focus,
html[data-site-template="nordic-mint"] .form-select:focus {
  background: #fff !important;
  border-color: #3aa77a !important;
  box-shadow: 0 0 0 .2rem rgba(22, 138, 97, .12);
}

html[data-site-template="nordic-mint"] .btn {
  border-radius: 10px;
  font-weight: 500;
}

html[data-site-template="nordic-mint"] .btn-primary {
  background: linear-gradient(135deg, #249c70, #117654) !important;
  border-color: #16845e !important;
  color: #fff !important;
  box-shadow: 0 7px 17px rgba(22, 138, 97, .2);
}

html[data-site-template="nordic-mint"] .btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 9px 21px rgba(22, 138, 97, .27);
}

html[data-site-template="nordic-mint"] .btn-outline-primary {
  border-color: rgba(22, 138, 97, .5) !important;
  color: #117654 !important;
}

html[data-site-template="nordic-mint"] .btn-outline-primary:hover {
  background: #168a61 !important;
  color: #fff !important;
}

html[data-site-template="nordic-mint"] .dropdown-item {
  color: var(--fh-text) !important;
}

html[data-site-template="nordic-mint"] .dropdown-item:hover,
html[data-site-template="nordic-mint"] .dropdown-item:focus {
  background: #eaf5ef !important;
  color: #117654 !important;
}

html[data-site-template="nordic-mint"] .table {
  color: var(--fh-text);
}

html[data-site-template="nordic-mint"] .table thead th {
  background: #edf5f0;
  color: #48665a;
  border-bottom-color: #d7e6dd;
  font-size: .76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .025em;
}

html[data-site-template="nordic-mint"] .table > :not(caption) > * > * {
  border-bottom-color: #e7f0eb;
}

html[data-site-template="nordic-mint"] .table-hover > tbody > tr:hover > * {
  background: #f0f8f4;
}

html[data-site-template="nordic-mint"] .dashboard-hero,
html[data-site-template="nordic-mint"] .create-vps-hero,
html[data-site-template="nordic-mint"] .guide-hero,
html[data-site-template="nordic-mint"] .docs-hero {
  background: linear-gradient(135deg, #ffffff 0%, #e5f3eb 100%) !important;
  border: 1px solid #d4e7dc !important;
  box-shadow: 0 14px 34px rgba(27, 77, 57, .08) !important;
}

html[data-site-template="nordic-mint"] .badge.bg-label-primary,
html[data-site-template="nordic-mint"] .bg-label-primary {
  background: rgba(22, 138, 97, .12) !important;
  color: #117654 !important;
}

html[data-site-template="nordic-mint"] .authentication-wrapper.authentication-basic {
  background:
    radial-gradient(circle at 12% 12%, rgba(52, 165, 116, .18), transparent 28rem),
    radial-gradient(circle at 88% 88%, rgba(213, 170, 102, .12), transparent 25rem),
    #eef5f1;
}

html[data-site-template="nordic-mint"] .authentication-wrapper .login-card {
  box-shadow: 0 24px 65px rgba(22, 72, 52, .15) !important;
}

html[data-site-template="nordic-mint"] .authentication-wrapper a {
  color: #117654;
}

.template-preview-nordic-mint {
  background: linear-gradient(135deg, #f5faf7 0%, #e1f1e8 100%);
  border-color: #cce2d5 !important;
  color: #183c2d;
}

.template-preview-nordic-mint .template-preview-primary {
  background: #168a61;
  color: #fff;
}

html[data-site-template="nordic-mint"] .btn-check:checked + .template-choice {
  border-color: #168a61 !important;
  box-shadow: 0 0 0 3px rgba(22, 138, 97, .16) !important;
}

html[data-site-template="modern-slate"] body,
html[data-site-template="modern-slate"] .content-wrapper {
  background: var(--fh-page-bg) !important;
  color: var(--fh-text);
}

html[data-site-template="modern-slate"] h1,
html[data-site-template="modern-slate"] h2,
html[data-site-template="modern-slate"] h3,
html[data-site-template="modern-slate"] h4,
html[data-site-template="modern-slate"] h5,
html[data-site-template="modern-slate"] h6,
html[data-site-template="modern-slate"] .fw-bold,
html[data-site-template="modern-slate"] .fw-semibold {
  color: var(--fh-heading) !important;
}

html[data-site-template="modern-slate"] .card,
html[data-site-template="modern-slate"] .dropdown-menu,
html[data-site-template="modern-slate"] .modal-content {
  background: var(--fh-card-bg) !important;
  border-color: var(--fh-card-border) !important;
  color: var(--fh-text);
  border-radius: var(--fh-radius);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .24) !important;
}

html[data-site-template="modern-slate"] .layout-menu,
html[data-site-template="modern-slate"] .bg-menu-theme {
  background: var(--fh-sidebar-bg) !important;
  color: var(--fh-text);
}

html[data-site-template="modern-slate"] .layout-navbar,
html[data-site-template="modern-slate"] .bg-navbar-theme {
  background: var(--fh-navbar-bg) !important;
  border: 1px solid var(--fh-card-border);
  color: var(--fh-text);
}

html[data-site-template="modern-slate"] .menu-link,
html[data-site-template="modern-slate"] .dropdown-item,
html[data-site-template="modern-slate"] .nav-link,
html[data-site-template="modern-slate"] .text-body {
  color: var(--fh-text) !important;
}

html[data-site-template="modern-slate"] .menu-item.active > .menu-link,
html[data-site-template="modern-slate"] .menu-link:hover,
html[data-site-template="modern-slate"] .dropdown-item:hover {
  background: rgba(95, 192, 255, .12) !important;
  color: #fff !important;
}

html[data-site-template="modern-slate"] .text-muted,
html[data-site-template="modern-slate"] small.text-muted {
  color: #8793a3 !important;
}

html[data-site-template="modern-slate"] .table {
  color: var(--fh-text);
}

html[data-site-template="modern-slate"] .table > :not(caption) > * > * {
  background: transparent;
  border-bottom-color: var(--fh-card-border);
  color: var(--fh-text);
}

html[data-site-template="modern-slate"] .table thead th {
  color: #f3f6f9;
  background: #111720;
}

html[data-site-template="modern-slate"] .form-control,
html[data-site-template="modern-slate"] .form-select,
html[data-site-template="modern-slate"] .input-group-text {
  background: #10151d !important;
  border-color: var(--fh-card-border) !important;
  color: #f3f6f9 !important;
  -webkit-text-fill-color: #f3f6f9;
}

html[data-site-template="modern-slate"] .form-control::placeholder {
  color: #7b8794 !important;
  opacity: 1;
}

html[data-site-template="modern-slate"] .btn-primary {
  background: var(--fh-primary) !important;
  border-color: var(--fh-primary) !important;
  color: #081018 !important;
}

html[data-site-template="modern-slate"] .btn-outline-primary {
  border-color: var(--fh-primary) !important;
  color: var(--fh-primary) !important;
}

html[data-site-template="modern-slate"] .btn-outline-primary:hover {
  background: var(--fh-primary) !important;
  color: #081018 !important;
}

html[data-site-template="modern-slate"] .badge.bg-label-primary,
html[data-site-template="modern-slate"] .bg-label-primary {
  background: rgba(95, 192, 255, .14) !important;
  color: #8bd2ff !important;
}

html[data-site-template="modern-slate"] .dashboard-hero,
html[data-site-template="modern-slate"] .server-hero,
html[data-site-template="modern-slate"] .invoice-hero,
html[data-site-template="modern-slate"] .create-user-header,
html[data-site-template="modern-slate"] .edit-user-header {
  background: linear-gradient(135deg, #18202b 0%, #111720 100%) !important;
  border: 1px solid var(--fh-card-border);
}

html[data-site-template="modern-slate"] .rounded.bg-white,
html[data-site-template="modern-slate"] .bg-light {
  background: #111720 !important;
  color: var(--fh-heading) !important;
}

html[data-site-template="modern-slate"] .frontpage-servers-card,
html[data-site-template="modern-slate"] .frontpage-servers-card > .card-header,
html[data-site-template="modern-slate"] .frontpage-servers-card > .card-body {
  background: #151922 !important;
  border-color: var(--fh-card-border) !important;
}

html[data-site-template="modern-slate"] .frontpage-server-item {
  background: #111720 !important;
  border-color: var(--fh-card-border) !important;
  color: var(--fh-text);
}

.template-choice {
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.btn-check:checked + .template-choice {
  border-color: var(--fh-primary) !important;
  box-shadow: 0 0 0 3px rgba(105, 108, 255, .16) !important;
  transform: translateY(-1px);
}

/* Shared dashboard surfaces. These selectors intentionally override old
   page-local colours so every page follows the selected site template. */
html[data-site-template] body,
html[data-site-template] .content-wrapper,
html[data-site-template] .create-vps-page {
  background: var(--fh-page-bg) !important;
  color: var(--fh-text) !important;
}

html[data-site-template] .layout-menu,
html[data-site-template] .bg-menu-theme {
  background: var(--fh-sidebar-bg) !important;
  color: var(--fh-text) !important;
}

html[data-site-template] .layout-navbar,
html[data-site-template] .bg-navbar-theme {
  background: var(--fh-navbar-bg) !important;
  border-color: var(--fh-card-border) !important;
  color: var(--fh-text) !important;
}

html[data-site-template] .dashboard-hero,
html[data-site-template] .create-vps-hero {
  background: var(--fh-card-bg) !important;
  border: 1px solid var(--fh-card-border) !important;
  color: var(--fh-heading) !important;
  border-radius: var(--fh-radius) !important;
  padding: 1.25rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .12);
}

html[data-site-template] .container-p-y > .card,
html[data-site-template] .container-p-y .row > .col-md-6 > .card,
html[data-site-template] .container-p-y .row > .col-lg-4 > .card,
html[data-site-template] .container-p-y .row > .col-lg-8 > .card,
html[data-site-template] .container-p-y .row > .col-xl-3 > .card,
html[data-site-template] .container-p-y .row > .col-xl-8 > .card,
html[data-site-template] .dashboard-card,
html[data-site-template] .buy-vps-card,
html[data-site-template] .frontpage-servers-card,
html[data-site-template] .frontpage-servers-card > .card-header,
html[data-site-template] .frontpage-servers-card > .card-body {
  background: var(--fh-card-bg) !important;
  border-color: var(--fh-card-border) !important;
  color: var(--fh-text) !important;
  border-radius: var(--fh-radius) !important;
}

html[data-site-template] .dashboard-hero-tile,
html[data-site-template] .quick-action,
html[data-site-template] .frontpage-server-item {
  background: var(--fh-page-bg) !important;
  border-color: var(--fh-card-border) !important;
  color: var(--fh-text) !important;
}

html[data-site-template] .container-p-y .card .text-muted,
html[data-site-template] .dashboard-card .text-muted,
html[data-site-template] .buy-vps-card .text-muted,
html[data-site-template] .buy-vps-card .form-text,
html[data-site-template] .frontpage-server-item .text-muted,
html[data-site-template] .dashboard-hero .text-muted,
html[data-site-template] .create-vps-hero .text-muted {
  color: color-mix(in srgb, var(--fh-text) 72%, transparent) !important;
}

html[data-site-template] .buy-vps-card .form-select,
html[data-site-template] .buy-vps-card .form-control {
  background-color: var(--fh-page-bg) !important;
  border-color: var(--fh-card-border) !important;
  color: var(--fh-text) !important;
  -webkit-text-fill-color: var(--fh-text) !important;
}

html[data-site-template] .buy-vps-card .form-select option,
html[data-site-template] .buy-vps-card .form-select optgroup {
  background: var(--fh-card-bg) !important;
  color: var(--fh-text) !important;
}

html[data-site-template] .buy-vps-card h5,
html[data-site-template] .buy-vps-card p,
html[data-site-template] .buy-vps-card strong,
html[data-site-template] .buy-vps-card .form-label,
html[data-site-template] .dashboard-card h4,
html[data-site-template] .dashboard-card h5,
html[data-site-template] .frontpage-servers-card h5 {
  color: var(--fh-heading) !important;
}

html[data-site-template] .guide-hero,
html[data-site-template] .docs-hero {
  background: var(--fh-card-bg) !important;
  border-color: var(--fh-card-border) !important;
  color: var(--fh-heading) !important;
}

html[data-site-template="modern-slate"] .guide-hero,
html[data-site-template="modern-slate"] .docs-hero {
  background: linear-gradient(135deg, #18202b 0%, #111720 100%) !important;
}

html[data-site-template] .fh-footer {
  background: transparent !important;
  color: var(--fh-text) !important;
}

html[data-site-template] .fh-footer-inner {
  background: var(--fh-card-bg);
  border: 1px solid var(--fh-card-border);
  border-radius: var(--fh-radius);
  padding: .85rem 1rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .08);
}

html[data-site-template] .fh-footer-brand {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border-radius: calc(var(--fh-radius) - 2px);
  background: color-mix(in srgb, var(--fh-primary) 15%, transparent);
  color: var(--fh-primary);
  font-size: 1.25rem;
}

@media (max-width: 575.98px) {
  html[data-site-template] .fh-footer-inner {
    align-items: stretch !important;
  }
  html[data-site-template] .fh-footer-inner .btn {
    width: 100%;
  }
}

@media (max-width: 767.98px) {
  html[data-site-template] .dashboard-hero,
  html[data-site-template] .create-vps-hero {
    padding: 1rem !important;
  }
}

html[data-site-template="modern-slate"] .dashboard-hero,
html[data-site-template="modern-slate"] .create-vps-hero {
  background: linear-gradient(135deg, #18202b 0%, #111720 100%) !important;
}

html[data-site-template="modern-slate"] .btn-check:checked + .template-choice {
  box-shadow: 0 0 0 3px rgba(95, 192, 255, .18) !important;
}

/* Keep Aurora's layered surfaces after the shared template fallbacks. */
html[data-site-template="aurora"] body,
html[data-site-template="aurora"] .content-wrapper,
html[data-site-template="aurora"] .create-vps-page {
  background:
    radial-gradient(circle at 8% 8%, rgba(111, 91, 255, .18), transparent 30rem),
    radial-gradient(circle at 92% 18%, rgba(0, 211, 255, .11), transparent 27rem),
    radial-gradient(circle at 70% 100%, rgba(235, 79, 255, .08), transparent 28rem),
    var(--fh-page-bg) !important;
}

html[data-site-template="aurora"] .dashboard-hero,
html[data-site-template="aurora"] .create-vps-hero,
html[data-site-template="aurora"] .guide-hero,
html[data-site-template="aurora"] .docs-hero {
  background: linear-gradient(135deg, rgba(103, 82, 224, .28), rgba(13, 18, 40, .94) 55%, rgba(23, 115, 168, .2)) !important;
}

html[data-site-template="aurora"] .btn-check:checked + .template-choice {
  border-color: #8b7cff !important;
  box-shadow: 0 0 0 3px rgba(139, 124, 255, .2) !important;
}
