/* ===================================================================
   Citinet Billing System — brand stylesheet
   Extends the CitiNET hotspot portal's visual language (style.css)
   to a full multi-page site: same navy gradient, orange CTAs, white
   rounded cards, pill badges, and plan-grid tiles — just with a
   navbar/footer/pagination wrapper around it instead of a single
   floating hotspot-card.
   =================================================================== */

*, *::before, *::after { box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  background: #f3f6f8;
  color: #111827;
  line-height: 1.5;
  margin: 0;
}

a { color: #1C4E6F; }

/* ── Top nav — dark navy, same brand-icon treatment as the hotspot card ── */
.citi-nav {
  background: #0B2A3B;
  padding: 14px 0;
}
.citi-nav .citi-nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.citi-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font-weight: 700;
  font-size: 18px;
  text-decoration: none;
}
.citi-nav-links { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.citi-nav-links a { color: #cbd5e1; text-decoration: none; font-size: 14px; font-weight: 600; }
.citi-nav-links a:hover { color: #fff; }

/* ── Buttons — orange primary, dark-navy secondary, pill radius ── */
.btn-citi {
  display: inline-block;
  padding: 13px 22px;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: background .15s, transform .1s, opacity .15s;
  min-height: 48px;
  line-height: 1.4;
}
.btn-citi:active { transform: scale(.98); }
.btn-citi-primary { background: #f97316; color: #fff; }
.btn-citi-primary:hover { background: #ea580c; color: #fff; }
.btn-citi-secondary { background: #374151; color: #fff; }
.btn-citi-secondary:hover { background: #1f2937; color: #fff; }
.btn-citi-outline { background: transparent; color: #f97316; border: 2px solid #f97316; padding: 11px 20px; }
.btn-citi-outline:hover { background: #fff7ed; }
.btn-citi-sm { padding: 8px 16px; font-size: 13px; min-height: auto; border-radius: 10px; }
.btn-citi:disabled, .btn-citi.loading { opacity: .65; cursor: not-allowed; transform: none; }

/* ── Hero — same navy-to-teal gradient as the captive portal background ── */
.citi-hero {
  background: linear-gradient(150deg, #0B2A3B 0%, #1C4E6F 100%);
  color: #fff;
  padding: 64px 20px;
  text-align: center;
}
.citi-hero h1 { font-size: 32px; font-weight: 800; letter-spacing: -0.5px; margin: 0 0 12px; }
.citi-hero p { font-size: 16px; color: #dbeafe; max-width: 520px; margin: 0 auto 24px; }

/* ── White rounded cards — matches .hotspot-card exactly ── */
.citi-card {
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(0,0,0,.10);
  overflow: hidden;
}
.citi-card-body { padding: 24px 20px; }

/* ── Pricing grid — explicit column counts instead of relying on auto-fit, which
   with a 180px minimum collapses to a single column on most phones (7 packages =
   7 full-width rows = exactly the "too much scrolling" problem). Guarantees at
   least 2 columns even on narrow screens, more as the screen grows. ── */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.pricing-card { background: #fff; border-radius: 16px; box-shadow: 0 4px 16px rgba(0,0,0,.08); padding: 14px 12px; text-align: center; display: flex; flex-direction: column; }
.pricing-card .plan-name { font-size: 14px; font-weight: 700; color: #374151; margin-bottom: 2px; }
.pricing-card .plan-sub { font-size: 10.5px; color: #9ca3af; margin-bottom: 8px; }
.pricing-card .plan-desc { font-size: 11px; color: #6b7280; margin-bottom: 8px; line-height: 1.4; }
.pricing-card .plan-price { font-size: 17px; font-weight: 800; color: #ea580c; margin-bottom: 10px; }
.pricing-card .btn-citi { margin-top: auto; }

@media (min-width: 480px) {
  .pricing-grid { grid-template-columns: repeat(3, 1fr); gap: 12px; }
}
@media (min-width: 700px) {
  .pricing-grid { grid-template-columns: repeat(4, 1fr); }
  .pricing-card { padding: 18px 14px; }
  .pricing-card .plan-name { font-size: 16px; }
  .pricing-card .plan-sub { font-size: 11px; }
  .pricing-card .plan-desc { font-size: 12px; }
  .pricing-card .plan-price { font-size: 20px; }
}

/* ── Plan grid — same tile treatment as the hotspot login page ── */
.grid-plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
}
.plan-item {
  background: #fff7ed;
  border: 2px solid transparent;
  border-radius: 14px;
  padding: 16px 10px;
  text-align: center;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  transition: border-color .15s, transform .1s;
  min-height: 110px;
  justify-content: center;
}
.plan-item:hover, .plan-item:focus { border-color: #ea580c; outline: none; transform: translateY(-2px); }
.plan-item:active { transform: scale(.97); border-color: #ea580c; }
.plan-name { font-size: 14px; font-weight: 700; color: #374151; }
.plan-sub { font-size: 11px; color: #9ca3af; }
.plan-price { font-size: 18px; font-weight: 800; color: #ea580c; }
.plan-cta { background: #ea580c; color: #fff; font-size: 11px; font-weight: 700; padding: 4px 12px; border-radius: 20px; margin-top: 2px; }

/* ── Pills / badges — same rounded-pill info style as the portal ── */
.pill { display: inline-block; font-size: 12px; font-weight: 700; padding: 5px 14px; border-radius: 20px; }
.pill-success { background: #f0fdf4; color: #166534; border: 1.5px solid #86efac; }
.pill-warning { background: #fef9c3; color: #854d0e; }
.pill-danger  { background: #fef2f2; color: #b91c1c; border: 1.5px solid #fca5a5; }
.pill-neutral { background: #f3f4f6; color: #374151; }
.pill-info    { background: #eff6ff; color: #1C4E6F; }

/* ── Support links — WhatsApp green / Telegram pill, straight from the portal footer ── */
.support-links { text-align: center; padding-top: 16px; border-top: 1px solid #f3f4f6; margin-top: 20px; }
.whatsapp-link, .support-link {
  display: inline-block; font-size: 13px; font-weight: 700; text-decoration: none;
  padding: 10px 20px; border-radius: 20px; margin: 0 6px 10px;
}
.whatsapp-link { background: #25D366; color: #fff; }
.whatsapp-link:hover { background: #1ebe5b; }
.support-link { background: #eff6ff; color: #1C4E6F; }
.support-link:hover { background: #dbeafe; }
.citipay-box {
  display: flex; align-items: center; gap: 12px; background: #eff8ff;
  border: 1.5px solid #93c5fd; border-radius: 14px; padding: 14px;
  text-decoration: none; color: inherit; transition: border-color .15s, background .15s;
}
.citipay-box:hover { background: #dbeafe; border-color: #3b82f6; }

/* ── Trial-style green callout — reused for "why choose us" / active voucher ── */
.callout-green {
  background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
  border: 2px solid #6ee7b7;
  border-radius: 16px;
  padding: 18px;
}
.callout-green .callout-badge {
  background: #059669; color: #fff; font-size: 10px; font-weight: 800;
  padding: 3px 8px; border-radius: 20px; letter-spacing: .8px; margin-right: 8px;
}
.callout-green h3 { color: #065f46; font-size: 16px; margin: 0 0 6px; display: inline; }
.callout-green p { color: #047857; font-size: 13px; margin: 8px 0 0; }

/* ── Info rows — used on receipts/status views, same style as alogin/status.html ── */
.info-rows { display: flex; flex-direction: column; gap: 10px; }
.info-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.info-label { font-size: 12px; font-weight: 700; color: #6b7280; min-width: 130px; flex-shrink: 0; }
.info-value { font-size: 13px; color: #111827; background: #f3f4f6; padding: 5px 12px; border-radius: 20px; }
.info-value code { background: none; }

/* ── Footer ── */
.citi-footer { background: #0B2A3B; color: #b8c4d9; padding: 40px 20px 24px; margin-top: 48px; }
.citi-footer .citi-footer-inner { max-width: 1100px; margin: 0 auto; }
.citi-footer h6 { color: #fff; font-size: 14px; margin-bottom: 10px; }
.citi-footer a { color: #b8c4d9; font-size: 13px; text-decoration: none; }
.citi-footer a:hover { color: #fff; }
.citi-footer ul { list-style: none; padding: 0; margin: 0; }
.citi-footer li { margin-bottom: 6px; }
.citi-footer hr { border-color: #1C4E6F; margin: 24px 0 16px; }
.citi-footer .footnote { font-size: 12px; color: #6b8299; text-align: center; }

/* ── Section spacing helpers ── */
.citi-section { max-width: 1100px; margin: 0 auto; padding: 48px 20px; }
.citi-section h2 { text-align: center; font-size: 24px; font-weight: 800; color: #0B2A3B; margin-bottom: 28px; }

/* ── Admin panel — dark navy sidebar to match brand, orange as the one accent ── */
.admin-sidebar { background: #0B2A3B; min-height: 100vh; width: 230px; flex-shrink: 0; }
.admin-sidebar a { color: #b8c4d9; text-decoration: none; display: block; padding: .6rem 1.2rem; border-radius: 10px; font-size: 14px; font-weight: 600; }
.admin-sidebar a:hover, .admin-sidebar a.active { background: #f97316; color: #fff; }
.admin-sidebar .brand { color: #fff; font-weight: 700; padding: 1.2rem; display: flex; align-items: center; gap: 8px; }
.admin-main { flex: 1; padding: 24px; background: #f3f6f8; min-height: 100vh; min-width: 0; }
.stat-card { background: #fff; border-radius: 16px; padding: 18px; box-shadow: 0 4px 16px rgba(0,0,0,.06); }
.stat-card .stat-label { font-size: 13px; color: #6b7280; margin-bottom: 4px; }
.stat-card .stat-value { font-size: 26px; font-weight: 800; color: #0B2A3B; }

/* ── Admin mobile nav — hidden entirely on desktop, this is what turns the fixed
   230px sidebar into a slide-out drawer on small screens instead of forcing the
   whole page wider than the viewport (the pinch-zoom symptom). ── */
.admin-mobile-bar { display: none; }
.admin-overlay { display: none; }

@media (max-width: 860px) {
  .admin-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 1000;
    transform: translateX(-100%);
    transition: transform .25s ease;
    box-shadow: 4px 0 24px rgba(0,0,0,.2);
    overflow-y: auto;
  }
  .admin-sidebar.open { transform: translateX(0); }

  .admin-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.45);
    z-index: 999;
  }
  .admin-overlay.show { display: block; }

  .admin-main { padding: 16px; }

  .admin-mobile-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #0B2A3B;
    padding: 12px 16px;
    margin: -16px -16px 16px -16px;
    position: sticky;
    top: 0;
    z-index: 500;
  }
  .admin-mobile-bar button {
    background: none;
    border: none;
    color: #fff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    padding: 4px 8px;
  }
  .admin-mobile-bar .brand-mini { color: #fff; font-weight: 700; font-size: 15px; }

  /* Stat cards and the stock matrix were laid out assuming desktop width —
     force them to stack/scroll instead of squeezing until text overlaps. */
  .stat-card { min-width: 0; }
}

