/* ============================================
   Dronemedia.no — felles stilark
   Mørkt, kinematisk tema
   ============================================ */

:root {
  --bg:            #0a0c0f;
  --bg-alt:        #11151a;
  --bg-card:       #151a21;
  --border:        #232a33;
  --text:          #f2f4f7;
  --text-muted:    #9aa4b2;
  --accent:        #4ea8de;
  --accent-hover:  #7cc6f0;
  --max:           1180px;
  --radius:        4px;
  --ease:          cubic-bezier(0.16, 1, 0.3, 1);
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto,
               Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--accent); text-decoration: none; transition: color .2s; }
a:hover { color: var(--accent-hover); }

h1, h2, h3 {
  line-height: 1.15;
  letter-spacing: -0.02em;
  font-weight: 600;
  margin: 0 0 .6em;
}

h1 { font-size: clamp(2.4rem, 6vw, 4.4rem); }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.5rem); }
h3 { font-size: 1.15rem; }

p { margin: 0 0 1.1em; color: var(--text-muted); }

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

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .18em;
  font-size: .74rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 1rem;
}

.lead { font-size: 1.14rem; max-width: 62ch; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 12, 15, .82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.nav {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 24px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 600;
  font-size: 1.06rem;
  letter-spacing: -0.01em;
}
.logo:hover { color: var(--text); }
.logo svg { width: 24px; height: 24px; flex: none; }
.logo span small {
  display: block;
  font-size: .6rem;
  letter-spacing: .2em;
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  margin-top: -2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 34px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--text-muted);
  font-size: .93rem;
  font-weight: 500;
  position: relative;
}
.nav-links a:hover,
.nav-links a[aria-current="page"] { color: var(--text); }
.nav-links a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -6px;
  height: 2px;
  background: var(--accent);
}

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  color: var(--text);
  padding: 8px;
  cursor: pointer;
}
.nav-toggle svg { width: 24px; height: 24px; }

/* ---------- Knapper ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 13px 26px;
  border-radius: var(--radius);
  font-size: .95rem;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all .2s var(--ease);
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: #06090c;
}
.btn-primary:hover {
  background: var(--accent-hover);
  color: #06090c;
  transform: translateY(-2px);
}

.btn-ghost {
  border-color: var(--border);
  color: var(--text);
  background: transparent;
}
.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--text);
  transform: translateY(-2px);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 2rem;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: 82vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 55% at 72% 18%, rgba(78, 168, 222, .17), transparent 68%),
    radial-gradient(ellipse 90% 60% at 12% 92%, rgba(78, 168, 222, .07), transparent 70%),
    linear-gradient(170deg, #0e131a 0%, #0a0c0f 55%, #080a0d 100%);
}

/* Fint rutenett — antyder kartlegging / flyplan */
.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.028) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 78% 78% at 50% 42%, #000 35%, transparent 82%);
  -webkit-mask-image: radial-gradient(ellipse 78% 78% at 50% 42%, #000 35%, transparent 82%);
}

.hero .wrap { position: relative; padding-top: 90px; padding-bottom: 90px; }
.hero h1 { max-width: 20ch; }
.hero .lead { font-size: 1.2rem; }

/* Underside-hero (kortere) */
.hero-sm { min-height: 0; }
.hero-sm .wrap { padding-top: 82px; padding-bottom: 66px; }
.hero-sm h1 { font-size: clamp(2.1rem, 5vw, 3.2rem); }

/* ---------- Seksjoner ---------- */

.section { padding: 96px 0; }
.section-alt { background: var(--bg-alt); border-block: 1px solid var(--border); }
.section-head { max-width: 64ch; margin-bottom: 3.2rem; }

/* ---------- Rutenett / kort ---------- */

.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  transition: border-color .25s, transform .25s var(--ease);
}
.card:hover { border-color: #33404f; transform: translateY(-3px); }
.card h3 { margin-bottom: .5rem; }
.card p:last-child { margin-bottom: 0; }
.card p { font-size: .95rem; }

.card-icon {
  width: 42px; height: 42px;
  display: grid; place-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--accent);
  margin-bottom: 20px;
}
.card-icon svg { width: 21px; height: 21px; }

.tags { list-style: none; margin: 18px 0 0; padding: 0; }
.tags li {
  font-size: .89rem;
  color: var(--text-muted);
  padding: 5px 0 5px 20px;
  position: relative;
}
.tags li::before {
  content: "";
  position: absolute;
  left: 2px; top: 15px;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--accent);
  opacity: .65;
}

