/* =============================================================
   IDZIK.pl – Main Stylesheet
   Design: Dark/Futuristic, Pink/Purple accent
   ============================================================= */

:root {
  --bg-dark:        #04051a;
  --bg-card:        rgba(255,255,255,0.04);
  --bg-card-hover:  rgba(255,255,255,0.08);
  --primary:        #7c3aed;
  --primary-hover:  #6d28d9;
  --secondary:      #3b82f6;
  --secondary-hover:#2563eb;
  --gradient:       linear-gradient(135deg, #7c3aed, #3b82f6);
  --gradient-subtle:linear-gradient(135deg, rgba(124,58,237,0.15), rgba(59,130,246,0.15));
  --text-primary:   #ffffff;
  --text-secondary: rgba(255,255,255,0.65);
  --text-muted:     rgba(255,255,255,0.40);
  --border:         rgba(255,255,255,0.08);
  --border-primary: rgba(124,58,237,0.4);
  --shadow:         0 20px 60px rgba(0,0,0,0.5);
  --shadow-primary: 0 0 30px rgba(124,58,237,0.3);
  --radius:         16px;
  --radius-sm:      10px;
  --radius-lg:      24px;
  --transition:     all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Material Symbols */
.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  vertical-align: middle;
  line-height: 1;
  user-select: none;
}
.icon-fill { font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24; }
.icon-sm { font-size: 1.1rem; }
.icon-md { font-size: 1.5rem; }
.icon-lg { font-size: 2rem; }
.icon-xl { font-size: 2.5rem; }

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; }
a { text-decoration: none; color: inherit; }

/* ── Typography ────────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  overflow-wrap: break-word;
  word-break: break-word;
  /* Prevent orphan words in headings – balances line lengths */
  text-wrap: balance;
}
h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.5rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.5rem); }
p {
  overflow-wrap: break-word;
  /* Avoid single words stranded on last line */
  text-wrap: pretty;
}
li, td, th, label {
  overflow-wrap: break-word;
}

.text-gradient {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.text-muted { color: var(--text-secondary); }

/* ── Layout ────────────────────────────────────────────────── */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}
.section {
  padding: 5rem 0;
}
.section-title {
  text-align: center;
  margin-bottom: 1rem;
}
.section-subtitle {
  text-align: center;
  color: var(--text-secondary);
  font-size: 1.1rem;
  margin-bottom: 3.5rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}
.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: 1.5rem;
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

