/* ================================================================
   02. PAGE SECTIONS
   Hero, Prosjekter, Tilbud, Om meg, Kontakt, footer, inbox,
   fade-in motion and the basic mobile layout.

   Files load in number order (01 → 12). Later files override
   earlier ones, so keep the order when moving rules around.
   ================================================================ */

/* ===== HERO ===== */
.hero {
  display: grid;
  grid-template-columns: minmax(0,1.4fr) minmax(0,1fr);
  gap: clamp(20px,3vw,40px);
  align-items: stretch;
}

.hero-main {
  display: flex;
  flex-direction: column;
  gap: 30px;
  justify-content: center;
  padding: clamp(8px,2vw,24px) 0;
}

.hero-main>.pill {
  align-self: flex-start;
}

.hero-main h1 {
  margin-top: 4px;
}

.hero-main .lead {
  font-size: clamp(17px,1.4vw,19px);
  color: #3f4659;
  max-width: 32em;
}

.cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 10px;
}

.stat {
  display: flex;
  align-items: flex-start;
  gap: 6px;
}

.stat .dot {
  font-size: clamp(34px,3.6vw,46px);
}

.stat .pill {
  margin-top: 2px;
}

/* timeline */
.tl {
  position: relative;
  margin-top: 10px;
  max-width: 520px;
}

.tl-dots {
  display: grid;
  grid-template-columns: repeat(14,1fr);
  align-items: center;
  height: 16px;
  gap: 2px;
}

.tl-dots i {
  justify-self: center;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #d3d0c5;
  transition: background .4s;
}

.tl-dots i.on {
  background: var(--ink);
}

.tl-dots i.last {
  background: var(--y);
  width: 9px;
  height: 9px!important;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(245,213,71,.3);
}

.tl-lab {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
}

.tl-flag {
  position: absolute;
  top: -16px;
  left: 50%;
  transform: translateX(-50%);
  background: #fff;
  border-radius: 999px;
  padding: 7px 14px;
  box-shadow: 0 10px 24px -10px rgba(15,23,36,.35);
  white-space: nowrap;
  font-size: 13.5px;
  display: flex;
  gap: 8px;
  align-items: center;
}

.tl-flag small {
  color: var(--mut);
  font-family: "IBM Plex Mono",monospace;
  font-size: 11px;
}

.hero-side {
  display: grid;
}

.glow {
  border-radius: var(--rc);
  position: relative;
  overflow: hidden;
  padding: 24px;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 300px;
  background: #f7f2dc;
}

.glow::before {
  content: "";
  position: absolute;
  inset: -30%;
  background: radial-gradient(closest-side at 50% 58%,#f5d547 0%,rgba(245,213,71,.65) 38%,rgba(255,241,200,.3) 62%,rgba(247,242,220,0) 80%);
  filter: blur(6px);
  animation: breathe 7s ease-in-out infinite;
}

.glow>* {
  position: relative;
}

.glow .big {
  text-align: center;
}

.glow .big .dot {
  font-size: clamp(84px,9vw,124px);
  color: #fff;
  text-shadow: 0 2px 18px rgba(170,130,0,.35);
}

.glow .big p {
  margin-top: 6px;
  font-size: 14px;
  color: #5a4a0c;
}

.ruler {
  display: flex;
  justify-content: space-between;
  align-items: end;
  height: 30px;
}

.ruler i {
  width: 1.5px;
  height: 12px;
  background: rgba(15,23,36,.25);
}

.ruler i:nth-child(5n+1) {
  height: 20px;
}

.ruler i.now {
  height: 30px;
  width: 3px;
  background: var(--ink);
}

@keyframes breathe {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.08);
  }
}

.mini {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
}

.mini .row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.live {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #3fbf6f;
  box-shadow: 0 0 0 0 rgba(63,191,111,.5);
  animation: ping 2.2s infinite;
  flex: none;
}

@keyframes ping {
  0% {
    box-shadow: 0 0 0 0 rgba(63,191,111,.5);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(63,191,111,0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(63,191,111,0);
  }
}

.track {
  position: relative;
  height: 4px;
  border-radius: 2px;
  background: var(--soft);
  margin: 8px 0 2px;
}

.track b {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 8%;
  background: var(--y);
  border-radius: 2px;
}

.track b::after {
  content: "";
  position: absolute;
  right: -6px;
  top: -4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--y);
}

/* ===== PROSJEKTER ===== */
.projects {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 16px;
}

.proj {
  padding: 12px;
}

.shot {
  aspect-ratio: 16/10;
  border-radius: 18px;
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
}

