html {
  scroll-behavior: smooth;
}

:root {
  color-scheme: light;
  --bg: #f8faff;
  --nav-bg: rgba(248, 250, 255, 0.82);
  --surface: #ffffff;
  --surface-grad-a: #f4f9ff;
  --surface-grad-b: #eaf2fd;
  --hero-a: #dce6f5;
  --hero-b: #eef4fc;
  --input-bg: #fafcff;
  --border: #e6edf8;
  --border-strong: #ccd9f0;
  --ink: #0b1a2f;
  --muted: #3e5077;
  --soft: #5f7093;
  --brand: #1e5bbf;
  --brand-bright: #1e5bbf;
  --logo-a: #0b2b5c;
  --logo-b: #1a4b8c;
  --chip-bg: #fff4dc;
  --chip-text: #8a5b00;
  --tag-bg: #e9effa;
  --tag-text: #1e4b8a;
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b1322;
  --nav-bg: rgba(11, 19, 34, 0.85);
  --surface: #121e33;
  --surface-grad-a: #16264a;
  --surface-grad-b: #101c31;
  --hero-a: #17273f;
  --hero-b: #101b2e;
  --input-bg: #0d1730;
  --border: #22314f;
  --border-strong: #334771;
  --ink: #e9effb;
  --muted: #aebcdc;
  --soft: #8698bc;
  --brand: #2f6fd6;
  --brand-bright: #6ea8ff;
  --logo-a: #7fb2ff;
  --logo-b: #cfe2ff;
  --chip-bg: rgba(245, 179, 66, 0.16);
  --chip-text: #ffd479;
  --tag-bg: rgba(110, 168, 255, 0.14);
  --tag-text: #9cc3ff;
}

/* smooth theme switch */
.theming *,
.theming *::before,
.theming *::after {
  transition: background-color 0.3s ease, color 0.3s ease,
              border-color 0.3s ease, box-shadow 0.3s ease, fill 0.3s ease !important;
}

/* keep anchored sections clear of the sticky navbar */
#solutions,
#news,
#reviews,
#contact {
  scroll-margin-top: 96px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

/* header / navbar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.3s ease, padding 0.3s ease;
}
.navbar.scrolled {
  padding: 12px 0;
  box-shadow: 0 10px 32px -14px rgba(11,43,92,0.22);
}

.logo {
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  background: linear-gradient(145deg, var(--logo-a), var(--logo-b));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline-block;
  text-decoration: none;
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.25, 1);
}
.logo:hover {
  transform: scale(1.04);
}
.logo span {
  color: #1e5bbf;
  background: none;
  -webkit-background-clip: unset;
  background-clip: unset;
}
.logo-icon {
  color: #1e5bbf;
  background: none;
  -webkit-background-clip: unset;
  background-clip: unset;
  font-size: 1.5rem;
  vertical-align: middle;
}

.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}
.nav-links a {
  text-decoration: none;
  color: var(--ink);
  font-weight: 500;
  transition: color 0.2s;
  position: relative;
}
.nav-links a:not(.btn-outline)::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 100%;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, #1e5bbf, #f5b342);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.25, 1);
}
.nav-links a:not(.btn-outline):hover::after {
  transform: scaleX(1);
}
.nav-links a:not(.btn-outline):hover {
  color: var(--brand-bright);
}
.btn-outline {
  border: 1.5px solid var(--brand);
  background: transparent;
  padding: 8px 22px;
  border-radius: 40px;
  font-weight: 600;
  color: var(--brand);
  transition: 0.2s;
  cursor: pointer;
}
.nav-links .btn-outline:hover {
  background: #1e5bbf;
  color: #ffffff;
  border-color: #1e5bbf;
}

/* hero */
.hero {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 50px 0 40px;
  gap: 30px;
}
.hero-content {
  flex: 1 1 400px;
}
.hero-content h1 {
  font-size: 3.2rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
}
.hero-content h1 i {
  color: #1e5bbf;
  margin-right: 8px;
}
.hero-content p {
  font-size: 1.2rem;
  color: var(--muted);
  max-width: 500px;
  margin-bottom: 2rem;
}
.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 2.5rem;
  margin-top: 2rem;
}
.stat-item {
  display: flex;
  flex-direction: column;
  padding: 10px 16px;
  border-radius: 18px;
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.25, 1), box-shadow 0.3s ease, background 0.3s ease;
}
.stat-item:hover {
  background: #ffffff;
  transform: translateY(-5px);
  box-shadow: 0 14px 28px -10px rgba(11,43,92,0.18);
}
.stat-number {
  font-size: 2.2rem;
  font-weight: 700;
  background: linear-gradient(145deg, var(--logo-a), var(--brand-bright));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.stat-label {
  font-size: 0.9rem;
  color: var(--soft);
  letter-spacing: 0.3px;
}

.hero-image {
  flex: 1 1 300px;
  background: linear-gradient(145deg, var(--hero-a), var(--hero-b));
  border-radius: 40px 40px 40px 8px;
  padding: 30px 25px;
  display: flex;
  flex-direction: column;
  gap: 15px;
  box-shadow: 0 20px 40px -12px rgba(0,20,50,0.2);
}
.hero-image .badge {
  background: var(--surface);
  padding: 14px 18px;
  border-radius: 60px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 500;
  box-shadow: 0 4px 10px rgba(0,0,0,0.02);
}
.hero-image .badge i {
  color: #1e5bbf;
  font-size: 1.2rem;
}
/* hero entrance + floating badges */
.hero-content h1,
.hero-content p,
.hero-stats {
  opacity: 0;
  animation: rise 0.75s cubic-bezier(0.2, 0.8, 0.25, 1) forwards;
}
.hero-content h1 { animation-delay: 0.05s; }
.hero-content p { animation-delay: 0.18s; }
.hero-stats { animation-delay: 0.32s; }
@keyframes rise {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: none; }
}
.hero-image {
  animation: rise 0.8s 0.28s cubic-bezier(0.2, 0.8, 0.25, 1) both;
}
.hero-image .badge {
  animation: floaty 5.5s ease-in-out infinite;
}
.hero-image .badge:nth-child(2) { animation-delay: 0.5s; }
.hero-image .badge:nth-child(3) { animation-delay: 1s; }
.hero-image .badge:nth-child(4) { animation-delay: 1.5s; }
@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-7px); }
}