/* ── Navbar ────────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  padding: 1rem 0;
  transition: var(--transition);
  backdrop-filter: blur(0px);
}
.navbar.scrolled {
  background: rgba(5,5,26,0.92);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 0.75rem 0;
}
.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.navbar-brand {
  display: flex;
  flex-direction: column;
  line-height: 1;
}
.navbar-logo {
  font-size: 1.8rem;
  font-weight: 900;
  letter-spacing: -0.05em;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.navbar-logo img {
  height: 40px;
  width: auto;
}
.navbar-powered {
  font-size: 0.65rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-top: 2px;
}
.navbar-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  list-style: none;
}
.navbar-nav a {
  display: block;
  padding: 0.5rem 0.9rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: var(--transition);
}
.navbar-nav a:hover, .navbar-nav a.active {
  color: var(--text-primary);
  background: rgba(255,255,255,0.06);
}
.navbar-nav .nav-disabled a {
  opacity: 0.4;
  cursor: not-allowed;
  pointer-events: none;
}
.navbar-nav .nav-cta a {
  background: var(--gradient);
  color: #fff;
  padding: 0.5rem 1.2rem;
  display: flex;
  align-items: center;
  gap: .25rem;
}
.navbar-nav .nav-cta a:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}
.navbar-nav .nav-mail a {
  background: linear-gradient(135deg, #0f766e, #059669) !important;
  color: #fff;
  padding: 0.5rem 1.2rem;
  display: flex;
  align-items: center;
  gap: .25rem;
}
.navbar-nav .nav-mail a:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}
.navbar-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 5px;
  background: none;
  border: none;
}
.navbar-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition);
}

/* ── Hero ──────────────────────────────────────────────────── */
.hero {
  min-height: 92vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding: 7rem 0 2rem;
}
.hero-bg {
  position: absolute;
  /* Starts 5px below navbar bottom, not behind it */
  top: 79px; /* navbar ~74px + 5px gap */
  left: 0; right: 0; bottom: 0;
  background: url('/assets/images/hero-bg.svg') 50% 50% / cover no-repeat;
  z-index: 0;
  /* opacity and background-position overridden inline from DB settings */
}
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(4,5,26,0.35) 0%, var(--bg-dark) 100%),
              linear-gradient(135deg, rgba(124,58,237,0.15) 0%, rgba(59,130,246,0.1) 100%);
}
.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
}
.hero-orb-1 {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(124,58,237,0.2) 0%, transparent 70%);
  top: -200px;
  right: -100px;
  animation: orbFloat 8s ease-in-out infinite;
}
.hero-orb-2 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(59,130,246,0.2) 0%, transparent 70%);
  bottom: 0;
  left: -50px;
  animation: orbFloat 10s ease-in-out infinite reverse;
}
@keyframes orbFloat {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-30px) scale(1.05); }
}
.hero-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1rem;
  background: rgba(124,58,237,0.15);
  border: 1px solid rgba(124,58,237,0.3);
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}
.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 900;
  margin-bottom: 1.5rem;
  line-height: 1.1;
}
.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
  max-width: 560px;
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}
.hero-stats {
  display: flex;
  gap: 2.5rem;
  flex-wrap: wrap;
}
.hero-stat {
  display: flex;
  flex-direction: column;
}
.hero-stat-value {
  font-size: 1.8rem;
  font-weight: 800;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}
.hero-stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
}

/* ── Buttons ───────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  border-radius: 50px;
  font-size: 0.95rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
  white-space: nowrap;
}
.btn-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: 0 4px 20px rgba(124,58,237,0.4);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(124,58,237,0.5);
}
.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(124,58,237,0.05);
}
.btn-secondary {
  background: rgba(255,255,255,0.08);
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.btn-secondary:hover {
  background: rgba(255,255,255,0.12);
}
.btn-sm {
  padding: 0.5rem 1.2rem;
  font-size: 0.85rem;
}
.btn-lg {
  padding: 1rem 2.5rem;
  font-size: 1.05rem;
}

/* ── Cards ─────────────────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  transition: var(--transition);
}
.card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(255,255,255,0.12);
  transform: translateY(-4px);
}

/* ── Package Cards ─────────────────────────────────────────── */
.packages-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  align-items: start;
}
.package-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  position: relative;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}
.package-card:hover {
  border-color: rgba(124,58,237,0.3);
  transform: translateY(-6px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}
.package-card.highlighted {
  border-color: var(--primary);
  background: rgba(124,58,237,0.06);
  transform: scale(1.03);
  box-shadow: var(--shadow-primary);
}
.package-card.highlighted:hover {
  transform: scale(1.03) translateY(-6px);
}
.package-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gradient);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.3rem 1rem;
  border-radius: 50px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
}
.package-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--gradient-subtle);
  border: 1px solid var(--border-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  font-size: 1.5rem;
}
.package-name {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 0.25rem;
}
.package-speed {
  font-size: 2.5rem;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 0.25rem;
}
.package-speed-sub {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
}
.package-price {
  font-size: 2.2rem;
  font-weight: 800;
  margin: 1rem 0;
  line-height: 1;
}
.package-price-sub {
  font-size: 0.85rem;
  color: var(--text-secondary);
}
.package-desc {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  min-height: 40px;
}
.package-features {
  list-style: none;
  margin-bottom: 2rem;
  flex: 1;
}
.package-features li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.45rem 0;
  font-size: 0.9rem;
  border-bottom: 1px solid var(--border);
}
.package-features li:last-child { border-bottom: none; }
.package-features li::before {
  content: '✓';
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(124,58,237,0.15);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
}
.package-cta { margin-top: auto; }