/* ---------- Prosess (nummerert) ---------- */

/* Kolonnene her er smale – rundt 210 px tekst. Sentrert innhold og kort
   tekst gjør at de fire kortene får omtrent samme høyde, i stedet for at
   tre av dem står med teksten øverst og et tomrom under. */
.steps .step {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 30px 22px 32px;
}

.steps .step-num {
  width: 40px;
  height: 40px;
  flex: none;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--accent);
  margin-bottom: 18px;
}

.steps .step h3 { margin-bottom: .45rem; }

.steps .step p {
  margin-bottom: 0;
  max-width: 26ch;
  text-wrap: balance;
}

/* ---------- Statistikk ---------- */

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  border-top: 1px solid var(--border);
  padding-top: 44px;
  margin-top: 60px;
}
.stat-num {
  font-size: 2.3rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--text);
  line-height: 1;
}
.stat-label {
  font-size: .84rem;
  color: var(--text-muted);
  margin-top: 8px;
  text-transform: uppercase;
  letter-spacing: .1em;
}

/* ---------- Portefølje ---------- */

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 34px;
}
.filter {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 8px 18px;
  border-radius: 999px;
  font-size: .88rem;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  transition: all .2s;
}
.filter:hover { color: var(--text); border-color: #33404f; }
.filter.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: #06090c;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.shot {
  position: relative;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-card);
  cursor: pointer;
  padding: 0;
  font-family: inherit;
  /* Knapper arver ikke tekstfarge – uten denne bruker nettleseren sin egen
     «buttontext», som er nesten svart og forsvinner mot bildet. */
  color: var(--text);
  text-align: left;
  display: block;
  width: 100%;
  transition: border-color .25s, transform .3s var(--ease);
}
.shot:hover { border-color: var(--accent); transform: translateY(-3px); }
.shot picture { display: block; width: 100%; height: 100%; }
.shot img { width: 100%; height: 100%; object-fit: cover; }
.shot.is-hidden { display: none; }

/* Plassholder til bilder kommer */
.shot-placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background:
    repeating-linear-gradient(45deg, #12171e 0 12px, #151b23 12px 24px);
}
.shot-placeholder svg { width: 34px; height: 34px; color: #33404f; }

.shot-meta {
  position: absolute;
  inset: auto 0 0 0;
  padding: 52px 18px 16px;
  /* Tre stopp i stedet for to: mørkt i bunnen, men fortsatt dekkende der
     tittelen står. Med bare to stopp ble øvre linje liggende i det halvklare
     området og fikk for lite kontrast mot lyse bilder. */
  background: linear-gradient(
    to top,
    rgba(6, 9, 12, .95) 0%,
    rgba(6, 9, 12, .82) 45%,
    rgba(6, 9, 12, 0) 100%
  );
  opacity: 0;
  transform: translateY(8px);
  transition: all .28s var(--ease);
}
.shot:hover .shot-meta,
.shot:focus-visible .shot-meta { opacity: 1; transform: none; }

/* Spill-ikon på videokort. Ligger midt i bildet og er alltid synlig,
   slik at man ser at kortet er en video før man peker på det. */
.shot-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(10, 12, 15, .58);
  border: 1px solid rgba(255, 255, 255, .32);
  color: #fff;
  pointer-events: none;
  transition: background .25s, transform .25s var(--ease);
}
.shot-play svg { width: 26px; height: 26px; margin-left: 3px; }
.shot:hover .shot-play,
.shot:focus-visible .shot-play {
  background: var(--accent);
  border-color: var(--accent);
  color: #06090c;
  transform: translate(-50%, -50%) scale(1.06);
}

.shot-meta strong {
  display: block;
  font-size: .97rem;
  font-weight: 600;
  color: var(--text);
  text-shadow: 0 1px 3px rgba(0, 0, 0, .55);
  margin-bottom: 2px;
}
.shot-meta span {
  font-size: .8rem;
  color: #c3ccd8;
  text-shadow: 0 1px 3px rgba(0, 0, 0, .55);
}

