/* ============================================================
   PACKOVA - Main Stylesheet
   Design: Organic Biophilic · Kraft Natural · Professional B2B
   ============================================================ */

/* ── Google Font Import ──────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400&display=swap');

/* ── Design Tokens ───────────────────────────────────────── */
:root {
  /* Brand Colors */
  --color-brand:        #8B4513;   /* Saddle Brown – kraft paper */
  --color-brand-dark:   #6B3410;
  --color-brand-light:  #C0784D;
  --color-eco:          #2D6A4F;   /* Forest Green – eco/FSC */
  --color-eco-dark:     #1B4332;
  --color-eco-light:    #40916C;

  /* UI Palette */
  --color-primary:      #1A1009;   /* Near-black warm */
  --color-secondary:    #5C3D2E;   /* Dark kraft brown */
  --color-accent:       #D97706;   /* Amber – CTA highlight */
  --color-accent-hover: #B45309;

  /* Surface Colors */
  --color-background:   #FEFDF8;   /* Warm white / paper */
  --color-surface:      #FAF6EE;   /* Cream / kraft paper tone */
  --color-surface-2:    #F3EDE0;   /* Slightly darker cream */
  --color-muted:        #E8E0D0;   /* Muted kraft */
  --color-border:       #D4C8B0;   /* Kraft border */

  /* Text Colors */
  --color-text:         #1A1009;   /* Primary text */
  --color-text-muted:   #6B5744;   /* Secondary text */
  --color-text-light:   #9C8575;   /* Tertiary text */

  /* State Colors */
  --color-success:      #166534;
  --color-error:        #DC2626;
  --color-warning:      #D97706;

  /* Shadows */
  --shadow-xs:   0 1px 2px 0 rgba(26,16,9,0.05);
  --shadow-sm:   0 2px 8px 0 rgba(26,16,9,0.08);
  --shadow-md:   0 4px 20px 0 rgba(26,16,9,0.10);
  --shadow-lg:   0 8px 40px 0 rgba(26,16,9,0.12);
  --shadow-xl:   0 16px 60px 0 rgba(26,16,9,0.15);

  /* Border Radius */
  --radius-xs:   4px;
  --radius-sm:   8px;
  --radius-md:   12px;
  --radius-lg:   16px;
  --radius-xl:   24px;
  --radius-2xl:  32px;
  --radius-full: 9999px;

  /* Spacing Scale (8px base) */
  --space-1:  4px;
  --space-2:  8px;
  --space-3:  12px;
  --space-4:  16px;
  --space-5:  20px;
  --space-6:  24px;
  --space-8:  32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;
  --space-20: 80px;
  --space-24: 96px;
  --space-32: 128px;

  /* Typography Scale */
  --text-xs:   0.75rem;    /* 12px */
  --text-sm:   0.875rem;   /* 14px */
  --text-base: 1rem;       /* 16px */
  --text-lg:   1.125rem;   /* 18px */
  --text-xl:   1.25rem;    /* 20px */
  --text-2xl:  1.5rem;     /* 24px */
  --text-3xl:  1.875rem;   /* 30px */
  --text-4xl:  2.25rem;    /* 36px */
  --text-5xl:  3rem;       /* 48px */
  --text-6xl:  3.75rem;    /* 60px */

  /* Line Heights */
  --leading-tight:  1.25;
  --leading-snug:   1.375;
  --leading-normal: 1.5;
  --leading-relaxed:1.625;
  --leading-loose:  1.75;

  /* Transitions */
  --transition-fast:   150ms ease-out;
  --transition-base:   250ms ease-out;
  --transition-slow:   400ms ease-out;

  /* Layout */
  --container-sm:  640px;
  --container-md:  768px;
  --container-lg:  1024px;
  --container-xl:  1280px;
  --container-2xl: 1440px;
  --navbar-height: 72px;

  /* Z-Index Scale */
  --z-base:    0;
  --z-raised:  10;
  --z-overlay: 20;
  --z-dropdown:40;
  --z-sticky:  100;
  --z-modal:   1000;
}

