/* Nagu Tak & Bygg Oy — self-contained styles (no external fonts/CDN) */

:root {
  --bg: #faf8f5;
  --bg-alt: #f1ebe1;
  --ink: #171512;
  --muted: #6b6560;
  --line: #e4ddd2;
  --accent: #b5551f;
  --accent-ink: #93451a;
  --white: #ffffff;
  --radius: 14px;
  --maxw: 1120px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, "Helvetica Neue", sans-serif;
  --shadow: 0 1px 2px rgba(23,21,18,.05), 0 8px 30px rgba(23,21,18,.06);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

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

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

h1, h2, h3 { line-height: 1.15; letter-spacing: -.02em; margin: 0 0 .4em; font-weight: 700; }

.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: clamp(1.1rem, 4vw, 2.5rem); }

.sr-only, .skip-link:not(:focus) {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: 1rem; top: 1rem; z-index: 100;
  background: var(--ink); color: var(--white); padding: .6rem 1rem; border-radius: 8px;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250,248,245,.86);
  backdrop-filter: saturate(150%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 1.2rem; height: 72px; }

.brand { display: inline-flex; align-items: center; color: var(--ink); }
.brand__logo { height: 46px; width: auto; display: block; }

.nav { margin-left: auto; }
.nav__list { display: flex; gap: 1.6rem; list-style: none; margin: 0; padding: 0; }
.nav__list a { color: var(--muted); font-weight: 500; font-size: .96rem; transition: color .15s; }
.nav__list a:hover, .nav__list a:focus-visible { color: var(--ink); }
.nav__toggle { display: none; }

.lang { display: inline-flex; gap: .15rem; margin-left: .4rem; background: var(--bg-alt); border-radius: 999px; padding: .2rem; }
.lang__btn {
  border: 0; background: transparent; color: var(--muted); font: inherit; font-size: .8rem; font-weight: 600;
  padding: .3rem .6rem; border-radius: 999px; cursor: pointer; transition: all .15s;
}
.lang__btn:hover { color: var(--ink); }
.lang__btn.is-active { background: var(--ink); color: var(--white); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 600; font-size: .98rem; padding: .8rem 1.4rem; border-radius: 999px;
  cursor: pointer; border: 1.5px solid transparent; transition: transform .12s, background .15s, border-color .15s;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--accent); color: var(--white); }
.btn--primary:hover { background: var(--accent-ink); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--ink); }

.eyebrow {
  text-transform: uppercase; letter-spacing: .14em; font-size: .74rem; font-weight: 700;
  color: var(--accent-ink); margin: 0 0 .8rem;
}

/* ---------- Hero (full-bleed photo) ---------- */
.hero {
  position: relative; isolation: isolate;
  display: flex; align-items: flex-end;
  min-height: min(88vh, 760px);
  padding: clamp(2.5rem, 7vw, 5rem) 0 clamp(2.5rem, 6vw, 4.5rem);
  background: var(--ink); color: #fff;
  overflow: hidden;
}
.hero__media { position: absolute; inset: 0; z-index: -2; }
.hero__media img { width: 100%; height: 100%; object-fit: cover; }
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(23,21,18,.25) 0%, rgba(23,21,18,.35) 45%, rgba(23,21,18,.86) 100%);
}
.hero__inner { width: 100%; }
.hero__text { max-width: 40ch; }
.hero .eyebrow { color: #f2c14e; }
.hero h1 { font-size: clamp(2.1rem, 5.4vw, 3.6rem); text-shadow: 0 2px 24px rgba(0,0,0,.35); }
.lead { font-size: clamp(1.05rem, 1.6vw, 1.26rem); color: rgba(255,255,255,.9); max-width: 40ch; margin: 0 0 1.6rem; }
.hero__actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-bottom: 1.6rem; }
.btn--onphoto { color: #fff; border-color: rgba(255,255,255,.55); background: rgba(255,255,255,.06); backdrop-filter: blur(2px); }
.btn--onphoto:hover { border-color: #fff; background: rgba(255,255,255,.14); }
.hero__badges { display: flex; flex-wrap: wrap; gap: 1.2rem 1.6rem; list-style: none; margin: 0; padding: 0; }
.hero__badges li { position: relative; padding-left: 1.4rem; font-size: .92rem; color: rgba(255,255,255,.92); }
.hero__badges li::before { content: "✓"; position: absolute; left: 0; color: #f2c14e; font-weight: 700; }

/* ---------- Sections ---------- */
.section { padding: clamp(3rem, 7vw, 5.5rem) 0; }
.section--alt { background: var(--bg-alt); }
.section__head { max-width: 46ch; margin-bottom: 2.4rem; }
.section__head h2 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); }
.section__intro { color: var(--muted); font-size: 1.08rem; margin: 0; }

/* ---------- Service cards ---------- */
.cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.1rem; }
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.6rem 1.5rem; transition: transform .15s, box-shadow .2s, border-color .2s;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: transparent; }
.card__icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 12px; background: var(--bg-alt); color: var(--accent);
  font-size: 1.2rem; margin-bottom: 1rem;
}
.card h3 { font-size: 1.16rem; }
.card p { margin: 0; color: var(--muted); font-size: .96rem; }