.section-title {
  font-size: 2.2rem;
  font-weight: 600;
  margin: 50px 0 30px;
  letter-spacing: -0.3px;
  position: relative;
  padding-bottom: 14px;
}
.section-title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 68px;
  height: 4px;
  border-radius: 4px;
  background: linear-gradient(90deg, #1e5bbf, #f5b342);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.6s 0.15s cubic-bezier(0.2, 0.8, 0.25, 1);
}
.section-title.in-view::after {
  transform: scaleX(1);
}
.section-sub {
  color: var(--muted);
  margin-bottom: 40px;
}

/* solutions grid – fixed 3 per row */
.grid-2col {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin: 30px 0 20px;
}
.card {
  position: relative;
  isolation: isolate;
  background: var(--surface);
  padding: 26px 24px;
  border-radius: 24px;
  box-shadow: 0 6px 24px rgba(11,26,47,0.06);
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.25, 1), box-shadow 0.35s ease;
  overflow: hidden;
}
/* animated gradient accent bar */
.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 100%;
  height: 4px;
  background: linear-gradient(90deg, #1e5bbf, #7fb2ff, #f5b342);
  transition: right 0.5s cubic-bezier(0.2, 0.8, 0.25, 1);
  z-index: 1;
}
/* soft corner glow */
.card::after {
  content: "";
  position: absolute;
  top: -60px;
  right: -60px;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(30,91,191,0.10), transparent);
  opacity: 0;
  transition: opacity 0.45s ease;
  z-index: 0;
}
.card > * {
  position: relative;
  z-index: 1;
}
.card:hover {
  transform: translateY(-10px);
  box-shadow: 0 26px 50px -14px rgba(11,43,92,0.25);
}
.card:hover::before {
  right: 0;
}
.card:hover::after {
  opacity: 1;
}
.card img {
  border-radius: 16px;
  width: 100%;
  object-fit: cover;
  transition: transform 0.55s cubic-bezier(0.2, 0.8, 0.25, 1), filter 0.4s ease;
}
.card:hover img {
  transform: scale(1.05);
}
.card h3 {
  font-size: 1.3rem;
  margin-bottom: 10px;
  transition: color 0.3s ease;
}
.card:hover h3 {
  color: #1e5bbf;
}
.card p {
  color: var(--muted);
  font-size: 0.98rem;
}
.card .tag {
  display: inline-block;
  margin-top: 14px;
  background: var(--tag-bg);
  padding: 4px 14px;
  border-radius: 40px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--tag-text);
}

/* cctv & service blocking – special cards */
.special-card {
  border-left: none;
  background: linear-gradient(165deg, var(--surface-grad-a), var(--surface-grad-b));
  box-shadow:
    inset 4px 0 0 #1e5bbf,
    0 6px 24px rgba(11,26,47,0.06);
}
.special-card:hover {
  box-shadow:
    inset 4px 0 0 #1e5bbf,
    0 26px 50px -14px rgba(11,43,92,0.28);
}

/* it services cards flow in the main solutions grid */

.badge-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}
.badge-group span {
  display: inline-flex;
  align-items: center;
  background: var(--surface);
  padding: 6px 16px;
  border-radius: 60px;
  font-size: 0.85rem;
  font-weight: 500;
  box-shadow: 0 2px 8px rgba(0,0,0,0.03);
  border: 1px solid var(--border);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.badge-group span:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong);
  box-shadow: 0 6px 14px rgba(30,91,191,0.12);
}
.badge-group span i {
  margin-right: 5px;
}
.badge-price {
  background: var(--chip-bg);
  color: var(--chip-text);
  padding: 2px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  margin-left: 8px;
}

/* news / updates */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 28px;
  margin: 20px 0 10px;
}
.news-item {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--surface);
  padding: 22px 20px;
  border-radius: 24px;
  border: 1px solid var(--border);
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.25, 1), box-shadow 0.35s ease, border-color 0.35s ease;
}
.news-item::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 100%;
  height: 3px;
  background: linear-gradient(90deg, #1e5bbf, #f5b342);
  transition: right 0.45s cubic-bezier(0.2, 0.8, 0.25, 1);
}
.news-item:hover {
  transform: translateY(-8px);
  border-color: transparent;
  box-shadow: 0 20px 40px -14px rgba(11,43,92,0.22);
}
.news-item:hover::before {
  right: 0;
}
.news-item .meta {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--brand-bright);
  font-weight: 600;
}
.news-item h4 {
  margin: 12px 0 8px;
  font-size: 1.2rem;
}
.news-item p {
  color: var(--muted);
  font-size: 0.95rem;
}

/* client reviews */
.review-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 28px;
  margin: 30px 0 20px;
}
.review {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--surface);
  padding: 24px 20px;
  border-radius: 28px;
  border: 1px solid var(--border);
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.25, 1), box-shadow 0.35s ease, border-color 0.35s ease;
}
.review::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 100%;
  height: 3px;
  background: linear-gradient(90deg, #f5b342, #1e5bbf);
  transition: right 0.45s cubic-bezier(0.2, 0.8, 0.25, 1);
}
.review:hover {
  transform: translateY(-8px) rotate(-0.5deg);
  border-color: transparent;
  box-shadow: 0 20px 40px -14px rgba(11,43,92,0.22);
}
.review:hover::before {
  right: 0;
}
.review .stars {
  color: #f5b342;
  letter-spacing: 2px;
  margin-bottom: 6px;
}
.review blockquote {
  font-style: italic;
  color: var(--ink);
  margin: 12px 0;
}
.review .author {
  font-weight: 600;
  color: var(--ink);
}
.review .title {
  font-size: 0.8rem;
  color: var(--soft);
}

