/* === PREMIUM TOKENS (Midnight Forest Theme) === */
:root {
  --bg: #0d1f0d; /* Deep Dark Green from Spec */
  --bg-darker: #050d05;
  --text: #fffce0; /* Pale Yellow/Muted Gold for high contrast */
  --text-muted: #a8b0a8;
  --accent: #d4af37; /* Muted Gold */
  --accent-glow: rgba(212, 175, 55, 0.3);
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --font-heading: 'Playfair Display', serif;
  --font-body: 'Inter', sans-serif;
  --shadow-neon: 0 0 20px var(--accent-glow);
  --glass-bg: rgba(13, 31, 13, 0.7);
  --glass-border: rgba(212, 175, 55, 0.15);
}

/* === CSS RESET & BASE === */
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: var(--font-body);
  line-height: 1.6;
  font-size: 15px; /* High density requirement */
  overflow-x: hidden;
  color: var(--text);
  background: var(--bg);
  background-attachment: fixed;
}

/* Animated Gradient Background */
.bg-animated {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  z-index: -1;
  background: linear-gradient(-45deg, #0d1f0d, #1a331a, #050d05, #0d1f0d);
  background-size: 400% 400%;
  animation: gradientBG 12s linear infinite;
}

@keyframes gradientBG {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

img { max-width: 100%; height: auto; display: block; object-fit: cover; }
a { text-decoration: none; color: inherit; transition: all 0.3s ease; }
ul { list-style: none; }

/* === STRUCTURAL BASELINES === */
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; width: 100%; }

/* Section Spacing: Spacious Editorial vs High Density Cards */
section {
  padding: 100px 0; /* 90-120px range */
  position: relative;
}

/* Paper Tear Divider */
.tear-divider {
  width: 100%;
  height: 60px;
  background: var(--bg);
  clip-path: polygon(0% 0%, 5% 40%, 10% 0%, 15% 50%, 20% 10%, 25% 60%, 30% 20%, 35% 70%, 40% 30%, 45% 80%, 50% 40%, 55% 90%, 60% 50%, 65% 100%, 70% 60%, 75% 90%, 80% 50%, 85% 80%, 90% 40%, 95% 70%, 100% 30%, 100% 100%, 0% 100%);
  margin-top: -60px;
  position: relative;
  z-index: 2;
}

/* === MEGA HEADER (Layout Scheme) === */
.mega-header {
  background: var(--bg-darker);
  padding: 40px 0;
  border-bottom: 1px solid var(--glass-border);
}

.header-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 32px;
  align-items: center;
}

.header-left, .header-right {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.brand-block {
  text-align: center;
}

.brand-name {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 2px;
}

.tagline {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-style: italic;
}

.header-search {
  display: flex;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--glass-border);
  padding: 8px 15px;
  border-radius: var(--radius-sm);
}

.header-search input {
  background: transparent;
  border: none;
  color: var(--text);
  outline: none;
  width: 100%;
}

.social-icons {
  display: flex;
  gap: 15px;
  justify-content: flex-end;
}

.contact-mini {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: right;
}

/* Fixed Nav Bar (Secondary Nav) */
.fixed-nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(13, 31, 13, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--glass-border);
  padding: 15px 0;
}

.nav-list {
  display: flex;
  justify-content: center;
  gap: 40px;
}

.nav-link {
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 1px;
}

.nav-link.active {
  color: var(--accent);
  border-bottom: 2px solid var(--accent);
}

/* === TABBED DASHBOARD ARCHETYPE === */
.tab-container {
  margin-top: 40px;
}

.tab-bar {
  display: flex;
  border-bottom: 1px solid var(--glass-border);
  margin-bottom: 30px;
}

.tab-btn {
  padding: 15px 30px;
  cursor: pointer;
  background: none;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-heading);
  font-size: 1.2rem;
  transition: all 0.3s;
}

.tab-btn.active {
  color: var(--accent);
  border-bottom: 3px solid var(--accent);
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

/* === HERO STYLE === */
.hero-section {
  min-height: 70vh;
  display: flex;
  align-items: center;
  background-size: cover;
  background-position: center;
  position: relative;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(13,31,13,0.95), rgba(13,31,13,0.4));
}

.hero-content {
  position: relative;
  z-index: 1;
  width: 100%;
}