/* ---------- Service blocks (two categories) ---------- */
.services2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem; align-items: start; }
.service-block {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(1.5rem, 3vw, 2.1rem);
}
.service-block h3 { font-size: 1.35rem; }
.service-block__intro { color: var(--muted); font-size: 1rem; margin: 0 0 1.1rem; }
.service-block__label { font-weight: 600; margin: 1.1rem 0 .6rem; }
.service-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.1rem; }
.service-list li { padding-left: 1.1rem; border-left: 2px solid var(--accent); }
.service-list strong { display: block; margin-bottom: .2rem; }
.service-list span { color: var(--muted); font-size: .96rem; }
.service-bullets { margin: 0 0 1.1rem; padding-left: 1.2rem; display: grid; gap: .35rem; }
.service-bullets li { color: var(--ink); }
.service-bullets li::marker { color: var(--accent); }
@media (max-width: 820px) { .services2 { grid-template-columns: 1fr; } }

/* ---------- Gallery (two flex columns — images shown uncropped) ---------- */
.gallery { display: flex; gap: 1.1rem; align-items: flex-start; }
.gallery__col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1.1rem; }
.gallery__item {
  position: relative; margin: 0; border-radius: var(--radius); overflow: hidden;
  background: var(--bg); box-shadow: var(--shadow);
}
.gallery__item img { width: 100%; height: auto; display: block; transition: transform .4s ease; }
.gallery__item:hover img { transform: scale(1.04); }
.gallery__cap {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 1.4rem 1.1rem .9rem; color: #fff; font-size: .92rem; font-weight: 500;
  background: linear-gradient(180deg, transparent, rgba(23,21,18,.8));
}
@media (max-width: 640px) {
  .gallery { flex-direction: column; }
}

/* ---------- About ---------- */
.about__text { max-width: 60ch; }
.about h2 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); }
.about p { color: var(--muted); font-size: 1.06rem; }
.stats { display: flex; flex-wrap: wrap; gap: 2.4rem; list-style: none; margin: 2rem 0 0; padding: 0; }
.stats li { display: flex; flex-direction: column; }
.stats strong { font-size: 1.9rem; letter-spacing: -.03em; }
.stats span { color: var(--muted); font-size: .92rem; }

/* ---------- Reviews ---------- */
.reviews__head { max-width: 60ch; }
.reviews__summary { display: flex; align-items: center; gap: .5rem; margin: .4rem 0 0; font-size: 1.05rem; color: var(--muted); }
.reviews__summary strong { color: var(--ink); }
.reviews { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.1rem; align-items: start; }
.review { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; display: flex; flex-direction: column; gap: .7rem; }
.review__stars { font-size: 1rem; }
.review blockquote { margin: 0; font-size: 1rem; line-height: 1.55; }
.review cite { font-style: normal; font-weight: 600; font-size: .92rem; color: var(--muted); }
.reviews__cta { margin-top: 1.8rem; }