/* ── CSS Reset ───────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
  color: var(--color-text);
  background-color: var(--color-background);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, video {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  cursor: pointer;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}

ul, ol { list-style: none; }

input, textarea, select {
  font-family: inherit;
  font-size: inherit;
}

/* ── Skip Link (Accessibility) ───────────────────────────── */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-4);
  background: var(--color-brand);
  color: #fff;
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-sm);
  font-weight: 600;
  z-index: calc(var(--z-modal) + 1);
  transition: top var(--transition-fast);
}
.skip-link:focus { top: var(--space-4); }

/* ── Layout Utilities ────────────────────────────────────── */
.container {
  width: 100%;
  max-width: var(--container-xl);
  margin-inline: auto;
  padding-inline: var(--space-6);
}

@media (min-width: 1280px) {
  .container { padding-inline: var(--space-10); }
}

.section {
  padding-block: var(--space-20);
}

@media (max-width: 768px) {
  .section { padding-block: var(--space-12); }
}

/* ── Typography ──────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: var(--leading-tight);
  color: var(--color-primary);
}

h1 { font-size: clamp(2rem, 5vw, var(--text-6xl)); }
h2 { font-size: clamp(1.5rem, 4vw, var(--text-4xl)); }
h3 { font-size: clamp(1.25rem, 3vw, var(--text-2xl)); }
h4 { font-size: var(--text-xl); }
h5 { font-size: var(--text-lg); }

p { max-width: 68ch; }

.text-brand  { color: var(--color-brand); }
.text-eco    { color: var(--color-eco); }
.text-muted  { color: var(--color-text-muted); }
.text-center { text-align: center; }
.text-sm     { font-size: var(--text-sm); }
.text-xs     { font-size: var(--text-xs); }
.text-lg     { font-size: var(--text-lg); }
.text-xl     { font-size: var(--text-xl); }

.font-medium  { font-weight: 500; }
.font-semibold{ font-weight: 600; }
.font-bold    { font-weight: 700; }
.font-extrabold{font-weight: 800; }

/* Section Labels */
.section-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-brand);
  margin-bottom: var(--space-4);
}

.section-label::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 2px;
  background: var(--color-brand);
  border-radius: var(--radius-full);
}

.section-title {
  font-size: clamp(1.75rem, 4vw, var(--text-4xl));
  font-weight: 800;
  line-height: var(--leading-snug);
  color: var(--color-primary);
  margin-bottom: var(--space-4);
}

.section-desc {
  font-size: var(--text-lg);
  color: var(--color-text-muted);
  line-height: var(--leading-relaxed);
  max-width: 56ch;
}

/* ── Buttons ─────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 14px var(--space-6);
  font-size: var(--text-base);
  font-weight: 600;
  line-height: 1;
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
  cursor: pointer;
  white-space: nowrap;
  min-height: 48px;
  position: relative;
  overflow: hidden;
}

.btn:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
}

.btn-primary {
  background: var(--color-brand);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover {
  background: var(--color-brand-dark);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}
.btn-primary:active { transform: translateY(0); }

.btn-eco {
  background: var(--color-eco);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-eco:hover {
  background: var(--color-eco-dark);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  color: var(--color-brand);
  border: 2px solid var(--color-brand);
}
.btn-outline:hover {
  background: var(--color-brand);
  color: #fff;
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--color-text-muted);
}
.btn-ghost:hover { background: var(--color-muted); color: var(--color-text); }

.btn-sm {
  padding: 10px var(--space-4);
  font-size: var(--text-sm);
  min-height: 40px;
}

.btn-lg {
  padding: 18px var(--space-8);
  font-size: var(--text-lg);
  min-height: 56px;
}

/* ── Cards ───────────────────────────────────────────────── */
.card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  transition: all var(--transition-base);
  box-shadow: var(--shadow-xs);
}