.theme-toggle {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1.5px solid var(--border-strong);
  background: var(--surface);
  color: var(--brand-bright);
  cursor: pointer;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.25, 1), box-shadow 0.3s ease, border-color 0.3s ease;
}
.theme-toggle:hover {
  transform: rotate(20deg) scale(1.08);
  border-color: var(--brand-bright);
  box-shadow: 0 6px 18px rgba(30, 91, 191, 0.25);
}

/* progress tracker (inspired by WhatsApp image) */
.tracker-panel {
  background: var(--surface);
  border-radius: 40px;
  padding: 30px 32px;
  margin: 50px 0 30px;
  border: 1px solid var(--border);
  box-shadow: 0 10px 30px rgba(0,20,50,0.04);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.25, 1), box-shadow 0.35s ease, border-color 0.35s ease;
}
.tracker-panel::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 100%;
  height: 4px;
  background: linear-gradient(90deg, #1e5bbf, #f5b342);
  transition: right 0.5s cubic-bezier(0.2, 0.8, 0.25, 1);
}
.tracker-panel:hover {
  transform: translateY(-6px);
  border-color: #bcd3f5;
  box-shadow: 0 24px 48px -16px rgba(11,43,92,0.22);
}
.tracker-panel:hover::before {
  right: 0;
}
.tracker-panel .track-label {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 600;
  font-size: 1.1rem;
}
.tracker-panel .track-label i {
  color: #1e5bbf;
  font-size: 1.6rem;
}
.tracker-input-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  flex: 1 1 300px;
}
.tracker-input-group input {
  flex: 2 1 200px;
  padding: 14px 18px;
  border-radius: 60px;
  border: 1px solid var(--border-strong);
  font-size: 0.95rem;
  background: var(--input-bg);
  color: var(--ink);
}
.tracker-input-group input:focus {
  outline: 2px solid #1e5bbf;
  border-color: transparent;
}
.tracker-id-display {
  flex: 2 1 200px;
  padding: 14px 18px;
  border-radius: 60px;
  border: 1px solid var(--border-strong);
  font-size: 0.95rem;
  background: var(--input-bg);
  color: var(--soft);
  display: flex;
  align-items: center;
  gap: 10px;
}
.tracker-input-group .btn-primary {
  background: #1e5bbf;
  color: white;
  border: none;
  padding: 14px 32px;
  border-radius: 60px;
  font-weight: 600;
  cursor: default;
  transition: 0.2s;
}
.tracker-input-group .btn-primary i {
  margin-right: 8px;
}
.tracker-hint {
  color: var(--soft);
  font-size: 0.9rem;
}

/* card contact form */
.card-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.card-contact input {
  flex: 1 1 120px;
  min-width: 0;
  padding: 10px 16px;
  border-radius: 40px;
  border: 1px solid var(--border-strong);
  font-size: 0.9rem;
  background: var(--input-bg);
  color: var(--ink);
}
.card-contact input:focus {
  outline: 2px solid #1e5bbf;
  border-color: transparent;
}
.btn-whatsapp {
  background: linear-gradient(135deg, #2fe071, #22c15e);
  color: white;
  border: none;
  padding: 10px 24px;
  border-radius: 40px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  white-space: nowrap;
  box-shadow: 0 4px 14px rgba(37,211,102,0.35);
}
.btn-whatsapp:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 8px 20px rgba(37,211,102,0.45);
}
.card:hover .btn-whatsapp {
  animation: wa-pulse 2s infinite;
}
@keyframes wa-pulse {
  0%   { box-shadow: 0 4px 14px rgba(37,211,102,0.35), 0 0 0 0 rgba(37,211,102,0.40); }
  70%  { box-shadow: 0 4px 14px rgba(37,211,102,0.35), 0 0 0 12px rgba(37,211,102,0); }
  100% { box-shadow: 0 4px 14px rgba(37,211,102,0.35), 0 0 0 0 rgba(37,211,102,0); }
}

/* scroll-reveal entrance */
.reveal {
  opacity: 0;
  transform: translateY(26px);
}
.reveal.in-view {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .card, .card img, .card::before, .badge-group span, .btn-whatsapp,
  .news-item, .review, .tracker-panel, .navbar, .nav-links a::after,
  .stat-item, .hero-content h1, .hero-content p, .hero-stats,
  .hero-image, .hero-image .badge, .section-title::after, .footer-note .fab {
    transition: none !important;
    animation: none !important;
  }
  .hero-content h1, .hero-content p, .hero-stats, .hero-image { opacity: 1; }
  .reveal { opacity: 1; transform: none; }
}
.btn-whatsapp i {
  margin-right: 6px;
}

.footer-note {
  border-top: 1px solid var(--border);
  padding: 30px 0 20px;
  margin-top: 40px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  font-size: 0.9rem;
  color: var(--muted);
}

.flex-center {
  display: flex;
  align-items: center;
  gap: 8px;
}
.footer-note .fab,
.footer-note .fas {
  transition: transform 0.25s ease, color 0.25s ease;
  cursor: pointer;
}
.footer-note .fab:hover {
  color: var(--brand-bright);
  transform: translateY(-3px) scale(1.15);
}

/* ─── hamburger menu ─── */
.nav-toggle {
  display: none;
  background: none;
  border: 1.5px solid var(--border-strong);
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  color: var(--ink);
  font-size: 1.1rem;
  transition: background 0.2s, color 0.2s;
}
.nav-toggle:hover {
  background: var(--tag-bg);
  color: var(--brand);
}