.hero-headline {
  font-family: var(--font-heading);
  font-size: 5rem;
  line-height: 1;
  max-width: 800px;
  margin-bottom: 20px;
}

.hero-subtitle {
  font-size: 1.5rem;
  color: var(--accent);
  text-align: right;
  max-width: 600px;
  margin-left: auto;
  font-weight: 300;
}

/* === GRID SYSTEM (Equal Columns) === */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

/* === CARD STYLING === */
.news-card {
  background: var(--bg-darker);
  border: 1px solid var(--glass-border);
  padding: 20px; /* Compact padding per spec */
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: var(--shadow-neon);
  position: relative;
  overflow: hidden;
}

.news-card:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: 0 15px 30px var(--accent-glow);
}

.card-meta {
  font-size: 0.75rem;
  color: var(--accent);
  margin-bottom: 10px;
  text-transform: uppercase;
}

.card-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  margin-bottom: 12px;
}

.card-excerpt {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* === UNDERLINE CTA === */
.cta-underline {
  display: inline-block;
  margin-top: 15px;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.8rem;
  padding-bottom: 2px;
  border-bottom: 2px solid var(--accent);
}

.cta-underline:hover {
  letter-spacing: 1px;
}

/* === TESTIMONIALS (Alternating) === */
.testimonial-block {
  display: flex;
  align-items: center;
  gap: 60px;
  margin-bottom: 80px;
}

.testimonial-block.alt {
  flex-direction: row-reverse;
}

.testimonial-img {
  width: 250px;
  height: 350px;
  border: 2px solid var(--accent);
  padding: 10px;
}

.testimonial-content {
  flex: 1;
}

.quote {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-style: italic;
  margin-bottom: 20px;
}

.author-info {
  color: var(--accent);
  font-weight: 600;
}

/* === COMPARISON SECTION === */
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 40px;
}

.comparison-table th, .comparison-table td {
  padding: 20px;
  border: 1px solid var(--glass-border);
  text-align: left;
}

.comparison-table th {
  background: var(--bg-darker);
  font-family: var(--font-heading);
}

.check-icon { color: #4ade80; }
.cross-icon { color: #f87171; }

/* === CALCULATOR === */
.calc-container {
  background: var(--bg-darker);
  padding: 40px;
  border: 1px solid var(--accent);
  max-width: 600px;
  margin: 0 auto;
}

.calc-group {
  margin-bottom: 25px;
}

.calc-group label {
  display: block;
  margin-bottom: 10px;
  font-weight: 600;
}

.calc-input {
  width: 100%;
  padding: 12px;
  background: var(--bg);
  border: 1px solid var(--glass-border);
  color: var(--text);
}

.calc-result {
  font-size: 2rem;
  color: var(--accent);
  text-align: center;
  margin-top: 30px;
  font-family: var(--font-heading);
}

/* === FOOTER (Bordered Style) === */
.site-footer {
  padding: 80px 0 40px;
  background: var(--bg-darker);
  border-top: 1px solid var(--glass-border);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.footer-col {
  padding: 30px;
  border: 1px solid var(--glass-border);
  border-left: none;
}

.footer-col:first-child { border-left: 1px solid var(--glass-border); }

.footer-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  margin-bottom: 20px;
  color: var(--accent);
}

.footer-links li { margin-bottom: 10px; }
.footer-links a:hover { color: var(--accent); padding-left: 5px; }

.copyright {
  text-align: center;
  margin-top: 60px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Breadcrumbs */
.breadcrumbs {
  padding: 20px 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.breadcrumbs a:hover { color: var(--accent); }

/* Mobile Menu */
.menu-toggle {
  display: none;
  font-size: 2rem;
  cursor: pointer;
  color: var(--accent);
}

/* Responsive */
@media (max-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .header-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .header-right, .contact-mini { text-align: center; justify-content: center; }
  .hero-headline { font-size: 2.5rem; }
  .grid-3, .grid-4, .footer-grid { grid-template-columns: 1fr; }
  .mega-header { padding: 20px 0; }
  .fixed-nav { padding: 10px 0; }
  .nav-list { display: none; flex-direction: column; text-align: center; gap: 15px; padding: 20px 0; }
  .nav-list.active { display: flex; }
  .menu-toggle { display: block; text-align: center; }
  .testimonial-block { flex-direction: column; text-align: center; }
  .testimonial-block.alt { flex-direction: column; }
}