/* Lysboks */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(5, 7, 9, .95);
  display: none;
  place-items: center;
  padding: 32px;
}
.lightbox.is-open { display: grid; }
.lightbox-inner { max-width: 1100px; width: 100%; }
.lightbox img,
.lightbox video {
  width: 100%;
  max-height: 78vh;
  object-fit: contain;
  border-radius: var(--radius);
  display: block;
  background: #000;
}
/* Bare én av dem vises av gangen – JS bytter */
.lightbox img[hidden],
.lightbox video[hidden] { display: none; }
.lightbox-caption {
  text-align: center;
  margin-top: 18px;
  font-size: .92rem;
  color: var(--text-muted);
}
.lightbox-close {
  position: absolute;
  top: 22px; right: 26px;
  background: none;
  border: 1px solid var(--border);
  color: var(--text);
  width: 42px; height: 42px;
  border-radius: var(--radius);
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}
.lightbox-close:hover { border-color: var(--accent); }

/* ---------- Kontakt ---------- */

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.contact-list { list-style: none; margin: 0; padding: 0; }
.contact-list li {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
}
.contact-list li:first-child { padding-top: 0; }
.contact-list svg { width: 19px; height: 19px; color: var(--accent); flex: none; margin-top: 5px; }
.contact-list dl { margin: 0; }
.contact-list dt {
  font-size: .76rem;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--text-muted);
  margin-bottom: 3px;
}
.contact-list dd { margin: 0; font-size: 1rem; font-weight: 500; }

/* Skjema */
.field { margin-bottom: 20px; }
.field label {
  display: block;
  font-size: .84rem;
  font-weight: 600;
  margin-bottom: 8px;
  letter-spacing: .01em;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  padding: 12px 14px;
  font: inherit;
  font-size: .95rem;
  transition: border-color .2s;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent);
}
.field-hint { font-size: .8rem; color: var(--text-muted); margin: 8px 0 0; }

.form-note {
  font-size: .85rem;
  color: var(--text-muted);
  margin-top: 18px;
}

/* ---------- FAQ ---------- */

.faq details {
  border-bottom: 1px solid var(--border);
  padding: 20px 0;
}
.faq summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 1rem;
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 20px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  color: var(--accent);
  font-size: 1.3rem;
  line-height: 1;
  flex: none;
}
.faq details[open] summary::after { content: "\2212"; }
.faq details p { margin: 14px 0 0; font-size: .95rem; max-width: 72ch; }

/* ---------- CTA-banner ---------- */

.cta {
  text-align: center;
  padding: 96px 0;
  background:
    radial-gradient(ellipse 60% 100% at 50% 0%, rgba(78,168,222,.12), transparent 70%),
    var(--bg-alt);
  border-top: 1px solid var(--border);
}
.cta h2 { max-width: 24ch; margin-inline: auto; }
.cta p { max-width: 52ch; margin-inline: auto; }
.cta .btn-row { justify-content: center; }

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 56px 0 32px;
  background: var(--bg);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr;
  gap: 44px;
  margin-bottom: 42px;
}
.site-footer h4 {
  font-size: .76rem;
  text-transform: uppercase;
  letter-spacing: .13em;
  color: var(--text-muted);
  margin: 0 0 16px;
  font-weight: 600;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 10px; font-size: .93rem; }
.site-footer li a { color: var(--text-muted); }
.site-footer li a:hover { color: var(--text); }
.site-footer .muted { font-size: .93rem; max-width: 40ch; }

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: .85rem;
  color: var(--text-muted);
}

/* ---------- Tilgjengelighet ---------- */

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

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: #06090c;
  padding: 12px 20px;
  z-index: 300;
  font-weight: 600;
}
.skip-link:focus { left: 12px; top: 12px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}

/* ---------- Responsivt ---------- */

@media (max-width: 900px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .contact-layout { grid-template-columns: 1fr; gap: 48px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); row-gap: 34px; }
}

@media (max-width: 680px) {
  body { font-size: 16px; }
  .section { padding: 68px 0; }
  .hero { min-height: 0; }
  .hero .wrap { padding-top: 64px; padding-bottom: 64px; }

  .nav-toggle { display: block; }
  .nav-links {
    position: absolute;
    top: 68px; left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--bg-alt);
    border-bottom: 1px solid var(--border);
    padding: 8px 24px 20px;
    display: none;
  }
  .nav-links.is-open { display: flex; }
  .nav-links li { border-bottom: 1px solid var(--border); }
  .nav-links li:last-child { border-bottom: 0; padding-top: 14px; }
  .nav-links a { display: block; padding: 14px 0; font-size: 1rem; }
  .nav-links a[aria-current="page"]::after { display: none; }
  .nav-links .btn { width: 100%; justify-content: center; }

  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .shot-meta { opacity: 1; transform: none; }
}