/* ── Coverage Section ──────────────────────────────────────── */
.coverage-search {
  max-width: 600px;
  margin: 0 auto 3rem;
}
.coverage-input-wrap {
  display: flex;
  gap: 0;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  border-radius: 50px;
  overflow: hidden;
  transition: var(--transition);
}
.coverage-input-wrap:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(124,58,237,0.1);
}
.coverage-input {
  flex: 1;
  background: none;
  border: none;
  padding: 1rem 1.5rem;
  color: var(--text-primary);
  font-size: 0.95rem;
  outline: none;
}
.coverage-input::placeholder { color: var(--text-muted); }
.coverage-btn {
  background: var(--gradient);
  color: #fff;
  border: none;
  padding: 0.75rem 1.75rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: 0 50px 50px 0;
  transition: var(--transition);
  white-space: nowrap;
}
.coverage-btn:hover { opacity: 0.9; }
.coverage-result {
  margin-top: 1rem;
  padding: 1rem 1.5rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  text-align: center;
  display: none;
}
.coverage-result.covered {
  background: rgba(34,197,94,0.1);
  border: 1px solid rgba(34,197,94,0.3);
  color: #22c55e;
  display: block;
}
.coverage-result.not-covered {
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.3);
  color: #ef4444;
  display: block;
}
.coverage-locations {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}
.coverage-location {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}
.coverage-location-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
  color: #fff;
}

/* ── FAQ ───────────────────────────────────────────────────── */
.faq-list { max-width: 800px; margin: 0 auto; }
.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 0.75rem;
  overflow: hidden;
  transition: var(--transition);
}
.faq-item.open { border-color: var(--border-primary); }
.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 1.5rem;
  cursor: pointer;
  font-weight: 600;
  gap: 1rem;
  background: var(--bg-card);
  transition: var(--transition);
  user-select: none;
}
.faq-question:hover { background: var(--bg-card-hover); }
.faq-item.open .faq-question { background: rgba(124,58,237,0.08); }
.faq-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  color: var(--primary);
  flex-shrink: 0;
  transition: var(--transition);
}
.faq-item.open .faq-icon { transform: rotate(45deg); border-color: var(--primary); background: rgba(124,58,237,0.1); }
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4,0,0.2,1), padding 0.3s;
  padding: 0 1.5rem;
  color: var(--text-secondary);
  line-height: 1.7;
}
.faq-answer.open {
  max-height: 800px;
  padding: 1.25rem 1.5rem;
}
.faq-answer ul, .faq-answer ol { padding-left: 1.5rem; margin: 0.5rem 0; }
.faq-answer li { margin-bottom: 0.3rem; }
.faq-answer strong { color: var(--text-primary); }
.faq-answer a { color: var(--primary); }
.faq-categories {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
  justify-content: center;
}
.faq-cat-btn {
  padding: 0.4rem 1rem;
  border-radius: 50px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 500;
  transition: var(--transition);
}
.faq-cat-btn.active, .faq-cat-btn:hover {
  background: rgba(124,58,237,0.1);
  border-color: var(--border-primary);
  color: var(--primary);
}