/* ---------- Steps ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.4rem; counter-reset: step; }
.step { position: relative; padding-top: .4rem; }
.step__num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 999px; border: 1.5px solid var(--accent);
  color: var(--accent-ink); font-weight: 700; margin-bottom: .9rem;
}
.step h3 { font-size: 1.1rem; }
.step p { margin: 0; color: var(--muted); font-size: .96rem; }

/* ---------- Contact ---------- */
.section--contact { background: var(--ink); color: var(--bg); }
.section--contact .eyebrow { color: #e9a23b; }
.contact { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.6rem, 5vw, 3.5rem); align-items: start; }
.contact h2 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); }
.contact__intro p { color: #cfc7bb; }
.contact__list { list-style: none; margin: 1.6rem 0 0; padding: 0; display: grid; gap: 1rem; }
.contact__list li { display: flex; flex-direction: column; }
.contact__label { text-transform: uppercase; letter-spacing: .1em; font-size: .72rem; color: #9c948a; margin-bottom: .15rem; }
.contact__list a, .contact__list li > span:last-child { font-size: 1.08rem; }
.contact__list a:hover { color: #e9a23b; }

.contact__form {
  background: var(--white); color: var(--ink); border-radius: var(--radius);
  padding: clamp(1.4rem, 3vw, 2rem); display: grid; gap: 1rem;
}
.field { display: grid; gap: .35rem; }
.field label { font-size: .88rem; font-weight: 600; }
.field input, .field textarea {
  font: inherit; padding: .7rem .85rem; border: 1.5px solid var(--line); border-radius: 10px;
  background: var(--bg); color: var(--ink); transition: border-color .15s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.field textarea { resize: vertical; }
.contact__form .btn { justify-self: start; }
.form__note { margin: 0; font-size: .84rem; color: var(--muted); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form__status { margin: 0; font-size: .92rem; font-weight: 600; min-height: 1.2em; }
.form__status.is-error { color: #c0392b; }
.form__status.is-ok { color: #1f7a44; }

/* rating badge */
.rating { display: flex; align-items: center; gap: .5rem; margin: 1.4rem 0 0; }
.rating__stars, .review__stars { color: #f2c14e; letter-spacing: 1px; }
.rating__text { font-size: .96rem; color: #cfc7bb; }
.rating__text strong { color: #fff; }

/* map */
.contact__map { margin-top: 2.2rem; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); border: 1px solid rgba(255,255,255,.08); }
.contact__map iframe { display: block; width: 100%; height: 340px; border: 0; filter: grayscale(.15); }

/* ---------- Footer ---------- */
.site-footer { background: var(--bg-alt); border-top: 1px solid var(--line); padding: 2rem 0; }
.footer-inner { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between; }
.footer__brand { display: flex; flex-direction: column; }
.footer__brand span { color: var(--muted); font-size: .9rem; }
.footer__legal { margin: 0; color: var(--muted); font-size: .86rem; display: flex; gap: .4rem; flex-wrap: wrap; }

/* ---------- Responsive ---------- */
@media (max-width: 820px) {
  .hero__inner { grid-template-columns: 1fr; }
  .hero__art { order: -1; }
  .contact { grid-template-columns: 1fr; }

  .nav__toggle {
    display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 10px;
    background: var(--white); cursor: pointer;
  }
  .nav__bars, .nav__bars::before, .nav__bars::after {
    content: ""; display: block; width: 20px; height: 2px; background: var(--ink);
    margin-inline: auto; transition: transform .2s, opacity .2s;
  }
  .nav__bars { position: relative; }
  .nav__bars::before { position: absolute; top: -6px; left: 0; right: 0; }
  .nav__bars::after { position: absolute; top: 6px; left: 0; right: 0; }
  .nav__toggle[aria-expanded="true"] .nav__bars { background: transparent; }
  .nav__toggle[aria-expanded="true"] .nav__bars::before { transform: translateY(6px) rotate(45deg); }
  .nav__toggle[aria-expanded="true"] .nav__bars::after { transform: translateY(-6px) rotate(-45deg); }

  .nav__list {
    position: absolute; left: 0; right: 0; top: 72px;
    flex-direction: column; gap: 0; background: var(--bg);
    border-bottom: 1px solid var(--line); padding: .5rem 0;
    max-height: 0; overflow: hidden; transition: max-height .25s ease;
  }
  .nav__list.is-open { max-height: 340px; }
  .nav__list li { border-top: 1px solid var(--line); }
  .nav__list a { display: block; padding: .9rem clamp(1.1rem, 4vw, 2.5rem); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