.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
  border-color: var(--color-brand-light);
}

.card-body { padding: var(--space-6); }

/* ── Badge ───────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 4px 12px;
  font-size: var(--text-xs);
  font-weight: 600;
  border-radius: var(--radius-full);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.badge-brand  { background: #F5E6D8; color: var(--color-brand); }
.badge-eco    { background: #D8F0E6; color: var(--color-eco-dark); }
.badge-accent { background: #FEF3C7; color: var(--color-accent-hover); }

/* ── Navigation ──────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--navbar-height);
  display: flex;
  align-items: center;
  background: rgba(254,253,248,0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--color-border);
  z-index: var(--z-sticky);
  box-shadow: var(--shadow-xs);
  transition: box-shadow var(--transition-base);
}

/* Container içinde tam yükseklik & inner'ın ortalanması */
.navbar > .container {
  height: 100%;
  display: flex;
  align-items: center;
}

.navbar.scrolled { box-shadow: var(--shadow-md); }

.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 100%;
}

.navbar-logo {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-weight: 800;
  font-size: var(--text-xl);
  color: var(--color-brand);
}

.navbar-logo img {
  height: 40px;
  width: auto;
}

.navbar-nav {
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-muted);
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  position: relative;
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-brand);
  background: rgba(139,69,19,0.08);
}

/* Dropdown */
.nav-dropdown { position: relative; }

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 200px;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: var(--space-2);
  z-index: var(--z-dropdown);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: all var(--transition-base);
}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav-dropdown-menu a {
  display: block;
  padding: var(--space-2) var(--space-4);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}

.nav-dropdown-menu a:hover {
  background: var(--color-surface-2);
  color: var(--color-brand);
}

/* Navbar Right */
.navbar-right {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

/* Navbar CTA – lang-switcher ile orantılı, compact */
.navbar-right .btn {
  padding: 8px 16px;
  min-height: 34px;
  font-size: var(--text-sm);
  border-radius: var(--radius-md);
}

/* Language Switcher */
.lang-switcher {
  display: flex;
  align-items: center;
  width: fit-content;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  padding: 2px;
  gap: 2px;
}

.lang-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  font-size: var(--text-xs);
  font-weight: 600;
  border-radius: var(--radius-full);
  transition: all var(--transition-fast);
  color: var(--color-text-muted);
  letter-spacing: 0.04em;
}

.lang-btn.active {
  background: var(--color-brand);
  color: #fff;
}

.lang-btn img {
  width: 18px;
  height: 12px;
  border-radius: 2px;
  object-fit: cover;
}

/* Mobile Menu Toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  transition: background var(--transition-fast);
}

.nav-toggle:hover { background: var(--color-surface); }

.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--color-text);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
  display: block;
}

.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.nav-toggle.active span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile Nav Overlay */
.nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(26,16,9,0.5);
  z-index: calc(var(--z-sticky) - 1);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-base);
}

.nav-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

/* Mobile Menu Drawer */
.nav-drawer {
  position: fixed;
  top: 0; right: 0;
  width: min(320px, 90vw);
  height: 100dvh;
  background: #fff;
  z-index: var(--z-sticky);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform var(--transition-slow);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
}

.nav-drawer.active { transform: translateX(0); }

.nav-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-6) var(--space-6) var(--space-4);
  border-bottom: 1px solid var(--color-border);
  flex-shrink: 0;
}

.nav-drawer-nav {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  flex: 1;
  overflow-y: auto;
  padding: var(--space-4) var(--space-6);
}

.nav-drawer-footer {
  flex-shrink: 0;
  padding: var(--space-4) var(--space-6);
  border-top: 1px solid var(--color-border);
}

.nav-drawer-link {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  font-size: var(--text-base);
  font-weight: 500;
  color: var(--color-text);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
}