/* ── Contact Form ──────────────────────────────────────────── */
.contact-form { max-width: 700px; margin: 0 auto; }
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.form-group {
  margin-bottom: 1.25rem;
  position: relative;
}
.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
  letter-spacing: 0.02em;
}
.form-control {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1.1rem;
  color: var(--text-primary);
  font-size: 0.95rem;
  outline: none;
  transition: var(--transition);
  font-family: inherit;
}
.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(124,58,237,0.1);
  background: rgba(255,255,255,0.06);
}
.form-control::placeholder { color: var(--text-muted); }
textarea.form-control { resize: vertical; min-height: 130px; }
.form-alert {
  padding: 1rem 1.25rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1.5rem;
  font-weight: 500;
  display: none;
}
.form-alert.success { background: rgba(34,197,94,0.1); border: 1px solid rgba(34,197,94,0.3); color: #22c55e; display: block; }
.form-alert.error   { background: rgba(239,68,68,0.1); border: 1px solid rgba(239,68,68,0.3); color: #ef4444; display: block; }

/* ── Contact Info ──────────────────────────────────────────── */
.contact-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}
.contact-info-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.contact-info-icon {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: var(--gradient-subtle);
  border: 1px solid var(--border-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}
.contact-info-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.2rem;
}
.contact-info-value {
  font-weight: 600;
  font-size: 1.05rem;
}
.contact-info-value a { color: inherit; }
.contact-info-value a:hover { color: var(--primary); }

/* ── Features/Perks ────────────────────────────────────────── */
.perks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr));
  gap: 1.25rem;
}
.perk-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  text-align: center;
  transition: var(--transition);
}
.perk-card:hover {
  border-color: var(--border-primary);
  background: rgba(124,58,237,0.04);
}
.perk-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
}
.perk-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}
.perk-desc {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

/* ── CTA Banner ────────────────────────────────────────────── */
.cta-banner {
  background: var(--gradient);
  border-radius: var(--radius-lg);
  padding: 4rem 2rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.cta-banner h2, .cta-banner p { position: relative; }
.cta-banner h2 { font-size: clamp(1.8rem, 3vw, 2.5rem); margin-bottom: 1rem; }
.cta-banner p { opacity: 0.9; font-size: 1.1rem; margin-bottom: 2rem; max-width: 600px; margin-left: auto; margin-right: auto; }
.cta-banner .btn-white {
  background: #fff;
  color: var(--primary);
  box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}
.cta-banner .btn-white:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(0,0,0,0.3); }

/* ── Footer ────────────────────────────────────────────────── */
.footer {
  background: rgba(0,0,0,0.4);
  border-top: 1px solid var(--border);
  padding: 4rem 0 2rem;
  margin-top: 5rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}
.footer-brand .footer-logo {
  font-size: 2rem;
  font-weight: 900;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.25rem;
}
.footer-brand .footer-powered {
  font-size: 0.7rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.footer-desc {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  margin-bottom: 1.5rem;
}
.footer-social {
  display: flex;
  gap: 0.75rem;
}
.footer-social a {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: var(--transition);
}
.footer-social a:hover {
  border-color: var(--primary);
  background: rgba(124,58,237,0.1);
}
.footer-col-title {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}
.footer-links {
  list-style: none;
}
.footer-links li { margin-bottom: 0.6rem; }
.footer-links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  transition: var(--transition);
}
.footer-links a:hover { color: var(--primary); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.footer-copyright {
  color: var(--text-muted);
  font-size: 0.85rem;
}
.footer-partner {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}
.footer-partner strong { color: var(--text-secondary); }

/* ── Modal ─────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(8px);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.modal-overlay.open { display: flex; }
.modal {
  background: #0d0d2b;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  max-width: 520px;
  width: 100%;
  padding: 2.5rem;
  position: relative;
  animation: modalIn 0.3s ease;
}
@keyframes modalIn {
  from { opacity: 0; transform: translateY(20px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.2rem;
  color: var(--text-secondary);
  transition: var(--transition);
}
.modal-close:hover { color: var(--text-primary); border-color: var(--primary); }
.modal-title { font-size: 1.4rem; margin-bottom: 0.5rem; }
.modal-subtitle { color: var(--text-secondary); font-size: 0.9rem; margin-bottom: 2rem; }

/* ── Page Header ───────────────────────────────────────────── */
.page-header {
  background: linear-gradient(to bottom, rgba(124,58,237,0.08), transparent);
  border-bottom: 1px solid var(--border);
  padding: 9rem 0 4rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.page-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center top, rgba(59,130,246,0.15), transparent 70%);
}
.page-header .container { position: relative; }
.page-header h1 { margin-bottom: 1rem; }
.page-header p { color: var(--text-secondary); font-size: 1.1rem; max-width: 600px; margin: 0 auto; }
.breadcrumb {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}
.breadcrumb a { color: var(--primary); }
.breadcrumb .sep { opacity: 0.4; }

/* ── Coming Soon ───────────────────────────────────────────── */
.coming-soon {
  text-align: center;
  padding: 5rem 0;
}
.coming-soon-icon {
  font-size: 4rem;
  margin-bottom: 1.5rem;
  opacity: 0.6;
}
.coming-soon h2 { margin-bottom: 1rem; }
.coming-soon p { color: var(--text-secondary); max-width: 500px; margin: 0 auto 2rem; }

/* ── Client Panel ──────────────────────────────────────────── */
.client-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  min-height: calc(100vh - 80px);
  gap: 0;
}
.client-sidebar {
  background: rgba(255,255,255,0.02);
  border-right: 1px solid var(--border);
  padding: 2rem 1rem;
}
.client-sidebar-nav { list-style: none; }
.client-sidebar-nav li { margin-bottom: 0.25rem; }
.client-sidebar-nav a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  transition: var(--transition);
}
.client-sidebar-nav a:hover, .client-sidebar-nav a.active {
  background: rgba(124,58,237,0.1);
  color: var(--primary);
}
.client-main { padding: 2rem; }
.client-welcome { margin-bottom: 2rem; }
.client-welcome h1 { font-size: 1.8rem; margin-bottom: 0.25rem; }
.client-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}
.client-stat {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.client-stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
}
.client-stat-value {
  font-size: 1.6rem;
  font-weight: 800;
}
.client-stat-value.negative { color: #ef4444; }
.client-stat-value.positive { color: #22c55e; }
.invoice-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.invoice-table th {
  text-align: left;
  padding: 0.75rem 1rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
}
.invoice-table td {
  padding: 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}
.invoice-table tr:last-child td { border-bottom: none; }
.badge-status {
  padding: 0.2rem 0.75rem;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
}
.badge-status.paid   { background: rgba(34,197,94,0.1); color: #22c55e; }
.badge-status.pending { background: rgba(251,191,36,0.1); color: #fbbf24; }
.badge-status.overdue { background: rgba(239,68,68,0.1); color: #ef4444; }

/* ── Admin Panel ───────────────────────────────────────────── */
.admin-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  min-height: 100vh;
}
.admin-sidebar {
  background: #07071e;
  border-right: 1px solid var(--border);
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}
.admin-sidebar-header {
  padding: 1.5rem;
  border-bottom: 1px solid var(--border);
}
.admin-sidebar-logo {
  font-size: 1.5rem;
  font-weight: 900;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.admin-sidebar-sub {
  font-size: 0.65rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.admin-nav { padding: 1rem 0; list-style: none; }
.admin-nav-section {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 1rem 1.5rem 0.5rem;
}
.admin-nav a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 1.5rem;
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
  transition: var(--transition);
}
.admin-nav a:hover, .admin-nav a.active {
  background: rgba(124,58,237,0.08);
  color: var(--primary);
  border-right: 2px solid var(--primary);
}
.admin-main { padding: 0; }
.admin-topbar {
  background: #07071e;
  border-bottom: 1px solid var(--border);
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
}
.admin-topbar-title { font-size: 1.1rem; font-weight: 700; }
.admin-content { padding: 2rem; }
.admin-card {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}
.admin-card-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}
.admin-table th {
  text-align: left;
  padding: 0.75rem 1rem;
  background: rgba(255,255,255,0.03);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}
.admin-table td {
  padding: 0.875rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
  vertical-align: middle;
}
.admin-table tr:hover td { background: rgba(255,255,255,0.02); }
.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}
.admin-stat {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
}
.admin-stat-value { font-size: 1.8rem; font-weight: 800; }
.admin-stat-label { font-size: 0.75rem; color: var(--text-muted); margin-top: 0.25rem; }

/* ── Login pages ───────────────────────────────────────────── */
.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  position: relative;
  overflow: hidden;
}
.login-bg {
  position: fixed;
  inset: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(124,58,237,0.15), transparent 60%),
              radial-gradient(ellipse at 70% 50%, rgba(59,130,246,0.15), transparent 60%);
  z-index: -1;
}
.login-card {
  background: rgba(13,13,43,0.95);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 3rem;
  width: 100%;
  max-width: 420px;
  backdrop-filter: blur(20px);
}
.login-logo {
  text-align: center;
  margin-bottom: 2rem;
}
.login-logo .logo-text {
  font-size: 2.5rem;
  font-weight: 900;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}
.login-logo .logo-sub { font-size: 0.7rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.1em; margin-top: 2px; }
.login-title { font-size: 1.3rem; font-weight: 700; margin-bottom: 0.5rem; }
.login-sub { color: var(--text-secondary); font-size: 0.9rem; margin-bottom: 2rem; }
.form-icon-wrap { position: relative; }
.form-icon-wrap .form-control { padding-left: 2.75rem; }
.form-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 1rem;
}

