/* ==========================================================================
   Erko Entreprenad — designsystem
   ========================================================================== */

:root {
  --orange: #E85D1C;
  --orange-dark: #C43A0D;
  --orange-light: #FF8A52;
  --gradient: linear-gradient(100deg, var(--orange) 0%, var(--orange-dark) 100%);

  --ink: #33383E;
  --ink-soft: #5B6169;
  --ink-faint: #8E939A;

  --paper: #FFFFFF;
  --stone: #F5F1EA;
  --stone-line: #E7E0D5;
  --line: #E5E3E0;

  --night: #201D1B;
  --night-soft: #2C2724;
  --night-line: #3D3733;

  --amber: #92650A;
  --amber-soft: #F5EAD2;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 18px 40px -20px rgba(24, 18, 12, 0.35);
  --shadow-sm: 0 8px 20px -12px rgba(24, 18, 12, 0.3);

  --font-display: "Archivo", "Arial Black", sans-serif;
  --font-body: "Public Sans", "Segoe UI", sans-serif;

  --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
svg { width: 1em; height: 1em; flex-shrink: 0; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
button { font-family: inherit; cursor: pointer; }

a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 2px;
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.12;
  margin: 0 0 0.5em;
  text-wrap: balance;
  color: var(--ink);
}

h1 { font-size: clamp(34px, 5vw, 58px); }
h2 { font-size: clamp(26px, 3.4vw, 40px); }
h3 { font-size: clamp(19px, 2.2vw, 24px); }

p { margin: 0 0 1em; max-width: 62ch; }
p.lead { font-size: 19px; color: var(--ink-soft); max-width: 56ch; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 14px;
}
.eyebrow::before {
  content: "";
  width: 22px; height: 3px;
  background: var(--gradient);
  border-radius: 2px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 26px;
  border-radius: 100px;
  font-weight: 700;
  font-size: 16px;
  border: 2px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}
.btn-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn-ghost {
  background: transparent;
  border-color: rgba(255,255,255,0.55);
  color: #fff;
}
.btn-ghost:hover { background: rgba(255,255,255,0.12); }
.btn-outline {
  background: transparent;
  border-color: var(--line);
  color: var(--ink);
}
.btn-outline:hover { border-color: var(--orange); color: var(--orange); }
.btn-block { width: 100%; justify-content: center; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.site-header .inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 24px;
  max-width: var(--container);
  margin: 0 auto;
  gap: 24px;
}
.logo-link { display: flex; align-items: center; }
.logo-link img { height: 72px; width: auto; }

.main-nav { display: flex; align-items: center; gap: 30px; }
.main-nav ul { display: flex; gap: 26px; }
.main-nav a {
  font-weight: 600; font-size: 15px; color: var(--ink-soft);
  padding: 6px 0; border-bottom: 2px solid transparent;
}
.main-nav a:hover, .main-nav a[aria-current="page"] { color: var(--orange); border-color: var(--orange); }

.header-actions { display: flex; align-items: center; gap: 14px; }
.phone-link {
  display: flex; align-items: center; gap: 8px;
  font-weight: 700; font-size: 15px; color: var(--ink);
}
.phone-link svg { width: 18px; height: 18px; color: var(--orange); }

.nav-toggle {
  display: none;
  flex-direction: column;
  align-items: center; justify-content: center;
  gap: 5px;
  background: none; border: none;
  width: 40px; height: 40px;
  cursor: pointer;
}
.nav-toggle span, .nav-toggle::before, .nav-toggle::after {
  content: ""; display: block; width: 22px; height: 2px; background: var(--ink);
  border-radius: 1px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle[aria-expanded="true"] span { opacity: 0; }
.nav-toggle[aria-expanded="true"]::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"]::after { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  color: #fff;
  min-height: 640px;
  display: flex; align-items: flex-end;
  overflow: hidden;
}
.hero-media { position: absolute; inset: 0; }
.hero-media img, .hero-media video {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover;
}
@media (prefers-reduced-motion: reduce) {
  .hero-media video { display: none; }
}

.hero-media::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(20,15,12,0.14) 0%, rgba(18,13,10,0.34) 55%, rgba(16,12,9,0.64) 100%);
}
.hero-content {
  position: relative;
  padding: 100px 24px 64px;
  max-width: var(--container);
  margin: 0 auto;
  width: 100%;
}
.hero h1 { color: #fff; max-width: 16ch; }
.hero .lead { color: rgba(255,255,255,0.88); font-size: 20px; max-width: 52ch; }
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 28px; }