.shot.g1 {
  background: radial-gradient(closest-side at 50% 60%,#9fd98a,#cfe8c0 55%,#eef0e6);
}

.shot.g2 {
  background: radial-gradient(closest-side at 50% 60%,#f4a3b5,#f6cfd8 55%,#f3ece9);
}

.shot img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shot .pill {
  position: absolute;
  left: 14px;
  top: 14px;
}

.shot .ph {
  background: rgba(255,255,255,.75);
  backdrop-filter: blur(6px);
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--mut);
}

.proj-body {
  padding: 20px 10px 8px;
}

.proj-body p {
  color: #3f4659;
  margin: 8px 0 16px;
}

.tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.note {
  margin-top: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ===== TILBUD ===== */
.pkgs {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 16px;
  align-items: stretch;
}

.pkg {
  display: flex;
  flex-direction: column;
  padding: 26px;
}

.pkg h3 {
  font-size: 24px;
  margin: 14px 0 18px;
}

.pkg ul {
  list-style: none;
  margin: 0 0 22px;
  padding: 0;
  display: grid;
  gap: 9px;
  flex: 1;
  align-content: start;
  color: #3f4659;
}

.pkg li {
  padding-left: 22px;
  position: relative;
}

.pkg li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: .55em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 2px solid var(--ink);
  opacity: .5;
}

.pkg .del {
  background: var(--panel);
  border-radius: 16px;
  padding: 14px 16px;
  margin-bottom: 18px;
}

.pkg .del .row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.pkg .del .dot {
  font-size: 30px;
}

.price {
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -.03em;
  white-space: nowrap;
}

.price .est {
  display: block;
  font-family: "IBM Plex Mono",ui-monospace,monospace;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  opacity: .7;
  margin-bottom: -2px;
  line-height: 1;
}

.pkg .btn {
  margin-top: 18px;
  width: 100%;
}

.pkg.hl {
  background: #fff;
  box-shadow: 0 0 0 2px var(--y),0 30px 60px -28px rgba(160,120,0,.45);
}

.pkg.hl::before {
  content: "";
  position: absolute;
  inset: auto -30% -55% -30%;
  height: 70%;
  background: radial-gradient(closest-side,rgba(245,213,71,.45),rgba(245,213,71,0));
  pointer-events: none;
}

.pkg.hl>* {
  position: relative;
}

.pkg.hl li::before {
  border-color: #c9a400;
  opacity: 1;
}

/* ===== OM MEG ===== */
.about {
  display: grid;
  grid-template-columns: minmax(0,1fr) minmax(0,1.4fr);
  gap: clamp(24px,5vw,72px);
  align-items: start;
}

.facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.about .card {
  padding: 28px;
}

.about p.big {
  font-size: clamp(17px,1.5vw,20px);
  line-height: 1.6;
  color: #3f4659;
}

.list {
  display: grid;
  gap: 10px;
  margin-top: 22px;
}

.list div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  background: var(--card);
  border-radius: 18px;
  padding: 13px 16px;
  box-shadow: var(--sh);
  font-size: 15px;
}

.me {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 28px;
  background: #f7f2dc;
}

.me::before {
  content: "";
  position: absolute;
  inset: -20%;
  background: radial-gradient(closest-side at 40% 60%,#f5d547,rgba(245,213,71,.4) 50%,rgba(247,242,220,0) 78%);
  animation: breathe 8s ease-in-out infinite;
}

.me>* {
  position: relative;
}

.me .dot {
  font-size: clamp(60px,7vw,96px);
  color: #fff;
  text-shadow: 0 2px 18px rgba(170,130,0,.35);
}

/* ===== KONTAKT ===== */
.contact {
  background: var(--y);
  color: var(--ink);
  border-radius: var(--r);
  margin-top: 14px;
  padding: clamp(24px,4vw,56px);
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0,1fr) minmax(0,1.05fr);
  gap: clamp(24px,5vw,72px);
  align-items: start;
}

.contact h2 {
  font-size: clamp(32px,4vw,54px);
}

.contact .lead {
  color: #3a3410;
  font-size: 18px;
  margin: 20px 0 28px;
  max-width: 26em;
}

.direct {
  display: grid;
  gap: 12px;
  justify-items: start;
}

.direct a.mail {
  font-size: 20px;
  font-weight: 600;
  word-break: break-all;
}

form {
  background: var(--card);
  color: var(--txt);
  border-radius: var(--rc);
  padding: clamp(20px,3vw,32px);
  box-shadow: 0 30px 60px -30px rgba(80,60,0,.45);
}

.fields {
  display: grid;
  gap: 16px;
}

label {
  display: grid;
  gap: 7px;
}

label .mono {
  color: var(--mut);
}

input,
textarea {
  font: 16px/1.5 "Zalando Sans",sans-serif;
  color: var(--txt);
  background: var(--panel);
  border: 1px solid transparent;
  border-radius: 14px;
  padding: 13px 16px;
  width: 100%;
  transition: border-color .2s,background .2s;
}