@media (max-width: 992px) {
  .grid-2col {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 16px;
  }
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .navbar {
    flex-wrap: nowrap;
  }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--nav-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    flex-direction: column;
    gap: 0;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 12px 32px rgba(11,43,92,0.12);
    z-index: 99;
  }
  .nav-links.open {
    display: flex;
  }
  .nav-links a,
  .nav-links button,
  .nav-links .btn-outline,
  .nav-links .btn-nav-register,
  .nav-links .nav-user {
    width: 100%;
    padding: 12px 16px;
    border-radius: 12px;
    text-align: left;
    font-size: 0.95rem;
  }
  .nav-links .btn-outline,
  .nav-links .btn-nav-register {
    text-align: center;
    margin-top: 4px;
  }
  .nav-links .nav-logout-form {
    width: 100%;
  }
  .nav-links .nav-logout-form button {
    width: 100%;
    padding: 12px 16px;
    border-radius: 12px;
    text-align: center;
    border: 1.5px solid var(--border-strong);
  }
  .nav-user {
    border-bottom: 1px solid var(--border);
    padding-bottom: 12px;
    margin-bottom: 4px;
  }

  .hero {
    flex-direction: column;
    gap: 24px;
    padding: 30px 0;
  }
  .hero-content h1 {
    font-size: 2.2rem;
  }
  .hero-content p {
    font-size: 1.05rem;
  }
  .hero-stats {
    gap: 1rem;
  }
  .stat-item {
    padding: 8px 12px;
  }
  .stat-number {
    font-size: 1.6rem;
  }
  .hero-image {
    border-radius: 24px;
    padding: 20px 18px;
    width: 100%;
  }
  .hero-image .badge {
    padding: 12px 16px;
    font-size: 0.9rem;
  }

  .section-title {
    font-size: 1.6rem;
    margin: 36px 0 20px;
  }

  .grid-2col {
    grid-template-columns: 1fr;
    gap: 18px;
    margin: 20px 0 16px;
  }
  .card {
    padding: 20px 18px;
    border-radius: 20px;
  }
  .card h3 {
    font-size: 1.1rem;
  }
  .badge-group {
    gap: 8px;
  }
  .badge-group span {
    padding: 5px 12px;
    font-size: 0.8rem;
  }

  .news-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .news-item {
    padding: 18px 16px;
  }

  .review-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .review {
    padding: 20px 16px;
  }

  .tracker-panel {
    flex-direction: column;
    align-items: flex-start;
    padding: 24px 20px;
    border-radius: 24px;
  }
  .tracker-input-group {
    flex-direction: column;
    width: 100%;
  }
  .tracker-input-group .btn-primary {
    width: 100%;
    text-align: center;
    cursor: pointer;
  }

  .footer-note {
    flex-direction: column;
    gap: 16px;
    padding: 24px 0 16px;
    text-align: center;
  }

  .modal {
    width: calc(100% - 24px);
    max-height: 92vh;
    border-radius: 24px;
    padding: 32px 20px 24px;
  }
  .modal-header h2 {
    font-size: 1.2rem;
  }
  .modal-search {
    flex-direction: column;
    gap: 8px;
  }
  .modal-search .btn-primary {
    width: 100%;
    text-align: center;
  }
  .modal-tabs {
    gap: 6px;
    flex-wrap: wrap;
  }
  .tab {
    flex: 1 1 auto;
    padding: 10px 12px;
    font-size: 0.8rem;
  }
  .tab i {
    margin-right: 4px;
  }

  .solution-modal-card,
  .news-modal-card,
  .form-modal-card {
    padding: 28px 20px 24px;
    border-radius: 24px;
  }
  .solution-modal-head h2,
  .news-modal-title,
  .form-modal-header h2 {
    font-size: 1.2rem;
  }
  .solution-modal-footer,
  .news-modal-footer {
    flex-direction: column;
  }
  .solution-modal-footer button,
  .news-modal-footer button {
    width: 100%;
    text-align: center;
  }

  .form-row {
    flex-direction: column;
    gap: 14px;
  }
  .card-contact {
    flex-direction: column;
  }
  .card-contact input {
    flex: auto;
  }
  .btn-whatsapp {
    width: 100%;
    text-align: center;
  }
}

@media (max-width: 380px) {
  .hero-content h1 {
    font-size: 1.8rem;
  }
  .stat-number {
    font-size: 1.4rem;
  }
  .modal {
    width: calc(100% - 16px);
    padding: 24px 16px 20px;
    border-radius: 20px;
  }
  .tab {
    padding: 8px 10px;
    font-size: 0.75rem;
  }
}

/* ─── card read-more arrow ─── */
.card-read-more {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--tag-bg);
  color: var(--brand-bright);
  font-size: 0.8rem;
  margin-top: 14px;
  transition: background 0.2s, transform 0.3s;
}
.special-card:hover .card-read-more {
  background: var(--brand);
  color: #fff;
  transform: translateX(4px);
}

.card-request-service {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  margin-top: 14px;
  border: none;
  padding: 12px 18px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  background: linear-gradient(135deg, #6c5ce7, #a29bfe);
  color: #fff;
  box-shadow: 0 4px 14px rgba(108, 92, 231, 0.3);
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.25, 1), box-shadow 0.25s ease;
}
.card-request-service:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(108, 92, 231, 0.4);
}
.card-request-service:active { transform: translateY(0) scale(0.98); }
.card-request-service i { margin-right: 2px; }

/* ─── solution detail modal ─── */
.solution-overlay { z-index: 10001; }
.solution-modal-card { text-align: left; padding: 48px 44px 40px; }
.solution-modal-head { margin-bottom: 24px; }
.solution-modal-icon {
  width: 56px; height: 56px; border-radius: 18px;
  background: linear-gradient(135deg, var(--logo-a), var(--brand));
  color: #fff; font-size: 1.3rem;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
  box-shadow: 0 8px 22px rgba(30,91,191,0.22);
}
.solution-modal-head h2 { font-size: 1.45rem; color: var(--ink); margin-bottom: 6px; }
.sol-modal-desc { color: var(--muted); font-size: 0.95rem; }

.sol-modal-extended {
  margin-bottom: 24px;
  padding: 20px 24px;
  background: var(--input-bg);
  border: 1px solid var(--border);
  border-radius: 18px;
}
.sol-modal-extended h4 { font-size: 0.92rem; color: var(--ink); margin-bottom: 12px; font-weight: 700; }
.sol-modal-extended ul { margin: 0; padding: 0 0 0 18px; }
.sol-modal-extended li {
  color: var(--muted); font-size: 0.92rem; line-height: 1.65;
  margin-bottom: 6px; position: relative; padding-left: 4px;
}
.sol-modal-extended li::marker { color: var(--brand-bright); }

