/* ======================================================================
   License Estimator — Stylesheet
   Theme: dark navy + yellow accents (matches license.php)
   Fonts: Barlow Condensed (headings) + Inter (body)
   ====================================================================== */

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

:root {
  --navy: #07091a;
  --navy2: #0d1128;
  --navy3: #131730;
  --card: #0f1322;
  --yellow: #f5c800;
  --yellow2: #e6b800;
  --yellow3: #fdd83a;
  --offwhite: #f0efe9;
  --muted: #7a7f96;
  --border: rgba(245, 200, 0, 0.15);
  --border2: rgba(245, 200, 0, 0.08);
  --red: #ef4444;
  --green: #22c55e;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", sans-serif;
  background: var(--navy);
  color: var(--offwhite);
  font-size: 16px;
  line-height: 1.65;
  overflow-x: hidden;
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 5%;
  height: 64px;
  background: rgba(7, 9, 26, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border2);
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.nav-wordmark {
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 800;
  font-size: 1.3rem;
  color: var(--offwhite);
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.nav-wordmark span {
  color: var(--yellow);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  text-decoration: none;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover {
  color: var(--offwhite);
}

/* ── MAIN LAYOUT ── */
main {
  padding: 100px 5% 60px;
  max-width: 1200px;
  margin: 0 auto;
}

.page-title {
  font-family: "Barlow Condensed", sans-serif;
  font-size: clamp(2rem, 3.5vw, 3rem);
  font-weight: 800;
  text-transform: uppercase;
  line-height: 1;
  letter-spacing: -0.01em;
  margin-bottom: 0.5rem;
}

.page-title .accent {
  color: var(--yellow);
}

.page-sub {
  color: var(--muted);
  font-size: 1rem;
  margin-bottom: 2rem;
  line-height: 1.7;
  max-width: 720px;
}

/* ── ESTIMATOR GRID (desktop: side-by-side) ── */
.estimator-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}

/* ── INPUT PANEL ── */
.input-panel {
  background: var(--card);
  border: 1px solid var(--border2);
  border-radius: 12px;
  padding: 2rem;
}

.input-panel h2 {
  font-family: "Barlow Condensed", sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin-bottom: 1.5rem;
  color: var(--offwhite);
}

.form-group {
  display: flex;
  flex-direction: column;
  margin-bottom: 1.25rem;
}

.form-group label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 0.3rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.form-group .label-desc {
  font-size: 0.75rem;
  color: var(--muted);
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  margin-top: 0.15rem;
}

.form-group select,
.form-group input[type="number"] {
  width: 100%;
  padding: 10px 14px;
  background: var(--navy2);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--offwhite);
  font-size: 0.9rem;
  font-family: "Inter", sans-serif;
  transition: border-color 0.2s;
}

.form-group select:focus,
.form-group input[type="number"]:focus {
  outline: none;
  border-color: var(--yellow);
}

.form-group select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23f5c800' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}

.form-group select option {
  background: var(--navy2);
  color: var(--offwhite);
}

/* ── TOGGLE SWITCH ── */
.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.toggle-info {
  flex: 1;
}

.toggle-info .toggle-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.toggle-info .toggle-desc {
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 0.15rem;
}

.toggle-switch {
  position: relative;
  width: 48px;
  height: 26px;
  flex-shrink: 0;
  margin-left: 1rem;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--navy2);
  border: 1px solid var(--border);
  border-radius: 26px;
  transition:
    background 0.25s,
    border-color 0.25s;
}

.toggle-slider::before {
  content: "";
  position: absolute;
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background: var(--muted);
  border-radius: 50%;
  transition:
    transform 0.25s,
    background 0.25s;
}

.toggle-switch input:checked + .toggle-slider {
  background: var(--yellow);
  border-color: var(--yellow);
}

.toggle-switch input:checked + .toggle-slider::before {
  transform: translateX(22px);
  background: var(--navy);
}

/* Read-only indicator */
.readonly-indicator {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  padding: 0.75rem 1rem;
  background: var(--navy2);
  border: 1px solid var(--border2);
  border-radius: 6px;
}

.readonly-indicator .check-icon {
  color: var(--green);
  font-weight: 700;
  font-size: 1rem;
}

.readonly-indicator .readonly-label {
  font-size: 0.8rem;
  color: var(--muted);
  font-weight: 500;
}

/* ── RESULT PANEL ── */
.result-panel {
  background: var(--card);
  border: 2px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  position: sticky;
  top: 84px;
}

.result-panel h2 {
  font-family: "Barlow Condensed", sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin-bottom: 1.5rem;
  color: var(--offwhite);
}

/* Totals */
.total-card {
  background: var(--navy2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
  text-align: center;
}

.total-card .total-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 0.3rem;
}

.total-card .total-value {
  font-family: "Barlow Condensed", sans-serif;
  font-size: 2rem;
  font-weight: 800;
  color: var(--yellow);
}

.total-card .total-sub {
  font-size: 0.8rem;
  color: var(--navy);
  margin-top: 0.25rem;
}

.tco-card {
  background: var(--navy3);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
  text-align: center;
}