/* ── Scrollbar ─────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(124,58,237,0.4); }

/* ── Divider ───────────────────────────────────────────────── */
.divider {
  height: 1px;
  background: var(--border);
  margin: 3rem 0;
}
.divider-gradient {
  height: 1px;
  background: linear-gradient(to right, transparent, var(--primary), transparent);
  margin: 3rem 0;
}

/* ── Animations ────────────────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-in-up { animation: fadeInUp 0.6s ease forwards; }
.fade-in-up-delay-1 { animation-delay: 0.1s; opacity: 0; }
.fade-in-up-delay-2 { animation-delay: 0.2s; opacity: 0; }
.fade-in-up-delay-3 { animation-delay: 0.3s; opacity: 0; }

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .contact-info-grid { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .navbar-nav {
    position: fixed;
    top: 70px;
    left: 0; right: 0;
    background: rgba(5,5,26,0.98);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 1rem;
    gap: 0;
    display: none;
  }
  .navbar-nav.open { display: flex; }
  .navbar-toggle { display: flex; }
  .hero-stats { gap: 1.5rem; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
  .client-layout { grid-template-columns: 1fr; }
  .client-sidebar { display: none; }
  .admin-layout { grid-template-columns: 1fr; }
  .admin-sidebar { display: none; }
  .packages-grid { grid-template-columns: 1fr; }
  .package-card.highlighted { transform: none; }
  .package-card.highlighted:hover { transform: translateY(-6px); }
}
@media (max-width: 480px) {
  .hero-actions { flex-direction: column; align-items: flex-start; }
  .cta-banner { padding: 3rem 1.5rem; }
  .login-card { padding: 2rem; }
  .modal { padding: 1.75rem; }
  /* Prevent any element from busting out of viewport */
  .container { padding: 0 1rem; }
  .section { padding: 3.5rem 0; }
  .page-header { padding: 7rem 0 3rem; }
  h1 { font-size: clamp(1.7rem, 8vw, 2.5rem); }
}

/* ── Global overflow guard ─────────────────────────────────── */
html, body { max-width: 100%; overflow-x: hidden; }
/* Ensure no child element wider than viewport */
section, footer, .page-header, .navbar { max-width: 100vw; overflow-x: hidden; }
/* Table overflow on mobile */
.admin-table-wrap, .invoice-table { overflow-x: auto; display: block; }
.admin-table, .invoice-table { display: table; min-width: 500px; }
@media (max-width: 768px) {
  /* Navbar buttons stack on mobile */
  .navbar-nav .nav-cta a { white-space: nowrap; }
  /* Footer: no fixed widths */
  .footer-grid > div { min-width: 0; }
}

/* ── Utility ───────────────────────────────────────────────── */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.hidden { display: none !important; }
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.w-full { width: 100%; }
.spinner {
  display: inline-block;
  width: 20px; height: 20px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