.bd-feat-list { list-style: none !important; padding: 0 0 0 2px !important; }
.bd-feat-list li { display: flex; align-items: flex-start; gap: 10px; padding-left: 0 !important; }
.bd-feat-list li::marker { content: none !important; }
.bd-feat-list li i { color: var(--brand-bright); margin-top: 4px; flex: none; }

.sol-modal-badges {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-bottom: 28px;
}
.sol-modal-badges .badge-pill {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 16px; border-radius: 40px;
  background: var(--surface); border: 1px solid var(--border);
  font-size: 0.85rem; color: var(--ink);
  transition: transform 0.2s, border-color 0.2s;
}
.sol-modal-badges .badge-pill:hover { transform: translateY(-2px); border-color: var(--border-strong); }
.sol-modal-badges .badge-pill .badge-price {
  background: var(--chip-bg); color: var(--chip-text);
  padding: 2px 10px; border-radius: 30px; font-weight: 700; font-size: 0.8rem;
}

.solution-modal-footer {
  display: flex; align-items: center; gap: 12px;
  padding-top: 22px; border-top: 1px solid var(--border);
}
.sol-modal-cta {
  border: none; padding: 14px 30px; border-radius: 50px;
  font-weight: 600; font-size: 0.95rem; cursor: pointer;
  background: #25d366; color: #fff;
  box-shadow: 0 4px 14px rgba(37,211,102,0.3);
  transition: transform 0.25s cubic-bezier(0.2,0.8,0.25,1), box-shadow 0.25s ease;
}
.sol-modal-cta:hover { transform: translateY(-2px) scale(1.03); box-shadow: 0 8px 24px rgba(37,211,102,0.4); }
.sol-modal-cta:active { transform: translateY(0) scale(0.98); }
.sol-modal-cta i { margin-right: 8px; }