.tco-card .tco-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 0.3rem;
}

.tco-card .tco-value {
  font-family: "Barlow Condensed", sans-serif;
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--offwhite);
}

/* Breakdown table */
.breakdown {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.breakdown thead th {
  text-align: left;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--border2);
}

.breakdown tbody td {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border2);
  color: var(--offwhite);
}

.breakdown tbody td:last-child {
  text-align: right;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.breakdown .subtotal-row td {
  font-weight: 700;
  color: var(--yellow);
  border-top: 1px solid var(--border);
  padding-top: 0.75rem;
}

.breakdown .line-item-label {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 400;
}

/* ── TERMS SECTION ── */
.terms-section {
  margin-top: 3rem;
  padding: 2rem;
  background: var(--card);
  border: 1px solid var(--border2);
  border-radius: 12px;
  max-width: 100%;
}

.terms-section h2 {
  font-family: "Barlow Condensed", sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin-bottom: 1.25rem;
  color: var(--offwhite);
}

.terms-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 0.75rem;
}

.terms-list li {
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.6;
  padding-left: 1.25rem;
  position: relative;
}

.terms-list li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--yellow);
  font-weight: 700;
}

/* ── EMPTY STATE ── */
.empty-state {
  text-align: center;
  padding: 2rem 0;
  color: var(--muted);
  font-size: 0.9rem;
}

/* ── RESPONSIVE ── */
@media (max-width: 860px) {
  .estimator-grid {
    grid-template-columns: 1fr;
  }

  .result-panel {
    position: static;
  }

  .terms-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .input-panel,
  .result-panel {
    padding: 1.25rem;
  }

  .nav-links {
    gap: 1rem;
  }

  .total-card .total-value,
  .tco-card .tco-value {
    font-size: 1.6rem;
  }
}

/* ══════════════════════════════════════════════════════════════════
   INDUSTRY TOGGLE
   ══════════════════════════════════════════════════════════════════ */

.industry-toggle {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 2rem;
  margin-inline: auto;
  background: var(--card);
  border: 1px solid var(--border2);
  border-radius: 10px;
  padding: 0.35rem;
  max-width: fit-content;
}

.industry-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.6rem 1.25rem;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--muted);
  font-family: "Inter", sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition:
    background 0.2s,
    color 0.2s,
    border-color 0.2s;
  white-space: nowrap;
}

.industry-btn:hover {
  color: var(--offwhite);
  background: var(--navy2);
}

.industry-btn.active {
  background: var(--navy2);
  border-color: var(--border);
  color: var(--offwhite);
  font-weight: 600;
}

/* ══════════════════════════════════════════════════════════════════
   SIMPLIFIED RESULT — VOLUME DISPLAY
   ══════════════════════════════════════════════════════════════════ */

.volume-display {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 1.5rem;
  padding: 1rem;
  background: var(--navy2);
  border-radius: 8px;
  border: 1px solid var(--border2);
}

.volume-label {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 0.2rem;
}

.volume-value {
  font-family: "Barlow Condensed", sans-serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--offwhite);
}

/* ── Free tier badge ── */
.free-tier-badge {
  display: inline-block;
  margin-top: 0.35rem;
  padding: 0.15rem 0.75rem;
  background: var(--green);
  color: var(--navy);
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ── Add-on note (free tier premium support) ── */
.addon-note {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.85rem 1rem;
  background: var(--navy2);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 1.25rem;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.5;
}

.addon-note .addon-icon {
  color: var(--yellow);
  font-size: 1rem;
  flex-shrink: 0;
  margin-top: 0.05rem;
}

/* ══════════════════════════════════════════════════════════════════
   INCLUDED CHECKLIST
   ══════════════════════════════════════════════════════════════════ */

.included-checklist {
  margin-top: 0.5rem;
}

.included-checklist h3 {
  font-family: "Barlow Condensed", sans-serif;
  font-size: 1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--offwhite);
  margin-bottom: 0.75rem;
}

.checklist {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.checklist li {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  font-size: 0.82rem;
  background: var(--navy2);
  border: 1px solid var(--border2);
}

.checklist .check-icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 0.7rem;
  font-weight: 700;
}

.check-included .check-icon {
  background: rgba(34, 197, 94, 0.15);
  color: var(--green);
}

.check-addon .check-icon {
  background: rgba(245, 200, 0, 0.15);
  color: var(--yellow);
}

.checklist .check-label {
  flex: 1;
  color: var(--offwhite);
  font-weight: 500;
}

.checklist .check-value {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.78rem;
  text-align: right;
  white-space: nowrap;
}

.check-addon .check-label {
  color: var(--muted);
}

/* ══════════════════════════════════════════════════════════════════
   RESPONSIVE — INDUSTRY TOGGLE
   ══════════════════════════════════════════════════════════════════ */

@media (max-width: 600px) {
  .industry-toggle {
    max-width: 100%;
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
  }

  .industry-btn {
    padding: 0.5rem 0.9rem;
    font-size: 0.78rem;
  }

  .checklist .check-value {
    font-size: 0.72rem;
  }
}