input:focus,
textarea:focus {
  background: #fff;
  border-color: #d8d4c8;
}

textarea {
  min-height: 130px;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: #9a9fab;
}

.two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

form .btn {
  justify-self: start;
}

.err {
  color: #b3261e;
  font-size: 14.5px;
}

.err:empty {
  display: none;
}

.thanks {
  padding: 0;
  opacity: 0;
  transform: scale(.6);
  filter: blur(4px);
  transition: opacity .25s,transform .25s,filter .25s,padding .6s;
}

.thanks h3 {
  font-size: 32px;
  margin: 12px 0 10px;
}

/* sent state: the form stretches downwards like the call island (grid rows animate, same spring curve) */
form {
  display: grid;
  grid-template-rows: 1fr 0fr;
  transition: grid-template-rows .75s cubic-bezier(.34,1.45,.5,1);
}

form>.fields,
form>.thanks {
  min-height: 0;
  overflow: hidden;
}

form>.fields {
  transition: opacity .25s,transform .25s,filter .25s;
}

form.sent {
  grid-template-rows: 0fr 1fr;
}

form.sent>.fields {
  opacity: 0;
  transform: scale(.6);
  filter: blur(4px);
  padding-top: 0;
  padding-bottom: 0;
}

form.sent .thanks {
  padding: 10px 0;
  opacity: 1;
  transform: none;
  filter: none;
  transition: opacity .35s .3s,transform .5s .28s cubic-bezier(.34,1.45,.5,1),filter .35s .3s,padding .6s;
}

@media (prefers-reduced-motion:reduce) {
  form,
  form>.fields,
  .thanks {
    transition: none;
  }
}

/* footer */
footer {
  padding: 26px 12px 10px;
  color: var(--mut);
}

footer .fwrap {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  justify-content: space-between;
}

footer b {
  color: var(--txt);
}

/* inbox */
.inbox {
  display: none;
}

body.show-inbox .inbox {
  display: block;
}

.inbox .card {
  margin-bottom: 12px;
}

.inbox .card p {
  white-space: pre-wrap;
  margin-top: 8px;
  color: #3f4659;
}

/* motion */
.fade {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .8s cubic-bezier(.2,.7,.2,1),transform .8s cubic-bezier(.2,.7,.2,1);
}

.fade.in {
  opacity: 1;
  transform: none;
}

.card.lift {
  transition: transform .3s,box-shadow .3s;
}

.card.lift:hover {
  transform: translateY(-4px);
  box-shadow: 0 1px 0 rgba(255,255,255,.9) inset,0 28px 50px -24px rgba(15,23,36,.45);
}

@media (prefers-reduced-motion:reduce) {
  .fade {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .glow::before,
  .live {
    animation: none;
  }
  .btn,
  .card.lift {
    transition: none;
  }
}

@media (max-width:1199px) {
  .hero,
  .about,
  .contact-grid {
    grid-template-columns: minmax(0,1fr);
  }
  .hero-side {
    grid-template-columns: minmax(0,1.3fr) minmax(0,1fr);
    grid-template-rows: auto;
  }
  .pkgs {
    grid-template-columns: minmax(0,1fr);
  }
}

@media (max-width:1199px) {
  .shell {
    grid-template-columns: minmax(0,1fr);
    padding: 10px;
  }
  .side {
    position: sticky;
    top: 0;
    z-index: 30;
    height: auto;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    padding: 8px 8px 8px 16px;
    border-radius: 999px;
    background: rgba(15,23,36,.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 10px 30px -18px rgba(15,23,36,.4);
  }
  .side .logo {
    padding: 0;
    flex: none;
    max-width: 40vw;
  }
  .side-tabs {
    display: none;
  }
  .nav {
    display: flex;
    overflow-x: auto;
    scrollbar-width: none;
    flex: 1;
    gap: 4px;
  }
  .nav::-webkit-scrollbar {
    display: none;
  }
  .nav a {
    flex: none;
    min-height: 40px;
    padding: 0 12px;
    border-radius: 999px;
    font-size: 14px;
  }
  .nav a .pill {
    display: none;
  }
  .promo {
    margin: 0;
    padding: 0;
    background: none;
    box-shadow: none;
    flex: none;
  }
  .promo>*:not(.btn) {
    display: none;
  }
}

@media (max-width:1199px) {
  .side .nav {
    display: none;
  }
  .side {
    justify-content: space-between;
  }
  .hero-side,
  .projects,
  .two {
    grid-template-columns: minmax(0,1fr);
  }
  .stats {
    grid-template-columns: repeat(2,minmax(0,1fr));
    row-gap: 18px;
  }
  .tl {
    display: none;
  }
  .glow {
    min-height: 260px;
  }
  form .btn,
  .cta .btn {
    width: 100%;
  }
  .nav a .lab i {
    display: none;
  }
}