.sol-modal-request {
  display: inline-flex; align-items: center;
  border: none; padding: 14px 30px; border-radius: 50px;
  font-weight: 600; font-size: 0.95rem; cursor: pointer;
  background: linear-gradient(135deg, #6c5ce7, #a29bfe); color: #fff;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(108,92,231,0.3);
  transition: transform 0.25s cubic-bezier(0.2,0.8,0.25,1), box-shadow 0.25s ease;
}
.sol-modal-request:hover { transform: translateY(-2px) scale(1.03); box-shadow: 0 8px 24px rgba(108,92,231,0.4); color: #fff; }
.sol-modal-request:active { transform: translateY(0) scale(0.98); }
.sol-modal-request i { margin-right: 8px; }

.sol-modal-dismiss {
  border: 1.5px solid var(--border-strong); background: transparent;
  color: var(--muted); padding: 13px 28px; border-radius: 50px;
  font-weight: 600; font-size: 0.92rem; cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.sol-modal-dismiss:hover { background: var(--input-bg); color: var(--ink); }

.bd-modal-cat {
  font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--brand); font-weight: 700; margin-bottom: 6px;
}
.badge-detail-price {
  margin: 0 0 6px; font-size: 1.6rem; font-weight: 800; color: var(--brand);
}
#bd-modal-price { margin-bottom: 16px; }

.payment-note {
  margin-top: 14px; font-size: 0.82rem; color: var(--muted);
  display: flex; align-items: center; gap: 6px; justify-content: center;
}
.payment-note i { color: var(--brand); }
#payment-form input[readonly] {
  background: var(--input-bg); cursor: not-allowed; opacity: 0.85;
}

/* ─── beautified payment modal ─── */
.payment-card { padding: 46px 40px 36px; }
.payment-icon {
  width: 64px; height: 64px; border-radius: 20px;
  background: linear-gradient(135deg, #6c5ce7, #a29bfe);
  font-size: 1.5rem; box-shadow: 0 10px 26px rgba(108,92,231,0.3);
}
.pay-summary {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-bottom: 22px; padding: 14px 18px; border-radius: 16px;
  background: linear-gradient(135deg, rgba(108,92,231,0.10), rgba(30,91,191,0.05));
  border: 1.5px solid var(--border);
}
.pay-summary-label { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-weight: 700; }
.pay-summary-name { font-weight: 700; color: var(--ink); font-size: 0.95rem; text-align: right; }
.pay-fields { display: flex; flex-direction: column; gap: 14px; }
.pay-input-wrap { position: relative; }
.pay-input-wrap > i {
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  color: var(--muted); font-size: 0.85rem; pointer-events: none; z-index: 1;
}
.pay-input-wrap input {
  width: 100%;
  padding: 13px 16px 13px 44px;
  border-radius: 14px;
  border: 1.5px solid var(--border-strong);
  background: var(--input-bg);
  color: var(--ink);
  font-size: 0.92rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.pay-input-wrap input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(30, 91, 191, 0.12);
}
.amount-wrap .amount-fixed {
  position: absolute; right: 16px; top: 50%; transform: translateY(-50%);
  font-weight: 700; color: var(--brand-bright); font-size: 0.9rem; pointer-events: none;
}
.amount-wrap input { font-weight: 700; }
.amount-wrap input[readonly] { cursor: not-allowed; background: var(--input-bg); }
.amount-wrap input::-webkit-outer-spin-button,
.amount-wrap input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.amount-wrap input[type="number"] { -moz-appearance: textfield; appearance: textfield; }
.pay-options {
  display: flex; gap: 8px; margin-top: 18px; flex-wrap: wrap;
}
.pay-opt {
  flex: 1; min-width: 86px; text-align: center; padding: 10px 6px;
  border-radius: 12px; font-size: 0.78rem; font-weight: 600; color: var(--muted);
  border: 1.5px solid var(--border-strong); background: var(--input-bg);
  cursor: default; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
.pay-opt.active {
  color: #fff; background: linear-gradient(135deg, #6c5ce7, #a29bfe);
  border-color: transparent; box-shadow: 0 4px 14px rgba(108,92,231,0.3);
}
.pay-submit {
  background: linear-gradient(135deg, #6c5ce7, #a29bfe);
  box-shadow: 0 4px 16px rgba(108,92,231,0.3);
}
.pay-submit:hover { box-shadow: 0 10px 28px rgba(108,92,231,0.42); }
@media (max-width: 560px) {
  .payment-card { padding: 38px 22px 28px; }
  .pay-opt { font-size: 0.72rem; }
}

/* ─── service request modal ─── */
.sr-card { padding: 46px 40px 36px; }
.sr-icon {
  width: 64px; height: 64px; border-radius: 20px;
  background: linear-gradient(135deg, #25d366, #1fbf5a);
  font-size: 1.4rem; box-shadow: 0 10px 26px rgba(37,211,102,0.3);
}
.sr-form { display: flex; flex-direction: column; gap: 14px; }
.sr-input-wrap input,
.sr-input-wrap textarea,
.sr-input-wrap select {
  width: 100%;
  padding: 13px 16px;
  border-radius: 14px;
  border: 1.5px solid var(--border-strong);
  background: var(--input-bg);
  color: var(--ink);
  font-size: 0.92rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.sr-input-wrap input:focus,
.sr-input-wrap textarea:focus,
.sr-input-wrap select:focus {
  border-color: #25d366;
  box-shadow: 0 0 0 4px rgba(37,211,102,0.14);
}
.sr-input-wrap textarea { resize: vertical; min-height: 90px; }
.sr-input-wrap select { cursor: pointer; }
.sr-submit {
  background: linear-gradient(135deg, #25d366, #1fbf5a);
  box-shadow: 0 4px 16px rgba(37,211,102,0.3);
}
.sr-submit:hover { box-shadow: 0 10px 28px rgba(37,211,102,0.42); }
.sr-note { color: var(--muted); }
@media (max-width: 560px) {
  .sr-card { padding: 38px 22px 28px; }
}
.badge-view-link {
  background: none; border: none; color: var(--brand-bright);
  cursor: pointer; font-weight: 600; font-size: 0.78rem;
  margin-left: 6px; text-decoration: underline dotted;
  padding: 0; transition: color 0.2s;
}
.badge-view-link:hover { color: var(--brand); }
.btn-primary.sol-modal-request { display: inline-flex; align-items: center; }
.btn-primary.sol-modal-request i { margin-right: 8px; }

.sol-modal-badge-detail {
  position: relative; margin-top: 16px; padding: 18px 20px;
  border: 1.5px solid var(--brand-bright);
  border-radius: 16px; background: linear-gradient(135deg, rgba(108,92,231,0.08), rgba(30,91,191,0.04));
}
.sol-modal-badge-detail h4 { margin: 0 0 6px; font-size: 1.1rem; color: var(--ink); }
.sol-modal-badge-detail .badge-detail-desc { margin: 0 0 8px; color: var(--muted); font-size: 0.9rem; }
.sol-modal-badge-detail .badge-detail-price {
  font-size: 1.25rem; font-weight: 700; color: var(--brand); margin-bottom: 14px;
}
.badge-detail-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.badge-detail-close {
  position: absolute; top: 8px; right: 10px;
  background: none; border: none; color: var(--muted);
  font-size: 1rem; cursor: pointer; padding: 4px;
}
.badge-detail-close:hover { color: var(--ink); }
.badge-detail-pay { background: linear-gradient(135deg, #6c5ce7, #a29bfe); color: #fff; }

[data-theme="dark"] .solution-modal-card {
  box-shadow: 0 24px 64px rgba(0,0,0,0.35), 0 0 0 1px rgba(255,255,255,0.04) inset;
}
@media (max-width: 560px) {
  .solution-modal-card { padding: 40px 24px 32px; border-radius: 28px; }
  .solution-modal-head h2 { font-size: 1.25rem; }
  .solution-modal-footer { flex-direction: column; }
}
.news-read-more {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--tag-bg);
  color: var(--brand-bright);
  font-size: 0.8rem;
  margin-top: 14px;
  transition: background 0.2s, transform 0.3s;
}
.news-item:hover .news-read-more {
  background: var(--brand);
  color: #fff;
  transform: translateX(4px);
}

/* ─── news detail modal ─── */
.news-overlay {
  z-index: 10000;
}
.news-modal-card {
  text-align: left;
  padding: 48px 44px 40px;
}
.news-modal-badge {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--logo-a), var(--brand));
  color: #fff;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  box-shadow: 0 6px 18px rgba(30, 91, 191, 0.2);
}
.news-modal-meta {
  font-size: 0.82rem;
  color: var(--soft);
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.news-modal-title {
  font-size: 1.5rem;
  margin-bottom: 20px;
  color: var(--ink);
  line-height: 1.3;
}
.news-modal-body {
  color: var(--muted);
  font-size: 0.98rem;
  line-height: 1.7;
  margin-bottom: 28px;
}
.news-modal-body h4 {
  color: var(--ink);
  font-size: 1.1rem;
  margin-bottom: 8px;
}
.news-modal-body p { margin-bottom: 12px; }
.news-modal-body ul {
  margin: 8px 0 0 20px;
  padding: 0;
}
.news-modal-body li {
  margin-bottom: 6px;
}
.news-modal-body strong { color: var(--ink); }

.news-modal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}
.news-modal-tag {
  font-size: 0.82rem;
  color: var(--soft);
  font-weight: 600;
}
.news-modal-tag i { margin-right: 6px; }
.news-modal-dismiss {
  border: none;
  padding: 12px 28px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  background: linear-gradient(135deg, var(--brand), var(--logo-b));
  color: #fff;
  box-shadow: 0 4px 14px rgba(30, 91, 191, 0.25);
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.25, 1), box-shadow 0.25s ease;
}
.news-modal-dismiss:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 8px 24px rgba(30, 91, 191, 0.35);
}
.news-modal-dismiss:active {
  transform: translateY(0) scale(0.98);
}
[data-theme="dark"] .news-modal-card {
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.04) inset;
}

/* ─── mobile news modal ─── */
@media (max-width: 560px) {
  .news-modal-card {
    padding: 40px 24px 32px;
    border-radius: 28px;
  }
  .news-modal-title { font-size: 1.25rem; }
  .news-modal-footer { flex-direction: column-reverse; gap: 14px; }
}

/* ─── "Add" section buttons ─── */
.btn-add-section {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 18px 0 0;
  padding: 10px 22px;
  border-radius: 40px;
  border: 1.5px dashed var(--border-strong);
  background: transparent;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.btn-add-section:hover {
  border-color: var(--brand);
  color: var(--brand);
  background: var(--tag-bg);
}

/* ─── form modals ─── */
.form-overlay { z-index: 10002; }
.form-modal-card { text-align: left; padding: 44px 40px 36px; max-height: 90vh; overflow-y: auto; }

.form-modal-header { text-align: center; margin-bottom: 28px; }
.form-modal-icon {
  width: 52px; height: 52px; border-radius: 16px;
  background: linear-gradient(135deg, var(--brand), var(--logo-b));
  color: #fff; font-size: 1.2rem;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 16px;
  box-shadow: 0 8px 22px rgba(30, 91, 191, 0.22);
}
.form-modal-header h2 { font-size: 1.4rem; color: var(--ink); margin-bottom: 6px; }
.form-modal-header p { color: var(--muted); font-size: 0.95rem; }

.django-form { display: flex; flex-direction: column; gap: 16px; }
.form-row { display: flex; gap: 16px; }
.form-row .form-group { flex: 1; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label {
  font-size: 0.85rem; font-weight: 600; color: var(--muted);
}
.form-group label i { margin-right: 6px; color: var(--brand-bright); width: 16px; text-align: center; }

.form-input,
.django-form input[type="text"],
.django-form input[type="email"],
.django-form input[type="tel"],
.django-form input[type="number"],
.django-form input[type="date"],
.django-form textarea,
.django-form select {
  width: 100%;
  padding: 12px 16px;
  border-radius: 14px;
  border: 1.5px solid var(--border-strong);
  background: var(--input-bg);
  color: var(--ink);
  font-size: 0.92rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-input:focus,
.django-form input:focus,
.django-form textarea:focus,
.django-form select:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(30, 91, 191, 0.1);
}
.django-form textarea { resize: vertical; min-height: 80px; }
.django-form select { cursor: pointer; appearance: auto; }

.form-actions { padding-top: 8px; }
.form-submit {
  width: 100%;
  border: none;
  padding: 14px 28px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  background: linear-gradient(135deg, var(--brand), var(--logo-b));
  color: #fff;
  box-shadow: 0 4px 14px rgba(30, 91, 191, 0.25);
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.25, 1), box-shadow 0.25s ease;
}
.form-submit:hover { transform: translateY(-2px) scale(1.02); box-shadow: 0 8px 24px rgba(30, 91, 191, 0.35); }
.form-submit:active { transform: translateY(0) scale(0.98); }
.form-submit i { margin-right: 8px; }

.tracker-result {
  background: var(--input-bg);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 20px 24px;
  margin-bottom: 24px;
}
.tracker-result .result-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 6px 0; border-bottom: 1px solid var(--border);
}
.tracker-result .result-row:last-child { border-bottom: none; }
.tracker-result .result-label { font-size: 0.82rem; color: var(--soft); font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.tracker-result .result-value { font-size: 0.95rem; color: var(--ink); font-weight: 600; }
.tracker-result .result-error { color: #ef4444; font-weight: 600; text-align: center; padding: 8px 0; }

@media (max-width: 560px) {
  .form-row { flex-direction: column; gap: 16px; }
  .form-modal-card { padding: 36px 20px 28px; border-radius: 28px; }
}
[data-theme="dark"] .form-modal-card {
  box-shadow: 0 24px 64px rgba(0,0,0,0.35), 0 0 0 1px rgba(255,255,255,0.04) inset;
}

.tracker-panel {
  cursor: pointer;
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}
.tracker-panel:hover {
  box-shadow: 0 10px 30px rgba(30, 91, 191, 0.12);
  transform: translateY(-3px);
}

/* ─── modal overlay ─── */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(5, 10, 25, 0.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}
.modal-overlay.open {
  opacity: 1;
  visibility: visible;
}

/* ─── modal card ─── */
.modal {
  position: relative;
  width: 580px;
  max-width: 92vw;
  max-height: 88vh;
  overflow-y: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 32px;
  padding: 44px 40px 36px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.18),
              0 0 0 1px rgba(255, 255, 255, 0.04) inset;
  transform: translateY(28px) scale(0.97);
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.4s ease;
}
.modal-overlay.open .modal {
  transform: translateY(0) scale(1);
}

/* scrollbar inside modal */
.modal::-webkit-scrollbar { width: 6px; }
.modal::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 10px; }

/* close button */
.modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--input-bg);
  color: var(--soft);
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s, transform 0.25s;
}
.modal-close:hover {
  background: var(--brand);
  color: #fff;
  transform: rotate(90deg);
}

/* header */
.modal-header {
  text-align: center;
  margin-bottom: 28px;
}
.modal-icon {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  background: linear-gradient(145deg, var(--logo-a), var(--brand));
  color: #fff;
  font-size: 1.35rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  box-shadow: 0 8px 22px rgba(30, 91, 191, 0.22);
}
.modal-header h2 {
  font-size: 1.45rem;
  margin-bottom: 6px;
  color: var(--ink);
}
.modal-header p {
  color: var(--muted);
  font-size: 0.95rem;
}

/* search form */
.modal-search {
  display: flex;
  gap: 10px;
  margin-bottom: 24px;
}
.modal-input {
  flex: 1;
  min-width: 0;
  padding: 13px 20px;
  border-radius: 50px;
  border: 1.5px solid var(--border-strong);
  background: var(--input-bg);
  color: var(--ink);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}
.modal-input:focus {
  border-color: var(--brand);
}
.modal-search .btn-primary {
  white-space: nowrap;
  background: linear-gradient(135deg, var(--brand), var(--logo-b));
  color: #ffffff;
  border: none;
  padding: 14px 30px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(30, 91, 191, 0.25);
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.25, 1), box-shadow 0.25s ease;
}
.modal-search .btn-primary i {
  margin-right: 8px;
}
.modal-search .btn-primary:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 8px 24px rgba(30, 91, 191, 0.35);
}
.modal-search .btn-primary:active {
  transform: translateY(0) scale(0.98);
  box-shadow: 0 2px 8px rgba(30, 91, 191, 0.2);
}

