/* ==========================================================================
   ContabilBun.ro - Design System (style.css)
   --------------------------------------------------------------------------
   Shared, canonical stylesheet for ALL 5 pages (home + 4 inner pages).
   Inner-page developers: copy the header/footer markup from index.html and
   REUSE the class names documented here. Do not fork this file per page.

   Sections:
     1.  Design tokens (CSS custom properties)
     2.  Reset & base elements
     3.  Layout helpers (.container, .section, .narrow, .center)
     4.  Typography helpers (.kicker, .lead, .muted, headings)
     5.  Buttons (.btn, .btn-primary, .btn-ghost, .btn-lg)
     6.  Header / Nav (.site-header, .nav, .brand, CSS-only mobile menu)
     7.  Hero (.hero) + trust chips (.chips)
     8.  Page hero for sub-pages (.page-hero)
     9.  Cards grid (.cards, .card)
     10. Process steps (.steps)
     11. Stats (.stats)
     12. Split band (.split) - image + text two columns
     13. FAQ (.faq with <details>)
     14. CTA band (.cta-band)
     15. Footer (.site-footer)
     16. Sticky mobile call bar (.callbar)
     17. Responsive breakpoints
     18. Reduced motion
   ========================================================================== */

/* 1. ----------------------------------------------------------------- TOKENS */
:root {
  /* Brand palette */
  --brand:        #0e3b43;  /* deep professional teal */
  --brand-deep:   #0f2c3f;  /* navy, for deep sections */
  --brand-700:    #0b2f36;
  --accent:       #18a45b;  /* fresh emerald, CTAs */
  --accent-600:   #14894c;  /* accent hover */
  --accent-300:   #4bcf8a;  /* light accent for dark backgrounds */

  /* Neutrals */
  --cream:        #f6f9f8;  /* soft off-white background */
  --cream-2:      #eef4f2;  /* alt section background */
  --surface:      #ffffff;  /* card surface */
  --ink:          #13242b;  /* primary text */
  --ink-muted:    #4d6068;  /* muted text */
  --line:         #e2ebe8;  /* hairline borders */

  /* Effects */
  --radius:       14px;
  --radius-sm:    10px;
  --radius-lg:    22px;
  --shadow-sm:    0 1px 2px rgba(15, 44, 63, .06), 0 2px 8px rgba(15, 44, 63, .05);
  --shadow:       0 10px 30px rgba(14, 59, 67, .10), 0 2px 8px rgba(14, 59, 67, .06);
  --shadow-lg:    0 24px 60px rgba(14, 59, 67, .18);

  /* Gradients */
  --grad-brand:   linear-gradient(135deg, #0e3b43 0%, #0f2c3f 100%);
  --grad-accent:  linear-gradient(135deg, #18a45b 0%, #14894c 100%);
  --grad-soft:    linear-gradient(180deg, #f6f9f8 0%, #eef4f2 100%);

  /* Type */
  --font-head: "Sora", "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Rhythm */
  --container: 1180px;
  --gutter: clamp(18px, 4vw, 40px);
  --section-y: clamp(56px, 8vw, 110px);
}

/* 2. ------------------------------------------------------------------ RESET */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 86px; /* offset sticky header on anchor jumps */
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

a { color: var(--accent-600); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.12;
  color: var(--ink);
  margin: 0 0 .5em;
  letter-spacing: -.015em;
}
h1 { font-size: clamp(2rem, 5vw, 3.35rem); }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.5rem); }
h3 { font-size: clamp(1.2rem, 2.2vw, 1.5rem); }
p  { margin: 0 0 1rem; }

/* Visible keyboard focus everywhere */
:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

/* 3. ----------------------------------------------------------------- LAYOUT */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: var(--section-y); }
.section-alt  { background: var(--cream-2); }       /* light alternate */
.section-deep {                                     /* dark, high contrast */
  background: var(--grad-brand);
  color: #dceae8;
}
.section-deep h1,
.section-deep h2,
.section-deep h3 { color: #fff; }
.section-deep .muted { color: #a9c4c2; }

.narrow { max-width: 760px; margin-inline: auto; }
.center { text-align: center; }

/* Section heading block */
.section-head { max-width: 720px; margin: 0 auto clamp(34px, 5vw, 56px); }
.section-head.center { text-align: center; }

/* 4. ------------------------------------------------------------- TYPOGRAPHY */
.kicker {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .82rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent-600);
  margin-bottom: .85rem;
}
.section-deep .kicker { color: var(--accent-300); }

.lead {
  font-size: clamp(1.08rem, 1.6vw, 1.28rem);
  line-height: 1.6;
  color: var(--ink-muted);
}
.section-deep .lead { color: #cfe2df; }

.muted { color: var(--ink-muted); }

/* 5. ---------------------------------------------------------------- BUTTONS */
.btn {
  --btn-bg: var(--surface);
  --btn-fg: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55em;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1;
  padding: .85em 1.45em;
  border-radius: 999px;
  border: 1.5px solid transparent;
  background: var(--btn-bg);
  color: var(--btn-fg);
  cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease, border-color .2s ease;
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--grad-accent);
  color: #fff;
  box-shadow: 0 8px 22px rgba(24, 164, 91, .32);
}
.btn-primary:hover { box-shadow: 0 12px 30px rgba(24, 164, 91, .42); color: #fff; }

.btn-ghost {
  background: transparent;
  color: var(--brand);
  border-color: rgba(14, 59, 67, .25);
}
.btn-ghost:hover { border-color: var(--brand); background: rgba(14, 59, 67, .05); }

/* Ghost variant on dark backgrounds */
.section-deep .btn-ghost,
.hero .btn-ghost {
  color: #fff;
  border-color: rgba(255, 255, 255, .45);
}
.section-deep .btn-ghost:hover,
.hero .btn-ghost:hover { background: rgba(255, 255, 255, .12); border-color: #fff; }

.btn-lg { padding: 1.05em 1.9em; font-size: 1.08rem; }

.btn-row { display: flex; flex-wrap: wrap; gap: 14px; }

/* 6. ------------------------------------------------------------ HEADER / NAV */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 70px;
}

/* Brand (logo + wordmark) */
.brand {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.22rem;
  color: var(--brand);
  letter-spacing: -.02em;
  text-decoration: none;
}
.brand:hover { text-decoration: none; }
.brand .brand-mark { flex: 0 0 auto; width: 34px; height: 34px; }
.brand b { color: var(--accent-600); font-weight: 700; }

/* Nav links + CTA wrapper */
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links a {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .96rem;
  color: var(--ink);
  padding: .55em .8em;
  border-radius: 8px;
  transition: color .15s ease, background .15s ease;
}
.nav-links a:hover { color: var(--accent-600); background: rgba(24, 164, 91, .08); text-decoration: none; }
.nav-links a[aria-current="page"] { color: var(--accent-600); }

/* Phone CTA in the nav */
.nav-cta {
  margin-left: 6px;
  background: var(--grad-accent);
  color: #fff !important;
  border-radius: 999px;
  padding: .6em 1.1em !important;
  box-shadow: 0 6px 16px rgba(24, 164, 91, .3);
}
.nav-cta:hover { background: var(--grad-accent); color: #fff !important; }

/* CSS-only mobile menu: hidden checkbox + burger label */
.nav-toggle { position: absolute; opacity: 0; pointer-events: none; }
.burger {
  display: none;
  width: 46px; height: 46px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  cursor: pointer;
  position: relative;
}
.burger span,
.burger span::before,
.burger span::after {
  content: "";
  position: absolute;
  left: 50%; top: 50%;
  width: 20px; height: 2px;
  background: var(--brand);
  border-radius: 2px;
  transform: translate(-50%, -50%);
  transition: transform .25s ease, opacity .2s ease;
}
.burger span::before { transform: translate(-50%, -7px); }
.burger span::after  { transform: translate(-50%, 5px); }

/* 7. ------------------------------------------------------------------- HERO */
.hero {
  position: relative;
  background: var(--grad-brand);
  color: #eaf3f1;
  overflow: hidden;
  padding-block: clamp(48px, 7vw, 96px);
}
.hero::after { /* subtle accent glow */
  content: "";
  position: absolute;
  inset: auto -10% -40% auto;
  width: 60vw; height: 60vw;
  max-width: 720px; max-height: 720px;
  background: radial-gradient(circle, rgba(24,164,91,.28) 0%, rgba(24,164,91,0) 65%);
  pointer-events: none;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  align-items: center;
  gap: clamp(28px, 5vw, 64px);
  position: relative;
  z-index: 1;
}
.hero h1 { color: #fff; margin-bottom: .35em; }
.hero .lead { color: #cfe2df; max-width: 36ch; }
.hero .btn-row { margin-top: 28px; }

.hero-media {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 4px solid rgba(255,255,255,.12);
}
.hero-media img {
  width: 100%;
  height: 100%;
  aspect-ratio: 5 / 5.4;
  object-fit: cover;
}

/* Trust chips */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
  padding: 0;
  list-style: none;
}
.chips li {
  display: inline-flex;
  align-items: center;
  gap: .45em;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .9rem;
  color: #eaf3f1;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.18);
  padding: .5em .9em;
  border-radius: 999px;
}
.chips li::before { content: "✓"; color: var(--accent-300); font-weight: 800; }

/* 8. -------------------------------------------------------------- PAGE HERO */
/* Compact hero for inner pages. Inner devs: <section class="page-hero">. */
.page-hero {
  background: var(--grad-brand);
  color: #eaf3f1;
  padding-block: clamp(46px, 6vw, 78px);
  text-align: center;
}
.page-hero h1 { color: #fff; }
.page-hero .lead { color: #cfe2df; margin-inline: auto; max-width: 60ch; }
.page-hero .breadcrumb {
  font-size: .9rem;
  color: #a9c4c2;
  margin-bottom: .9rem;
}
.page-hero .breadcrumb a { color: var(--accent-300); }

/* 9. ------------------------------------------------------------------ CARDS */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(18px, 2.5vw, 28px);
}
.cards.cols-3 { grid-template-columns: repeat(3, 1fr); }
.cards.cols-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: #d4e3df; }

.card-media { aspect-ratio: 16 / 10; overflow: hidden; background: var(--cream-2); }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.card:hover .card-media img { transform: scale(1.05); }

.card-body { padding: clamp(20px, 2.4vw, 28px); display: flex; flex-direction: column; flex: 1; }
.card-body h3 { margin-bottom: .4rem; }
.card-body p { color: var(--ink-muted); }

/* Feature card variant (icon, no image) for why-us grid */
.feature {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: clamp(20px, 2.4vw, 28px);
  transition: transform .2s ease, box-shadow .2s ease;
}
.feature:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.feature .feature-icon {
  width: 50px; height: 50px;
  display: grid; place-items: center;
  border-radius: 12px;
  background: rgba(24,164,91,.12);
  color: var(--accent-600);
  margin-bottom: 16px;
  font-size: 1.5rem;
}
.feature h3 { font-size: 1.18rem; margin-bottom: .35rem; }
.feature p { color: var(--ink-muted); margin: 0; }

/* "Read more" inline link with arrow */
.link-more {
  margin-top: auto;
  padding-top: 14px;
  display: inline-flex;
  align-items: center;
  gap: .4em;
  font-family: var(--font-head);
  font-weight: 600;
  color: var(--accent-600);
}
.link-more::after { content: "→"; transition: transform .2s ease; }
.card:hover .link-more::after { transform: translateX(4px); }

/* 10. ------------------------------------------------------------------ STEPS */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: clamp(18px, 2.5vw, 28px);
  counter-reset: step;
}
.step {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 30px 24px 24px;
}
.step::before {
  counter-increment: step;
  content: counter(step);
  display: grid; place-items: center;
  width: 44px; height: 44px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.15rem;
  color: #fff;
  background: var(--grad-accent);
  border-radius: 12px;
  box-shadow: 0 6px 14px rgba(24,164,91,.3);
  margin-bottom: 16px;
}
.step h3 { font-size: 1.15rem; margin-bottom: .3rem; }
.step p { color: var(--ink-muted); margin: 0; }

/* 11. ------------------------------------------------------------------ STATS */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: clamp(16px, 3vw, 36px);
  text-align: center;
}
.stat .stat-num {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(2rem, 4vw, 2.9rem);
  line-height: 1;
  color: var(--accent-300);
}
.section:not(.section-deep) .stat .stat-num { color: var(--accent-600); }
.stat .stat-label { font-size: .98rem; color: inherit; opacity: .92; margin-top: .4rem; }

/* 12. ------------------------------------------------------------------ SPLIT */
/* Image + text two-column band. Inner devs reuse for service pages. */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: clamp(28px, 5vw, 64px);
}
.split.reverse .split-media { order: 2; }
.split-media {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.split-media img {
  width: 100%;
  height: 100%;
  aspect-ratio: 4 / 3.2;
  object-fit: cover;
}
.split-body h2 { margin-bottom: .5rem; }

/* Checklist used inside split / sections */
.checklist { list-style: none; margin: 18px 0 0; padding: 0; }
.checklist li {
  position: relative;
  padding: 8px 0 8px 34px;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
}
.checklist li:last-child { border-bottom: 0; }
.checklist li::before {
  content: "✓";
  position: absolute;
  left: 0; top: 8px;
  width: 22px; height: 22px;
  display: grid; place-items: center;
  font-size: .8rem; font-weight: 800;
  color: var(--accent-600);
  background: rgba(24,164,91,.14);
  border-radius: 999px;
}

/* 13. -------------------------------------------------------------------- FAQ */
.faq { max-width: 820px; margin-inline: auto; display: grid; gap: 14px; }
.faq details {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.faq summary {
  list-style: none;
  cursor: pointer;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.06rem;
  color: var(--ink);
  padding: 20px 56px 20px 22px;
  position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 22px; top: 50%;
  transform: translateY(-50%);
  font-size: 1.5rem;
  line-height: 1;
  color: var(--accent-600);
  transition: transform .2s ease;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details > p { margin: 0; padding: 0 22px 22px; color: var(--ink-muted); }

/* 14. --------------------------------------------------------------- CTA BAND */
.cta-band {
  background: var(--grad-accent);
  color: #fff;
  text-align: center;
  border-radius: var(--radius-lg);
  padding: clamp(40px, 6vw, 70px) clamp(22px, 5vw, 60px);
  box-shadow: var(--shadow);
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.92); max-width: 56ch; margin-inline: auto; }
.cta-band .btn-primary {
  background: #fff;
  color: var(--accent-600);
  box-shadow: 0 10px 26px rgba(0,0,0,.18);
}
.cta-band .btn-primary:hover { color: var(--accent-600); background: #fff; }
.cta-band .btn-ghost { color: #fff; border-color: rgba(255,255,255,.6); }
.cta-band .btn-ghost:hover { background: rgba(255,255,255,.14); border-color: #fff; }
.cta-band .btn-row { justify-content: center; margin-top: 26px; }

/* 15. ----------------------------------------------------------------- FOOTER */
.site-footer {
  background: var(--brand-deep);
  color: #b9cfcc;
  padding-block: clamp(48px, 6vw, 72px) 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.3fr;
  gap: clamp(28px, 4vw, 48px);
}
.site-footer .brand { color: #fff; margin-bottom: 14px; }
.site-footer .brand b { color: var(--accent-300); }
.footer-pitch { color: #95b2ae; max-width: 34ch; }
.footer-col h4 {
  font-size: .82rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #7fa19c;
  margin-bottom: 14px;
}
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-col a { color: #cfe0dd; }
.footer-col a:hover { color: #fff; }
.footer-contact a { color: #fff; font-weight: 600; }
.footer-bottom {
  margin-top: clamp(36px, 5vw, 52px);
  border-top: 1px solid rgba(255,255,255,.12);
  padding-block: 22px clamp(74px, 9vw, 28px); /* extra bottom space for mobile callbar */
  font-size: .9rem;
  color: #86a4a0;
  text-align: center;
}

/* 16. -------------------------------------------------------- MOBILE CALL BAR */
.callbar {
  display: none; /* shown <=720px */
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 200;
  background: var(--grad-accent);
  color: #fff;
  text-align: center;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.05rem;
  padding: 14px 16px;
  box-shadow: 0 -6px 20px rgba(0,0,0,.18);
  text-decoration: none;
  letter-spacing: .01em;
}
.callbar:hover { color: #fff; text-decoration: none; }

/* 17. ----------------------------------------------------------- RESPONSIVE */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-media { max-width: 520px; margin-inline: auto; order: -1; }
  .split, .split.reverse { grid-template-columns: 1fr; }
  .split.reverse .split-media { order: -1; }
  .cards.cols-3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  /* Collapse nav into CSS-only mobile menu */
  .burger { display: block; }
  .nav-links {
    position: fixed;
    inset: 70px 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    padding: 10px 16px 18px;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transition: max-height .3s ease, opacity .25s ease, visibility .25s ease;
  }
  .nav-links a { padding: .85em .6em; border-radius: 8px; font-size: 1.05rem; }
  .nav-cta { margin: 8px 0 0; text-align: center; }
  .nav-toggle:checked ~ .nav-links {
    max-height: 80vh;
    opacity: 1;
    visibility: visible;
  }
  /* Burger morph into X when open */
  .nav-toggle:checked ~ .burger span { background: transparent; }
  .nav-toggle:checked ~ .burger span::before { transform: translate(-50%, 0) rotate(45deg); }
  .nav-toggle:checked ~ .burger span::after  { transform: translate(-50%, 0) rotate(-45deg); }
}

@media (max-width: 720px) {
  body { font-size: 16px; }
  .callbar { display: block; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .btn-row .btn { flex: 1 1 auto; }
}

@media (max-width: 520px) {
  .footer-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
}

/* 18. ------------------------------------------------------- REDUCED MOTION */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}
