@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;1,9..40,300&display=swap');

:root {
  --tx-red: #BF2012;
  --tx-red-dark: #8C160D;
  --tx-red-light: #F5E6E4;
  --tx-blue: #003087;
  --tx-blue-light: #E6ECF8;
  --tx-gold: #D4A017;
  --tx-gold-light: #FBF4E0;
  --bg: #F8F6F1;
  --surface: #FFFFFF;
  --border: #E2DDD4;
  --text-primary: #1A1714;
  --text-secondary: #5C5750;
  --text-muted: #918B83;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08), 0 2px 6px rgba(0,0,0,0.04);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.1), 0 4px 12px rgba(0,0,0,0.06);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5 {
  font-family: 'Syne', sans-serif;
  line-height: 1.2;
  color: var(--text-primary);
}

a { color: var(--tx-red); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── NAV ── */
.site-nav {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

.nav-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-family: 'Syne', sans-serif;
  font-size: 18px;
  font-weight: 800;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}

.nav-logo span.star {
  color: var(--tx-red);
  font-size: 22px;
}

.nav-links {
  display: flex;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s;
}

.nav-links a:hover, .nav-links a.active { color: var(--tx-red); }

/* ── HERO ── */
.hero {
  background: linear-gradient(135deg, #1A1714 0%, #2C2318 50%, #1A1714 100%);
  padding: 72px 24px 80px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '★';
  position: absolute;
  font-size: 420px;
  color: rgba(191,32,18,0.04);
  right: -60px;
  top: -80px;
  font-family: sans-serif;
  pointer-events: none;
}

.hero-inner {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.hero-text h1 {
  font-size: clamp(32px, 4vw, 52px);
  font-weight: 800;
  color: #FFFFFF;
  margin-bottom: 16px;
  line-height: 1.15;
}

.hero-text h1 em {
  font-style: normal;
  color: var(--tx-gold);
}

.hero-text p {
  color: rgba(255,255,255,0.65);
  font-size: 17px;
  margin-bottom: 24px;
  font-weight: 300;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 100px;
  padding: 6px 14px;
  font-size: 13px;
  color: rgba(255,255,255,0.8);
  font-weight: 500;
}

.badge .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--tx-gold); }

/* ── CALCULATOR CARD ── */
.calc-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.calc-header {
  background: var(--tx-red);
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.calc-header h2 {
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.calc-header .tx-flag {
  font-size: 22px;
}

.calc-body { padding: 24px; }

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 14px;
}

.form-group { display: flex; flex-direction: column; gap: 6px; }

.form-group label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input,
.form-group select {
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--text-primary);
  transition: border-color 0.2s, box-shadow 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--tx-red);
  box-shadow: 0 0 0 3px rgba(191,32,18,0.1);
  background: #fff;
}

.form-group.full { grid-column: 1 / -1; }

.calc-btn {
  width: 100%;
  padding: 14px;
  background: var(--tx-red);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-family: 'Syne', sans-serif;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  margin-top: 6px;
  letter-spacing: 0.3px;
}

.calc-btn:hover { background: var(--tx-red-dark); }
.calc-btn:active { transform: scale(0.99); }

/* ── RESULTS ── */
.results-section {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1.5px solid var(--border);
  display: none;
}

.results-section.visible { display: block; }

.results-headline {
  font-family: 'Syne', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 14px;
}

.results-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 16px;
}

.result-card {
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  border: 1px solid var(--border);
}

.result-card.highlight {
  background: var(--tx-red);
  border-color: var(--tx-red);
  grid-column: 1 / -1;
}

.result-card .rc-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.result-card.highlight .rc-label { color: rgba(255,255,255,0.7); }

.result-card .rc-value {
  font-family: 'Syne', sans-serif;
  font-size: 22px;
  font-weight: 800;
  color: var(--text-primary);
}

.result-card.highlight .rc-value { color: #fff; font-size: 28px; }

.breakdown-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.breakdown-table tr { border-bottom: 1px solid var(--border); }
.breakdown-table tr:last-child { border-bottom: none; }

.breakdown-table td {
  padding: 8px 4px;
  color: var(--text-secondary);
}

.breakdown-table td:last-child {
  text-align: right;
  font-weight: 600;
  color: var(--text-primary);
  font-family: 'Syne', sans-serif;
}

.breakdown-table .deduction td:last-child { color: var(--tx-red); }
.breakdown-table .total-row td { font-weight: 700; color: var(--text-primary); border-top: 2px solid var(--border); }

/* ── MAIN CONTENT ── */
.main-content {
  max-width: 1120px;
  margin: 0 auto;
  padding: 64px 24px;
}

.section-label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--tx-red);
  margin-bottom: 12px;
}

