
/* ==========================================
   BOX800 - STYLE.CSS
========================================== */

:root {
  --blue: #c6ccd6;
  --black: #090b0d;
  --dark: #15191d;
  --white: #fff;
  --muted: #c3c7cc;
  --max: 1200px;
}

/* GRUNNSTILLINGAR */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 85px;
}

body {
  margin: 0;
  background: var(--black);
  color: var(--white);
  font-family: "Inter", Arial, sans-serif;
  line-height: 1.6;
}

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

button {
  font: inherit;
}

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

.container {
  width: min(calc(100% - 44px), var(--max));
  margin: auto;
}

h1,
h2,
h3 {
  font-family: "Barlow Condensed", Impact, sans-serif;
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: 0.015em;
}

h2 {
  font-size: clamp(43px, 6vw, 82px);
  margin: 20px 0 28px;
}

h2 span {
  color: var(--blue);
}

.section {
  padding: 100px 0;
}

.kicker,
.eyebrow {
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 2px;
}

.subtle,
.edit-note {
  color: #9ea7ae;
  font-size: 13px;
}

/* ==========================================
   1. FORSÍÐA
========================================== */

.hero {
  min-height: 710px;
  min-height: min(820px, calc(100svh - 80px));
  position: relative;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: #171b20;
}

.hero-photo {
  position: absolute;
  inset: 0;

  background-image:
    linear-gradient(
      90deg,
      rgba(4, 6, 8, 0.94) 0%,
      rgba(4, 6, 8, 0.75) 38%,
      rgba(4, 6, 8, 0.20) 100%
    ),
    url("images/forsida.webp");

  background-position: center, 65% center;
  background-size: cover;
  background-repeat: no-repeat;
}

.hero-content {
  position: relative;
  z-index: 1;
  padding: 100px 0 120px;
}

.hero h1 {
  font-size: clamp(52px, 7.5vw, 108px);
  max-width: 1040px;
  margin: 24px 0;
}

.hero h1 em {
  color: var(--blue);
  font-style: normal;
}

.hero p {
  font-size: 17px;
  max-width: 485px;
  color: #e4e6e8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

/* HNAPPAR */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 22px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.5px;
  transition:
    transform 0.2s ease,
    background 0.2s ease;
}

.btn:hover {
  transform: translateY(-3px);
}

.btn-primary {
  background: var(--blue);
  color: #101215;
}

.btn-primary:hover {
  background: #e6e9ef;
}

.btn-outline {
  border: 1px solid #d6d6d6;
  color: #fff;
}

.btn-outline:hover {
  background: #fff;
  color: #111;
}

.hero-scroll {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  justify-content: space-between;
  z-index: 2;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.5px;
}

/* ==========================================
   2. AFSLÁTTARBORÐI
========================================== */

.ticker {
  display: block;
  background: var(--blue);
  color: #101215;
  overflow: hidden;
  padding: 12px 0;
  text-decoration: none;
  cursor: pointer;
}

.ticker-track {
  display: flex;
  width: max-content;
  font: 800 27px "Barlow Condensed", sans-serif;
  letter-spacing: 2px;
  white-space: nowrap;
  animation: slide 22s linear infinite;
}

.ticker-track span {
  padding-right: 12px;
}

@keyframes slide {
  to {
    transform: translateX(-50%);
  }
}

.ticker:hover {
  background: #e6e9ef;
}

.ticker:focus-visible {
  outline: 3px solid #fff;
  outline-offset: -3px;
}

/* ==========================================
   3. UM OKKUR
========================================== */

.about {
  background: var(--dark);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 70px;
}

.about-copy p {
  color: var(--muted);
  max-width: 510px;
}

.text-link {
  display: inline-block;
  margin-top: 18px;
  font-size: 12px;
  font-weight: 800;
  border-bottom: 2px solid var(--blue);
  padding-bottom: 8px;
}

.about-photos {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  align-items: center;
}

.about-photos img {
  width: 100%;
  height: 380px;
  object-fit: cover;
}

.about-photos img:last-child {
  height: 315px;
  transform: translateY(34px);
}

/* ==========================================
   4. ÆFINGAR OG NÁMSKEIÐ
========================================== */

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 35px;
}

.section-heading p {
  max-width: 250px;
  color: var(--muted);
}

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

.program-card {
  position: relative;
  height: 470px;
  min-width: 0;
  overflow: hidden;
  isolation: isolate;
  background: #23282d;
}

.program-card > img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.4s ease;
}

/* SÉRSTÖK STAÐSETNING HYROX MYNDAR */

.program-card-hyrox > img {
  object-position: 50% 35%;
}

.program-card:hover > img {
  transform: scale(1.06);
}

.program-shade {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.94) 0%,
    rgba(0, 0, 0, 0.55) 48%,
    rgba(0, 0, 0, 0.05) 100%
  );
}

.program-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 2;
  padding: 22px;
}

.program-content > span {
  font-size: 11px;
  color: var(--blue);
  font-weight: 800;
  letter-spacing: 1px;
}

.program-content h3 {
  font-size: clamp(29px, 2.8vw, 43px);
  margin: 12px 0;
}

.program-content p {
  font-size: 14px;
  color: #e2e2e2;
  line-height: 1.5;
}