/* ---------- Sections ---------- */
section { padding: 84px 0; }
section.tight { padding: 56px 0; }
.section-stone { background: var(--stone); }
.section-night { background: var(--night); color: #fff; }
.section-night h2, .section-night h3 { color: #fff; }
.section-night p { color: rgba(255,255,255,0.78); }

.section-head { max-width: 680px; margin: 0 0 48px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

/* ---------- Service cards ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 22px;
}
.service-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
  display: flex; flex-direction: column;
}
.service-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.service-card .thumb { aspect-ratio: 4/3; overflow: hidden; background: var(--stone); }
.service-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.service-card .body { padding: 22px 22px 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.service-card h3 { margin: 0; font-size: 20px; }
.service-card p { margin: 0; color: var(--ink-soft); font-size: 15px; }
.service-card .more { margin-top: auto; font-weight: 700; color: var(--orange); font-size: 14.5px; display: flex; align-items: center; gap: 6px; }
.service-card .more svg { width: 14px; height: 14px; transition: transform 0.15s; }
.service-card:hover .more svg { transform: translateX(3px); }

.tag {
  display: inline-block;
  font-size: 12.5px; font-weight: 700;
  padding: 4px 11px; border-radius: 100px;
  background: rgba(232,93,28,0.1); color: var(--orange);
  margin-bottom: 4px;
}

/* ---------- Why-us / trust ---------- */
.trust-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 30px;
}
.trust-item { display: flex; gap: 16px; }
.trust-item .icon {
  flex-shrink: 0; width: 46px; height: 46px; border-radius: 12px;
  background: var(--gradient);
  display: flex; align-items: center; justify-content: center;
}
.trust-item .icon svg { width: 22px; height: 22px; color: #fff; }
.trust-item h3 { font-size: 17px; margin-bottom: 6px; }
.trust-item p { font-size: 14.5px; color: var(--ink-soft); margin: 0; }

/* ---------- Project gallery ---------- */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 26px;
}
.project-card {
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--paper);
  border: 1px solid var(--line);
}
.project-card .media { aspect-ratio: 5/4; position: relative; overflow: hidden; }
.project-card .media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.project-card:hover .media img { transform: scale(1.05); }
.project-card .body { padding: 20px 22px 24px; }
.project-card .meta { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.project-card h3 { font-size: 19px; margin-bottom: 6px; }
.project-card p { font-size: 14.5px; color: var(--ink-soft); margin-bottom: 0; }

/* before/after compare */
.compare {
  position: relative;
  aspect-ratio: 4/3;
  border-radius: var(--radius);
  overflow: hidden;
  user-select: none;
  box-shadow: var(--shadow);
}
.compare img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.compare .after-wrap { position: absolute; inset: 0; overflow: hidden; width: 50%; }
.compare .after-wrap img { width: var(--compare-w, 100%); max-width: none; }
.compare .handle {
  position: absolute; top: 0; bottom: 0; left: 50%;
  width: 4px; background: #fff; transform: translateX(-2px);
  cursor: ew-resize; box-shadow: 0 0 0 3px rgba(0,0,0,0.15);
}
.compare .handle::after {
  content: "↔";
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  width: 42px; height: 42px; border-radius: 50%; background: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; color: var(--ink); box-shadow: 0 4px 14px rgba(0,0,0,0.25);
}
.compare .label {
  position: absolute; top: 14px; padding: 5px 12px; border-radius: 100px;
  font-size: 12.5px; font-weight: 700; letter-spacing: 0.03em;
  background: rgba(12,25,23,0.72); color: #fff; text-transform: uppercase;
}
.compare .label.before { left: 14px; }
.compare .label.after { right: 14px; }

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--gradient);
  color: #fff;
  border-radius: 20px;
  padding: 52px 40px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 30px; flex-wrap: wrap;
}
.cta-band h2 { color: #fff; margin-bottom: 6px; }
.cta-band p { color: rgba(255,255,255,0.9); margin: 0; }
.cta-band .btn-primary { background: #fff; color: var(--orange-dark); }

/* ---------- Area / map section ---------- */
.area-list { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.area-list .pill {
  font-size: 14px; font-weight: 600; padding: 8px 16px;
  border-radius: 100px; border: 1px solid var(--line); background: var(--paper);
}
.area-list .pill.primary { border-color: var(--orange); color: var(--orange); background: rgba(232,93,28,0.06); }

/* ---------- FAQ ---------- */
.faq-item {
  border-bottom: 1px solid var(--line);
  padding: 20px 0;
}
.faq-item summary {
  cursor: pointer; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 20px;
  font-weight: 700; font-size: 17px; font-family: var(--font-display);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+"; font-size: 24px; color: var(--orange); flex-shrink: 0; font-weight: 400;
  transition: transform 0.2s;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .a { padding-top: 12px; color: var(--ink-soft); max-width: 68ch; }

/* ---------- Forms ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }

label { display: block; font-weight: 700; font-size: 14px; margin-bottom: 7px; }
label .opt { font-weight: 400; color: var(--ink-faint); }
input, select, textarea {
  width: 100%; padding: 13px 15px; border-radius: var(--radius-sm);
  border: 1.5px solid var(--line); font-family: inherit; font-size: 15px;
  background: var(--paper); color: var(--ink);
}
input:focus, select:focus, textarea:focus { border-color: var(--orange); }
textarea { resize: vertical; min-height: 120px; }
.file-drop {
  border: 2px dashed var(--line); border-radius: var(--radius-sm);
  padding: 24px; text-align: center; color: var(--ink-faint); font-size: 14px;
}
.checkbox-row { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--ink-soft); }
.checkbox-row input { width: 18px; height: 18px; margin-top: 2px; flex-shrink: 0; }
.form-note { font-size: 13px; color: var(--ink-faint); margin-top: 6px; }

.confirm-box {
  display: none;
  background: var(--stone); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; text-align: center;
}
.confirm-box.show { display: block; }

/* ---------- Footer ---------- */
.site-footer { background: var(--night); color: rgba(255,255,255,0.78); }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  padding-top: 64px;
  padding-bottom: 40px;
}
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
.footer-grid h4 {
  color: #fff; font-family: var(--font-body); font-size: 14px;
  letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 16px;
}
.footer-grid li { margin-bottom: 10px; font-size: 14.5px; }
.footer-grid a:hover { color: #fff; }
.footer-logo img { height: 64px; margin-bottom: 16px; }
.footer-grid p { color: rgba(255,255,255,0.6); font-size: 14px; }
.footer-bottom {
  border-top: 1px solid var(--night-line);
  padding-top: 22px;
  padding-bottom: 22px;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  font-size: 13px; color: rgba(255,255,255,0.5);
}
.footer-bottom a:hover { color: #fff; }
.social-row { display: flex; gap: 12px; margin-top: 16px; }
.social-row a {
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(255,255,255,0.08); display: flex; align-items: center; justify-content: center;
}
.social-row svg { width: 17px; height: 17px; }

/* ---------- Sticky mobile CTA ---------- */
.mobile-cta {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 60;
  display: none; gap: 10px; padding: 10px 14px;
  background: rgba(255,255,255,0.97); border-top: 1px solid var(--line);
  backdrop-filter: blur(8px);
}
.mobile-cta .btn { flex: 1; padding: 13px 10px; font-size: 14.5px; }

/* ---------- Breadcrumb ---------- */
.breadcrumb { font-size: 13.5px; color: var(--ink-faint); margin-bottom: 18px; }
.breadcrumb a:hover { color: var(--orange); }

/* ---------- Placeholder / TODO markers (dev only, remove for launch) ---------- */
.todo-flag {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--amber-soft); color: var(--amber);
  font-size: 12.5px; font-weight: 700; padding: 3px 10px; border-radius: 100px;
  margin-left: 8px; vertical-align: middle;
}

/* ---------- Utility ---------- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
@media (max-width: 860px) { .grid-2 { grid-template-columns: 1fr; gap: 32px; } }
.img-frame { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .main-nav {
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    padding: 8px 24px 16px;
  }
  .main-nav.is-open { display: block; }
  .main-nav ul { flex-direction: column; gap: 2px; }
  .main-nav a { display: block; padding: 14px 4px; border-bottom: 1px solid var(--line); }
  .nav-toggle { display: flex; }
  .header-actions .phone-link span { display: none; }
  .mobile-cta { display: flex; }
  body { padding-bottom: 64px; }
  section { padding: 60px 0; }
  .cta-band { padding: 36px 24px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