.section-title {
  font-family: 'Syne', sans-serif;
  font-size: clamp(26px, 3vw, 38px);
  font-weight: 800;
  margin-bottom: 16px;
}

.section-intro {
  color: var(--text-secondary);
  font-size: 17px;
  max-width: 640px;
  margin-bottom: 40px;
}

/* ── INFO GRID ── */
.info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 64px;
}

.info-card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 28px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.info-card .ic-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--tx-red-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  margin-bottom: 16px;
}

.info-card h3 {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 8px;
}

.info-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ── TAX TABLE ── */
.tax-table-wrap {
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  margin-bottom: 64px;
  box-shadow: var(--shadow-sm);
}

.tax-table-wrap .tt-head {
  background: var(--text-primary);
  padding: 20px 28px;
}

.tax-table-wrap .tt-head h3 {
  color: #fff;
  font-size: 17px;
  font-weight: 700;
}

.tax-table-wrap .tt-head p {
  color: rgba(255,255,255,0.55);
  font-size: 13px;
  margin-top: 4px;
}

table.styled {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

table.styled thead th {
  background: var(--bg);
  padding: 12px 20px;
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border);
}

table.styled tbody td {
  padding: 12px 20px;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}

table.styled tbody tr:last-child td { border-bottom: none; }
table.styled tbody tr:hover td { background: var(--bg); }
table.styled tbody td:first-child { color: var(--text-primary); font-weight: 500; }
table.styled .rate-cell { font-family: 'Syne', sans-serif; font-weight: 700; color: var(--tx-red); }

/* ── FAQ ── */
.faq-list { max-width: 740px; margin-bottom: 64px; }

.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  margin-bottom: 10px;
  overflow: hidden;
  background: var(--surface);
}

.faq-q {
  padding: 18px 24px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  user-select: none;
  transition: background 0.15s;
}

.faq-q:hover { background: var(--bg); }

.faq-q .arrow {
  font-size: 12px;
  color: var(--text-muted);
  transition: transform 0.25s;
  flex-shrink: 0;
}

.faq-item.open .faq-q .arrow { transform: rotate(180deg); }

.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s;
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
  padding: 0 24px;
}

.faq-item.open .faq-a {
  max-height: 300px;
  padding: 0 24px 18px;
}

/* ── BLOG SECTION ── */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
  margin-bottom: 64px;
}

.blog-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, transform 0.2s;
  display: flex;
  flex-direction: column;
}

.blog-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.blog-card-img {
  height: 180px;
  background: linear-gradient(135deg, var(--tx-red) 0%, #8C160D 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  position: relative;
  overflow: hidden;
}

.blog-card-img::after {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.04'%3E%3Cpath d='M0 40L40 0H20L0 20M40 40V20L20 40'/%3E%3C/g%3E%3C/svg%3E");
}

.blog-card-body { padding: 24px; flex: 1; display: flex; flex-direction: column; }

.bc-tag {
  display: inline-block;
  background: var(--tx-red-light);
  color: var(--tx-red);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 4px 10px;
  border-radius: 100px;
  margin-bottom: 12px;
}

.blog-card h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 10px;
  line-height: 1.35;
}

.blog-card h3 a { color: var(--text-primary); text-decoration: none; }
.blog-card h3 a:hover { color: var(--tx-red); }

.blog-card p {
  font-size: 14px;
  color: var(--text-secondary);
  flex: 1;
  margin-bottom: 16px;
}

.read-more {
  font-size: 13px;
  font-weight: 600;
  color: var(--tx-red);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.read-more::after { content: '→'; }
.read-more:hover { text-decoration: underline; }

/* ── CTA BAND ── */
.cta-band {
  background: var(--text-primary);
  padding: 64px 24px;
  text-align: center;
}

.cta-band h2 {
  color: #fff;
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 12px;
}

.cta-band p {
  color: rgba(255,255,255,0.6);
  margin-bottom: 28px;
  font-size: 16px;
}

.cta-btn {
  display: inline-block;
  background: var(--tx-red);
  color: #fff;
  padding: 14px 32px;
  border-radius: var(--radius-sm);
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 16px;
  text-decoration: none;
  transition: background 0.2s;
}

.cta-btn:hover { background: var(--tx-red-dark); text-decoration: none; }

/* ── FOOTER ── */
.site-footer {
  background: #1A1714;
  padding: 48px 24px 28px;
  color: rgba(255,255,255,0.5);
  font-size: 14px;
}

.footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand h3 {
  color: #fff;
  font-size: 18px;
  margin-bottom: 10px;
}

.footer-brand p { line-height: 1.6; font-size: 13px; }

.footer-col h4 {
  color: rgba(255,255,255,0.8);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 14px;
}

.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 8px; }
.footer-col a { color: rgba(255,255,255,0.5); font-size: 13px; text-decoration: none; transition: color 0.2s; }
.footer-col a:hover { color: rgba(255,255,255,0.9); }

