/* =============================================
   heihenriikkx.fi — shared stylesheet
   ============================================= */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #e5e5e5;
  --white: #ffffff;
  --dark: #1a1a1a;
  --mid: #666;
  --light-text: #999;
  --max-w: 820px;
  --side-margin: 12px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  font-family: 'Nunito Sans', sans-serif;
  color: var(--dark);
  font-weight: 300;
  line-height: 1.6;
}

a { color: #000; letter-spacing: 1px; text-decoration: none; }
a:hover { color: #444; }

/* ── NAV ── */
.nav-outer {
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 100;
}

nav {
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 44px;
  height: 60px;
  max-width: var(--max-w);
  margin: 0 auto;
  box-shadow: 0 1px 0 rgba(0,0,0,0.07);
  position: relative;
}

.nav-links { display: flex; gap: 36px; list-style: none; }

.nav-links a {
  text-decoration: none;
  color: var(--dark);
  font-family: 'Nunito Sans', sans-serif;
  font-size: 12.5px;
  font-weight: 400;
  letter-spacing: 0.04em;
  transition: opacity 0.2s;
}
.nav-links a:hover { opacity: 0.45; }
.nav-links li:first-child a { text-decoration: underline; text-underline-offset: 3px; }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
}
.hamburger span {
  display: block;
  width: 23px;
  height: 2px;
  background: var(--dark);
  transition: all 0.3s;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  display: none;
  position: fixed;
  top: 60px;
  left: 0;
  right: 0;
  background: var(--white);
  padding: 20px 28px;
  z-index: 99;
  box-shadow: 0 4px 24px rgba(0,0,0,0.1);
  flex-direction: column;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  text-decoration: none;
  color: var(--dark);
  font-size: 14px;
  padding: 13px 0;
  border-bottom: 1px solid #eee;
  font-family: 'Nunito Sans', sans-serif;
  font-weight: 400;
}

/* ── PAGE WRAP ── */
.page-wrap {
  background: var(--white);
  max-width: var(--max-w);
  margin: 0 auto;
}

/* ── HERO ── */
.hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding: 52px 44px 44px;
  gap: 22px;
  align-items: start;
}

.hero h1 {
  font-family: 'Big Shoulders Display', sans-serif;
  font-size: clamp(40px, 6vw, 58px);
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  color: var(--dark);
  margin-bottom: 18px;
}

.hero p {
  font-size: 11.5px;
  color: var(--mid);
  line-height: 1.75;
  max-width: 230px;
  margin-bottom: 26px;
}