/* tabs */
.modal-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 14px;
}
.tab {
  flex: 1;
  padding: 11px 16px;
  border-radius: 14px;
  border: 1.5px solid var(--border);
  background: transparent;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.tab i { margin-right: 6px; }
.tab:hover { border-color: var(--brand-bright); color: var(--brand-bright); }
.tab.active {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}

/* tab panels */
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* status timeline */
.status-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  position: relative;
}
.status-item:last-child { border-bottom: none; }

.status-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid var(--border-strong);
  background: var(--input-bg);
  flex-shrink: 0;
  margin-top: 3px;
  transition: background 0.3s, border-color 0.3s;
}
.status-item.done .status-dot {
  background: #22c55e;
  border-color: #22c55e;
}
.status-item.active .status-dot {
  background: var(--brand);
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(30, 91, 191, 0.18);
  animation: pulse-dot 1.8s infinite;
}
@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 4px rgba(30, 91, 191, 0.18); }
  50%      { box-shadow: 0 0 0 8px rgba(30, 91, 191, 0.08); }
}

.status-item div { flex: 1; }
.status-item strong { display: block; font-size: 0.95rem; color: var(--ink); margin-bottom: 2px; }
.status-item p { font-size: 0.85rem; color: var(--muted); margin: 0; }

.btn-pay {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding: 9px 20px;
  border-radius: 40px;
  border: none;
  background: linear-gradient(135deg, #6c5ce7, #a29bfe);
  color: #fff;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.25s, box-shadow 0.25s;
}
.btn-pay:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 6px 18px rgba(108, 92, 231, 0.35);
}
.btn-pay i { margin-right: 4px; }