.footer-bottom {
  max-width: 1120px;
  margin: 0 auto;
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex;
  justify-content: space-between;
  font-size: 12px;
}

.disclaimer {
  background: var(--tx-gold-light);
  border: 1px solid var(--tx-gold);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  font-size: 13px;
  color: #6B4E0A;
  line-height: 1.6;
  margin-bottom: 24px;
}

.disclaimer strong { color: #4A3500; }

/* ── BLOG POST STYLES ── */
.blog-post-hero {
  background: linear-gradient(135deg, #1A1714 0%, #2C2318 100%);
  padding: 60px 24px;
}

.blog-post-hero-inner {
  max-width: 760px;
  margin: 0 auto;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.post-tag {
  background: var(--tx-red);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 4px 12px;
  border-radius: 100px;
}

.post-date { color: rgba(255,255,255,0.5); font-size: 13px; }
.post-read { color: rgba(255,255,255,0.5); font-size: 13px; }

.blog-post-hero h1 {
  color: #fff;
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 16px;
}

.blog-post-hero .excerpt {
  color: rgba(255,255,255,0.6);
  font-size: 17px;
  font-weight: 300;
}

.post-body {
  max-width: 760px;
  margin: 0 auto;
  padding: 56px 24px 80px;
}

.post-body h2 {
  font-size: 26px;
  font-weight: 800;
  margin: 40px 0 14px;
  padding-top: 8px;
}

.post-body h3 {
  font-size: 20px;
  font-weight: 700;
  margin: 28px 0 10px;
}

.post-body p {
  color: var(--text-secondary);
  margin-bottom: 18px;
  font-size: 16px;
  line-height: 1.8;
}

.post-body ul, .post-body ol {
  color: var(--text-secondary);
  margin: 0 0 18px 20px;
  font-size: 16px;
  line-height: 1.8;
}

.post-body li { margin-bottom: 6px; }

.post-body .callout {
  background: var(--tx-blue-light);
  border-left: 4px solid var(--tx-blue);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 16px 20px;
  margin: 24px 0;
  font-size: 15px;
  color: var(--tx-blue);
}

.post-body .callout strong { color: var(--tx-blue-dark, var(--tx-blue)); }

.post-body table.post-table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 14px;
}

.post-body table.post-table th {
  background: var(--text-primary);
  color: #fff;
  padding: 10px 16px;
  text-align: left;
  font-weight: 600;
}

.post-body table.post-table td {
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}

.post-body table.post-table tr:last-child td { border-bottom: none; }
.post-body table.post-table tr:nth-child(even) td { background: var(--bg); }

.placeholder-block {
  background: repeating-linear-gradient(
    45deg,
    var(--bg),
    var(--bg) 10px,
    var(--border) 10px,
    var(--border) 11px
  );
  border-radius: var(--radius-md);
  border: 1px dashed var(--border);
  padding: 32px;
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
  margin: 24px 0;
}

.placeholder-block strong { display: block; font-size: 16px; margin-bottom: 6px; color: var(--text-secondary); }

.related-tool-cta {
  background: var(--tx-red);
  border-radius: var(--radius-lg);
  padding: 32px;
  text-align: center;
  margin: 40px 0;
}

.related-tool-cta h3 { color: #fff; font-size: 20px; margin-bottom: 8px; }
.related-tool-cta p { color: rgba(255,255,255,0.7); font-size: 14px; margin-bottom: 18px; }
.related-tool-cta a {
  display: inline-block;
  background: #fff;
  color: var(--tx-red);
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  transition: opacity 0.2s;
}
.related-tool-cta a:hover { opacity: 0.9; text-decoration: none; }

/* ── BREADCRUMB ── */
.breadcrumb {
  max-width: 1120px;
  margin: 0 auto;
  padding: 16px 24px 0;
  font-size: 13px;
  color: var(--text-muted);
}

.breadcrumb a { color: var(--text-muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--tx-red); }
.breadcrumb span { margin: 0 6px; }

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; gap: 40px; }
  .info-grid { grid-template-columns: 1fr 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 600px) {
  .form-row { grid-template-columns: 1fr; }
  .results-grid { grid-template-columns: 1fr; }
  .info-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .footer-bottom { flex-direction: column; gap: 8px; }
}