.hero-btns {
  display: flex;
  gap: 11px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.btn-primary {
  background: var(--dark);
  color: #fff;
  border: none;
  padding: 10px 22px;
  font-family: 'Nunito Sans', sans-serif;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  cursor: pointer;
  border-radius: 2px;
  transition: opacity 0.2s;
  text-decoration: none;
  display: inline-block;
}
.btn-primary:hover { opacity: 0.7; }

.btn-outline {
  background: transparent;
  color: var(--dark);
  border: 1.5px solid #ccc;
  padding: 9px 18px;
  font-family: 'Nunito Sans', sans-serif;
  font-size: 11.5px;
  font-weight: 400;
  cursor: pointer;
  border-radius: 2px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s;
  text-decoration: none;
}
.btn-outline:hover { border-color: var(--dark); }

.play-icon {
  width: 0;
  height: 0;
  border-top: 4.5px solid transparent;
  border-bottom: 4.5px solid transparent;
  border-left: 8px solid var(--dark);
  flex-shrink: 0;
}

/* Instagram card */
.ig-card {
  display: flex;
  align-items: center;
  gap: 11px;
  background: #f8f8f8;
  border: 1px solid #ebebeb;
  border-radius: 6px;
  padding: 9px 13px;
  max-width: 210px;
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.2s, border-color 0.2s;
}
.ig-card:hover { box-shadow: 0 2px 10px rgba(0,0,0,0.08); border-color: #d0d0d0; }

.ig-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: var(--dark);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.ig-icon svg { width: 20px; height: 20px; fill: white; }
.ig-text { font-size: 10px; color: var(--light-text); line-height: 1.5; }
.ig-text strong { display: block; font-size: 10.5px; color: var(--dark); font-weight: 600; margin-bottom: 1px; }

/* Hero image */
.hero-image { width: 100%; overflow: hidden; }
.hero-image img {
  width: 100%;
  height: auto;
  max-height: 420px;
  object-fit: cover;
  display: block;
}

/* ── ABOUT ── */
.about {
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding: 44px;
  gap: 0;
  align-items: center;
  border-top: 1px solid #f2f2f2;
}

.about-image { width: 100%; overflow: hidden; }
.about-image img {
  width: 100%;
  height: auto;
  max-height: 420px;
  object-fit: cover;
  display: block;
}

.about-content { padding-left: 44px; }

.about h2 {
  font-family: 'Big Shoulders Display', sans-serif;
  font-size: clamp(40px, 6vw, 58px);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 1;
  margin-bottom: 18px;
}

.about p {
  font-size: 11.5px;
  color: var(--mid);
  line-height: 1.8;
  margin-bottom: 26px;
}

/* ── SLIDESHOW (portfolio page) ── */
.slideshow {
  width: 100%;
  position: relative;
  background: #bbb;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  cursor: pointer;
}

.slideshow::after {
  content: '';
  position: absolute;
  top: 8px;
  right: 8px;
  width: 22px;
  height: 22px;
  background: rgba(255,255,255,0.7) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231a1a1a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7'/%3E%3C/svg%3E") center/14px no-repeat;
  border-radius: 3px;
  pointer-events: none;
}

.slideshow-track {
  display: flex;
  height: 100%;
  transition: transform 0.6s ease;
}

.slide {
  min-width: 100%;
  flex-shrink: 0;
  position: relative;
  height: 100%;
}

.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: grayscale(100%) contrast(0.85) brightness(1.25);
  transition: filter 0.4s ease, opacity 0.3s ease;
}

.slide-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0,0,0,0.5);
  color: #fff;
  font-family: 'Nunito Sans', sans-serif;
  font-size: 10px;
  font-weight: 300;
  line-height: 1.4;
  padding: 8px 38px 8px 10px;
  letter-spacing: 0.02em;
}