.status-date {
  font-size: 0.8rem;
  color: var(--soft);
  white-space: nowrap;
  margin-top: 3px;
}

/* dark mode modal specifics */
[data-theme="dark"] .modal {
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.35),
              0 0 0 1px rgba(255, 255, 255, 0.04) inset;
}
[data-theme="dark"] .modal-overlay {
  background: rgba(2, 6, 18, 0.6);
}
[data-theme="dark"] .status-item.active .status-dot {
  box-shadow: 0 0 0 4px rgba(110, 168, 255, 0.2);
}

/* ── Auth pages ──────────────────────────────────────────────────────────── */
.auth-page {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 70vh;
  padding: 40px 16px;
}
.auth-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 48px 40px 40px;
  max-width: 440px;
  width: 100%;
  text-align: center;
  box-shadow: 0 12px 40px rgba(30, 91, 191, 0.08);
  animation: fadeSlideUp 0.4s ease;
}
.auth-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  color: #fff;
  font-size: 1.6rem;
}
.auth-card h1 {
  font-size: 1.6rem;
  font-weight: 800;
  margin: 0 0 6px;
  color: var(--ink);
}
.auth-card > p {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 0 0 28px;
}
.auth-error {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
  border-radius: 10px;
  padding: 10px 16px;
  font-size: 0.85rem;
  margin-bottom: 20px;
  text-align: left;
}
[data-theme="dark"] .auth-error {
  background: rgba(220, 38, 38, 0.12);
  border-color: rgba(220, 38, 38, 0.25);
  color: #fca5a5;
}
.auth-card .django-form {
  text-align: left;
}
.auth-card .django-form .form-group {
  margin-bottom: 18px;
}
.auth-card .django-form label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 6px;
}
.auth-card .django-form label i {
  width: 16px;
  text-align: center;
  margin-right: 4px;
  color: var(--brand);
}
.auth-card .form-input {
  width: 100%;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--input-bg);
  color: var(--ink);
  font-size: 0.95rem;
  box-sizing: border-box;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.auth-card .form-input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(30, 91, 191, 0.12);
}
.auth-card .form-actions {
  margin-top: 24px;
}
.auth-card .form-submit {
  width: 100%;
  padding: 14px;
  font-size: 1rem;
}
.auth-footer {
  margin-top: 24px;
  font-size: 0.9rem;
  color: var(--muted);
}
.auth-footer a {
  color: var(--brand);
  font-weight: 700;
  text-decoration: none;
}
.auth-footer a:hover {
  text-decoration: underline;
}
.field-error {
  display: block;
  color: #dc2626;
  font-size: 0.8rem;
  margin-top: 4px;
}
[data-theme="dark"] .field-error {
  color: #fca5a5;
}

/* ── Navbar auth buttons ─────────────────────────────────────────────────── */
.nav-user {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--brand);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.nav-user i {
  font-size: 1.1rem;
}
.btn-nav-register {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  border-radius: 40px;
  background: #10b981;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.25s, box-shadow 0.25s;
  white-space: nowrap;
}
.btn-nav-register:hover,
.btn-nav-register:active,
.btn-nav-register:focus {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 6px 18px rgba(16, 185, 129, 0.35);
  color: #fff !important;
}
.nav-logout-form {
  display: inline;
  margin: 0;
  padding: 0;
}
.nav-logout-form button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  padding: inherit;
}
[data-theme="dark"] .btn-nav-register {
  background: #34d399;
  color: #fff;
}

/* ── Password toggle ────────────────────────────────────────────────────── */
.password-toggle-wrap {
  position: relative;
}
.password-toggle-wrap .form-input {
  width: 100%;
  padding-right: 48px;
  box-sizing: border-box;
}
.password-toggle-btn {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--soft);
  font-size: 1rem;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
  transition: color 0.2s;
}
.password-toggle-btn:hover {
  color: var(--brand);
}