.program-content a {
  font-size: 12.5px;
  font-weight: 800;
  color: var(--blue);
}

.program-content a:hover {
  color: #fff;
}

.edit-note {
  margin-top: 22px;
}

/* ==========================================
   5. MYNDASAFN
========================================== */

.training-gallery {
  background: #090b0d;
}

.gallery-heading {
  margin-bottom: 40px;
}

.gallery-heading h2 {
  font-size: clamp(48px, 7vw, 95px);
  line-height: 1.08;
  margin: 18px 0 25px;
}

.gallery-heading p {
  color: #c3c7cc;
  max-width: 560px;
  font-size: 16px;
  line-height: 1.7;
}

.training-gallery-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 14px;
}

.gallery-photo {
  position: relative;
  height: 450px;
  overflow: hidden;
  background: #15191d;
}

.gallery-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.5s ease;
}

.gallery-photo:hover img {
  transform: scale(1.05);
}

/* ==========================================
   6. SAMFÉLAGSMYNDIR
========================================== */

.community {
  background: var(--dark);
}

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

.community-grid img {
  height: 430px;
  width: 100%;
  object-fit: cover;
}

/* ==========================================
   7. UPPLÝSINGAKAFLAR
========================================== */

.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 70px;
  align-items: center;
}

.detail-grid p {
  max-width: 470px;
  color: var(--muted);
  margin-bottom: 25px;
}

.details-alt {
  background: var(--dark);
}

/* ==========================================
   8. SKRÁNING / SAMBAND
========================================== */

.contact {
  text-align: center;
  background: linear-gradient(145deg, #202831, #090b0d);
}

.contact-inner {
  max-width: 820px;
}

.contact h2 {
  font-size: clamp(58px, 9vw, 112px);
}

.contact p {
  max-width: 510px;
  margin: 20px auto 30px;
  color: var(--muted);
}

/* ==========================================
   9. SPJALDTÖLVUR
========================================== */

@media (max-width: 1050px) {
  .program-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .program-content h3 {
    font-size: 40px;
  }
}

@media (max-width: 900px) {
  .training-gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .gallery-photo {
    height: 350px;
  }

  .gallery-photo-large {
    grid-column: 1 / -1;
    height: 420px;
  }
}

/* ==========================================
   10. FARSÍMAR
========================================== */

@media (max-width: 760px) {
  .container {
    width: min(calc(100% - 32px), var(--max));
  }

  .section {
    padding: 70px 0;
  }

  /* FORSÍÐUMYND */

  .hero {
    min-height: 690px;
  }

  .hero-photo {
    background-image:
      linear-gradient(
        180deg,
        rgba(4, 6, 8, 0.30) 0%,
        rgba(4, 6, 8, 0.58) 45%,
        rgba(4, 6, 8, 0.88) 100%
      ),
      url("images/forsida.webp");

    background-size: cover, auto 130%;
    background-position: center, center bottom;
    background-repeat: no-repeat;
  }

  .hero-content {
    padding: 85px 0 110px;
  }

  .hero h1 {
    font-size: clamp(43px, 9vw, 70px);
  }

  .hero p {
    font-size: 15px;
  }

  /* UM OKKUR */

  .about-grid,
  .detail-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .about-photos img {
    height: 300px;
  }

  .about-photos img:last-child {
    height: 260px;
  }

  .section-heading {
    display: block;
  }

  /* ÆFINGAKORT */

  .program-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }

  .program-card {
    width: 100%;
    height: 440px;
    min-height: 440px;
    max-height: 440px;
  }

  .program-card > img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
  }

  /* HYROX MYND Í SÍMA */

  .program-card-hyrox > img {
    object-position: 50% 25%;
  }

  .program-shade {
    background: linear-gradient(
      to top,
      rgba(0, 0, 0, 0.92) 0%,
      rgba(0, 0, 0, 0.35) 55%,
      rgba(0, 0, 0, 0.08) 100%
    );
  }

  .program-content {
    position: absolute;
    inset: auto 0 0;
    padding: 28px;
  }

  .program-content h3 {
    font-size: clamp(36px, 9vw, 45px);
    line-height: 1.05;
  }

  .program-content p {
    font-size: 13px;
    line-height: 1.5;
  }

  .community-grid img {
    height: 260px;
  }
}

/* ==========================================
   11. MINNI SÍMAR
========================================== */

@media (max-width: 600px) {
  .gallery-heading h2 {
    font-size: clamp(42px, 10vw, 65px);
  }

  .training-gallery-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .gallery-photo {
    height: 230px;
  }

  .gallery-photo-large {
    grid-column: 1 / -1;
    height: 320px;
  }
}

@media (max-width: 500px) {
  .hero h1 {
    font-size: clamp(35px, 9.3vw, 48px);
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-scroll {
    font-size: 9px;
  }

  .community-grid {
    grid-template-columns: 1fr 1fr;
  }

  .community-grid img {
    height: 240px;
  }

  .community-grid img:last-child {
    display: none;
  }
}

/* ==========================================
   12. MINNI HREYFING
========================================== */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .ticker-track {
    animation: none;
  }

  .program-card > img,
  .gallery-photo img,
  .btn {
    transition: none;
  }
}