.slide-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.72);
  border: none;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  transition: background 0.2s;
}
.slide-btn:hover { background: rgba(255,255,255,0.95); }
.slide-btn.prev { left: 6px; }
.slide-btn.next { right: 6px; }
.slide-btn svg {
  width: 12px;
  height: 12px;
  stroke: #1a1a1a;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ── LIGHTBOX (portfolio page) ── */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.92);
  z-index: 1000;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.lightbox.open { display: flex; }

.lb-inner {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  width: 100%;
  max-width: min(96vw, 920px);
}

.lb-content {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}

.lb-img-wrap { width: 100%; }

.lb-img-wrap img {
  width: 100%;
  max-height: 75vh;
  object-fit: contain;
  display: block;
}

.lb-caption {
  width: 100%;
  background: rgba(0,0,0,0.6);
  color: rgba(255,255,255,0.85);
  font-family: 'Nunito Sans', sans-serif;
  font-size: 11px;
  font-weight: 300;
  line-height: 1.5;
  padding: 10px 14px;
  letter-spacing: 0.03em;
  text-align: left;
}

.lb-counter {
  margin-top: 10px;
  font-family: 'Nunito Sans', sans-serif;
  font-size: 11px;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.1em;
}

.lb-btn {
  background: rgba(255,255,255,0.12);
  border: none;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s;
  align-self: center;
}
.lb-btn:hover { background: rgba(255,255,255,0.25); }
.lb-btn svg {
  width: 18px;
  height: 18px;
  stroke: #fff;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.lb-close {
  position: fixed;
  top: 14px;
  right: 16px;
  background: none;
  border: none;
  color: rgba(255,255,255,0.7);
  font-size: 28px;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s;
}
.lb-close:hover { color: #fff; }

/* ── SERVICES ── */
.services {
  padding: 44px 44px 60px;
  border-top: 1px solid #f2f2f2;
}

.services-header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 44px;
  margin-bottom: 44px;
  align-items: start;
}

.services-header h2 {
  font-family: 'Big Shoulders Display', sans-serif;
  font-size: clamp(20px, 5.5vw, 35px);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 1;
}

.services-header p {
  font-size: 11.5px;
  color: var(--mid);
  line-height: 1.8;
  padding-top: 4px;
}

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

.service-item h3 {
  font-family: 'Big Shoulders Display', sans-serif;
  font-size: 14px;
  letter-spacing: 1px;
  font-weight: 600;
  margin-bottom: 7px;
}

.service-item p {
  font-size: 11px;
  color: var(--light-text);
  line-height: 1.7;
}

/* CV body (portfolio page) */
.cv-body { font-size: 11.5px; color: var(--mid); line-height: 1.8; }

.cv-body h3 {
  font-family: 'Big Shoulders Display', sans-serif;
  font-size: 14px;
  letter-spacing: 1px;
  font-weight: 600;
  color: var(--dark);
  margin-top: 18px;
  margin-bottom: 6px;
}
.cv-body h3:first-child { margin-top: 0; }

.cv-body p { font-size: 11.5px; color: var(--mid); line-height: 1.8; }

/* ── FOOTER ── */
.footer-outer { background: var(--bg); }

footer {
  background: var(--dark);
  color: rgba(133, 131, 132, 0.66);
  text-align: center;
  padding: 20px;
  font-size: 11px;
  letter-spacing: 0.08em;
  font-family: 'Nunito Sans', sans-serif;
  max-width: var(--max-w);
  margin: 0 auto;
}

/* ── MOBILE ── */
@media (max-width: 680px) {

  .nav-outer { padding: 0 var(--side-margin); }

  nav {
    max-width: 100%;
    padding: 0 20px;
    box-shadow: none;
    margin: 0;
  }

  .nav-links { display: none; }
  .hamburger { display: flex; }

  .page-wrap { margin: 0 var(--side-margin); }
  footer { max-width: 100%; margin: 0 var(--side-margin); }

  /* Hero */
  .hero {
    grid-template-columns: 1fr 1fr;
    padding: 50px 14px 18px;
    gap: 12px;
    align-items: start;
  }
  .hero h1 { font-size: clamp(24px, 8vw, 36px); margin-bottom: 8px; }
  .hero p { font-size: 9.5px; max-width: 100%; margin-bottom: 12px; line-height: 1.55; }

  .hero-btns {
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 6px;
    margin-bottom: 12px;
  }
  .btn-primary { font-size: 9px; padding: 6px 10px; white-space: nowrap; }
  .btn-outline { font-size: 9px; padding: 5px 8px; white-space: nowrap; }
  .play-icon { border-top-width: 3.5px; border-bottom-width: 3.5px; border-left-width: 5px; }

  .ig-card { max-width: 100%; padding: 7px 9px; gap: 7px; }
  .ig-icon { width: 30px; height: 30px; border-radius: 5px; }
  .ig-icon svg { width: 15px; height: 15px; }
  .ig-text { font-size: 8.5px; }
  .ig-text strong { font-size: 9px; }
  .hero-image img { max-height: 260px; }

  /* About */
  .about {
    grid-template-columns: 1fr 1fr;
    padding: 18px 14px;
    gap: 0;
  }
  .about-image img { max-height: 260px; }
  .about-content { padding-left: 12px; }
  .about h2 { font-size: clamp(24px, 8vw, 36px); margin-bottom: 8px; }
  .about p { font-size: 9.5px; margin-bottom: 12px; line-height: 1.6; }
  .about .btn-primary { font-size: 9.5px; padding: 7px 12px; }

  /* Slideshow */
  .slide-caption { font-size: 8.5px; padding: 6px 32px 6px 8px; }
  .slide-btn { width: 22px; height: 22px; }
  .slide-btn svg { width: 9px; height: 9px; }

  /* Lightbox */
  .lb-btn { width: 32px; height: 32px; }
  .lb-btn svg { width: 14px; height: 14px; }

  /* Services */
  .services { padding: 22px 14px 36px; }
  .services-header { grid-template-columns: 1fr; gap: 10px; margin-bottom: 22px; }
  .services-header h2 { font-size: 20px; }
  .services-header p { font-size: 11px; }
  .services-grid { grid-template-columns: repeat(2, 1fr); gap: 18px; }
}

@media (min-width: 681px) {
  .hamburger { display: none; }
}