.nav-drawer-link:hover {
  background: var(--color-surface);
  color: var(--color-brand);
}

.nav-drawer-submenu {
  padding-left: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  margin-top: var(--space-1);
}

.nav-drawer-submenu a {
  display: block;
  padding: var(--space-2) var(--space-4);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}

.nav-drawer-submenu a:hover { color: var(--color-brand); }

/* ── Footer ──────────────────────────────────────────────── */
.footer {
  background: var(--color-primary);
  color: rgba(255,255,255,0.7);
  padding-top: var(--space-16);
  padding-bottom: var(--space-8);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-10);
  padding-bottom: var(--space-12);
  border-bottom: 1px solid rgba(255,255,255,0.1);
  margin-bottom: var(--space-8);
}

@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: var(--space-8); }
}

@media (max-width: 640px) {
  .footer-grid { grid-template-columns: 1fr; }
}

.footer-brand img { height: 56px; width: auto; display: block; margin: 0 auto var(--space-4); filter: brightness(0) invert(1); }
.footer-brand p { font-size: var(--text-sm); line-height: var(--leading-relaxed); max-width: 36ch; text-align: center; margin: 0 auto; }

.footer-col h3 {
  color: #fff;
  font-size: var(--text-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: var(--space-4);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.footer-links a {
  font-size: var(--text-sm);
  color: rgba(255,255,255,0.6);
  transition: color var(--transition-fast);
}
.footer-links a:hover { color: var(--color-brand-light); }

.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  font-size: var(--text-sm);
  color: rgba(255,255,255,0.65);
  margin-bottom: var(--space-3);
}

.footer-contact-item svg {
  width: 18px; height: 18px;
  flex-shrink: 0;
  color: var(--color-brand-light);
  margin-top: 2px;
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
}

.footer-bottom p { font-size: var(--text-xs); }

.footer-social {
  display: flex;
  gap: var(--space-3);
  justify-content: center;
}

.footer-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px; height: 40px;
  background: rgba(255,255,255,0.08);
  border-radius: var(--radius-sm);
  color: rgba(255,255,255,0.7);
  transition: all var(--transition-fast);
}

.footer-social a:hover {
  background: var(--color-brand);
  color: #fff;
  transform: translateY(-2px);
}

.footer-social svg { width: 18px; height: 18px; }

/* ── Floating WhatsApp ───────────────────────────────────── */
.whatsapp-float {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: var(--z-overlay);
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.whatsapp-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px; height: 56px;
  background: #25D366;
  border-radius: var(--radius-full);
  box-shadow: 0 4px 20px rgba(37,211,102,0.4);
  transition: all var(--transition-base);
  animation: pulse-green 2.5s ease-in-out infinite;
}

.whatsapp-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 28px rgba(37,211,102,0.5);
  animation: none;
}

.whatsapp-btn svg { width: 28px; height: 28px; fill: #fff; }

@keyframes pulse-green {
  0%, 100% { box-shadow: 0 4px 20px rgba(37,211,102,0.4); }
  50%       { box-shadow: 0 4px 32px rgba(37,211,102,0.65); }
}

/* ── Page Header / Hero Inner ────────────────────────────── */
.page-hero {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  padding-top: calc(var(--navbar-height) + var(--space-16));
  padding-bottom: var(--space-16);
  position: relative;
  overflow: hidden;
}

.page-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../images/paper-background.webp') center/cover no-repeat;
  opacity: 0.04;
  pointer-events: none;
}

.page-hero-content,
.page-hero > .container { position: relative; z-index: 1; }

.breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}

.breadcrumb a:hover { color: var(--color-brand); }
.breadcrumb-sep { color: var(--color-text-light); }

/* ── Divider ─────────────────────────────────────────────── */
.divider {
  height: 1px;
  background: var(--color-border);
  margin-block: var(--space-8);
}

/* ── Grid Helpers ────────────────────────────────────────── */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-6); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-6); }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-6); }

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

@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* ── Flex Helpers ────────────────────────────────────────── */
.flex          { display: flex; }
.flex-col      { flex-direction: column; }
.items-center  { align-items: center; }
.justify-center{ justify-content: center; }
.gap-2         { gap: var(--space-2); }
.gap-3         { gap: var(--space-3); }
.gap-4         { gap: var(--space-4); }
.gap-6         { gap: var(--space-6); }
.flex-wrap     { flex-wrap: wrap; }
.flex-1        { flex: 1; }

/* ── Scroll Animations ───────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 768px) {
  .navbar-nav { display: none; }
  .nav-toggle   { display: flex; }
  .nav-overlay  { display: block; }

  /* Mobilde lang-switcher toggle olarak gösterilir */
  .navbar-right .lang-btn {
    padding: 5px 10px;
    font-size: 11px;
    gap: 0;
  }
  .navbar-right .lang-btn img { display: none; }
}

/* ── Organic Decorative Shapes ───────────────────────────── */
.organic-blob {
  position: absolute;
  border-radius: 60% 40% 55% 45% / 50% 60% 40% 50%;
  opacity: 0.06;
  pointer-events: none;
  filter: blur(40px);
}

/* ── Tables ──────────────────────────────────────────────── */
.table-wrapper {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--text-sm);
}

thead th {
  background: var(--color-surface-2);
  padding: var(--space-3) var(--space-4);
  text-align: left;
  font-weight: 600;
  color: var(--color-text-muted);
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 1px solid var(--color-border);
}

tbody td {
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--color-muted);
  color: var(--color-text);
}

tbody tr:last-child td { border-bottom: none; }
tbody tr:hover td { background: var(--color-surface); }

/* ── Forms ───────────────────────────────────────────────── */
.form-group { display: flex; flex-direction: column; gap: var(--space-2); }

.form-label {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
}

.form-label .required { color: var(--color-error); margin-left: 2px; }

.form-control {
  padding: 12px var(--space-4);
  border: 2px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: var(--text-base);
  color: var(--color-text);
  background: #fff;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  min-height: 48px;
  width: 100%;
}

.form-control:focus {
  outline: none;
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px rgba(139,69,19,0.12);
}

.form-control::placeholder { color: var(--color-text-light); }

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

.form-error {
  font-size: var(--text-xs);
  color: var(--color-error);
  display: none;
}
.form-group.has-error .form-control { border-color: var(--color-error); }
.form-group.has-error .form-error   { display: block; }

/* ── Stat Block ──────────────────────────────────────────── */
.stat-block {
  text-align: center;
  padding: var(--space-6);
}

.stat-number {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  color: var(--color-brand);
  line-height: 1;
  margin-bottom: var(--space-2);
}

.stat-label {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  font-weight: 500;
}

/* ── Feature Icon Block ──────────────────────────────────── */
.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px; height: 56px;
  background: var(--color-surface-2);
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-4);
  color: var(--color-brand);
  flex-shrink: 0;
}

.feature-icon svg { width: 28px; height: 28px; }
.feature-icon.eco { background: #D8F0E6; color: var(--color-eco); }

/* ── Highlight Box ───────────────────────────────────────── */
.highlight-box {
  background: linear-gradient(135deg, var(--color-surface) 0%, var(--color-surface-2) 100%);
  border: 1px solid var(--color-border);
  border-left: 4px solid var(--color-brand);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}

/* ── Responsive Visibility ───────────────────────────────── */
.hide-mobile  { display: block; }
.show-mobile  { display: none;  }

@media (max-width: 640px) {
  .hide-mobile  { display: none; }
  .show-mobile  { display: block; }
}

/* ── Smooth page offset for fixed nav ───────────────────── */
[id] { scroll-margin-top: calc(var(--navbar-height) + 16px); }
