/* ====================================================================
   HLJÓÐVEST — styles
   ==================================================================== */

:root {
  --bg:        #08090b;
  --bg-2:      #0c0e12;
  --surface:   #13161c;
  --surface-2: #1a1e26;
  --border:    #262b34;
  --text:      #f2f4f7;
  --muted:     #99a2b0;
  --accent:    #45c4e0;
  --accent-2:  #4361ee;
  --accent-grad: linear-gradient(120deg, #45c4e0, #4361ee);

  --maxw: 1180px;
  --nav-h: 72px;
  --radius: 16px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3 { font-family: 'Space Grotesk', system-ui, sans-serif; line-height: 1.1; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* offset for fixed nav when scrolling to anchors */
section[id] { scroll-margin-top: var(--nav-h); }

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
}

/* ===================== BUTTONS ===================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.01em;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform .15s ease, box-shadow .25s ease, background .25s ease, border-color .25s ease;
}
.btn--sm { padding: 9px 18px; font-size: 14px; }
.btn--primary {
  background: var(--accent-grad);
  color: #04121a;
  box-shadow: 0 8px 24px -8px rgba(69, 196, 224, .55);
}
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 14px 32px -8px rgba(69, 196, 224, .7); }
.btn--ghost {
  background: rgba(255, 255, 255, .03);
  border-color: var(--border);
  color: var(--text);
}
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }

/* ===================== NAV ===================== */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--nav-h);
  z-index: 100;
  display: flex;
  align-items: center;
  transition: background .3s ease, border-color .3s ease, backdrop-filter .3s ease;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(8, 9, 11, .82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--border);
}
.nav__inner {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { display: flex; align-items: center; gap: 11px; color: var(--text); }
.brand__logo { height: 26px; width: auto; display: block; }
.brand__logo--footer { height: 22px; }
.brand__mark { color: var(--accent); display: flex; }
.brand__name {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 19px;
  letter-spacing: 0.14em;
}
.nav__links { display: flex; align-items: center; gap: 30px; }
.nav__links > a {
  font-size: 15px;
  font-weight: 500;
  color: var(--muted);
  position: relative;
  transition: color .2s ease;
}
.nav__links > a:hover { color: var(--text); }
.nav__links > a.is-active { color: var(--text); }
.nav__links > a.is-active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -8px;
  height: 2px;
  background: var(--accent-grad);
  border-radius: 2px;
}
.nav__social { display: flex; align-items: center; gap: 14px; padding-left: 6px; }
.nav__social a { color: var(--muted); transition: color .2s ease, transform .2s ease; }
.nav__social a:hover { color: var(--accent); transform: translateY(-2px); }

.nav__toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav__toggle span { width: 24px; height: 2px; background: var(--text); border-radius: 2px; transition: transform .3s ease, opacity .3s ease; }
.nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===================== HERO ===================== */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--nav-h) 24px 60px;
  overflow: hidden;
}
.hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; }
.hero__glow {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(60% 50% at 50% 38%, rgba(67, 97, 238, .22), transparent 70%),
    radial-gradient(50% 40% at 50% 60%, rgba(69, 196, 224, .12), transparent 70%);
  pointer-events: none;
}
.hero__content { position: relative; z-index: 2; max-width: 760px; }
.hero__content .eyebrow { margin-bottom: 22px; }
.hero__logo { margin: 0; line-height: 0; }
.hero__logo img {
  width: min(86vw, 640px);
  height: auto;
  margin: 0 auto;
  display: block;
  filter: drop-shadow(0 0 60px rgba(69, 196, 224, .22));
}
.hero__title {
  font-size: clamp(54px, 12vw, 132px);
  font-weight: 700;
  letter-spacing: 0.04em;
  background: linear-gradient(180deg, #ffffff, #aeb6c2);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 60px rgba(69, 196, 224, .18);
}
.hero__tagline {
  margin: 26px auto 0;
  max-width: 580px;
  font-size: clamp(16px, 2.2vw, 19px);
  color: var(--muted);
}
.hero__cta { margin-top: 38px; display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

.hero__scroll {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  width: 26px;
  height: 42px;
  border: 2px solid var(--border);
  border-radius: 14px;
  display: flex;
  justify-content: center;
}
.hero__scroll span {
  width: 4px; height: 8px;
  background: var(--accent);
  border-radius: 2px;
  margin-top: 7px;
  animation: scrollDot 1.6s ease-in-out infinite;
}
@keyframes scrollDot { 0%,100% { opacity: 0; transform: translateY(0); } 40% { opacity: 1; } 80% { opacity: 0; transform: translateY(12px); } }

/* ===================== SECTIONS ===================== */
.section { padding: clamp(72px, 11vw, 140px) 0; position: relative; }
.section--alt { background: var(--bg-2); border-block: 1px solid var(--border); }
.section__head { max-width: 680px; margin-bottom: 56px; }
.section__head .eyebrow { margin-bottom: 16px; }
.section__title { font-size: clamp(34px, 5.5vw, 56px); font-weight: 700; }
.section__lead { margin-top: 18px; color: var(--muted); font-size: 17px; }
.section__lead em { color: var(--muted); opacity: .8; }
.section__foot {
  margin-top: 54px;
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
  padding: 28px 32px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.section__foot p { font-weight: 500; font-size: 17px; }

/* ===================== GRIDS / CARDS ===================== */
.grid { display: grid; gap: 20px; }
.grid--cards { grid-template-columns: repeat(3, 1fr); }
.grid--products { grid-template-columns: repeat(3, 1fr); }
.grid--projects { grid-template-columns: repeat(3, 1fr); }

/* ----- vörur (leigusíða) ----- */
.product {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .2s ease, border-color .2s ease;
}
.product:hover { transform: translateY(-4px); border-color: var(--accent); }
.product__img {
  aspect-ratio: 4 / 3;
  background: #ffffff;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  padding: 16px;
}
.product__img img { width: 100%; height: 100%; object-fit: contain; display: block; transition: transform .3s ease; }
.product:hover .product__img img { transform: scale(1.03); }
.product__img span { font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: #9aa3b0; }
.product__body { padding: 20px 22px 24px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.product__head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.product__head h3 { font-size: 19px; }
.product__price {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 600;
  font-size: 16px;
  color: var(--accent);
  white-space: nowrap;
}
.product__price small { color: var(--muted); font-size: 12px; font-weight: 500; }
.product__price--quote {
  font-size: 13px;
  border: 1px solid rgba(69, 196, 224, .3);
  background: rgba(69, 196, 224, .08);
  padding: 4px 12px;
  border-radius: 999px;
}
.product__body p { color: var(--muted); font-size: 14.5px; }
.grid-empty { grid-column: 1 / -1; color: var(--muted); font-size: 16px; padding: 28px 2px; }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 28px;
  display: flex;
  flex-direction: column;
  color: var(--text);
  text-decoration: none;
  transition: transform .2s ease, border-color .2s ease, background .2s ease;
}
.card:hover { transform: translateY(-4px); border-color: var(--accent); background: var(--surface-2); }
.card__more { margin-top: auto; padding-top: 16px; color: var(--accent); font-weight: 600; font-size: 14px; }
.card:hover .card__more { letter-spacing: .02em; }

/* ----- undirsíður (leiga/*) ----- */
.subpage { min-height: 100vh; }
.backlink {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--muted); font-size: 15px; font-weight: 500;
  transition: color .2s ease, gap .2s ease;
}
.backlink:hover { color: var(--accent); gap: 12px; }
.cat-nav { display: flex; flex-wrap: wrap; gap: 10px; margin: -20px 0 46px; }
.cat-pill {
  padding: 9px 18px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
  transition: color .2s ease, border-color .2s ease, background .2s ease, transform .15s ease;
}
.cat-pill:hover { color: var(--text); border-color: var(--accent); transform: translateY(-2px); }
.cat-pill.is-active { background: var(--accent-grad); color: #04121a; border-color: transparent; }
.card__icon {
  width: 52px; height: 52px;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px;
  border-radius: 12px;
  background: rgba(69, 196, 224, .1);
  border: 1px solid rgba(69, 196, 224, .2);
  margin-bottom: 20px;
}
.card h3 { font-size: 20px; margin-bottom: 8px; }
.card p { color: var(--muted); font-size: 15px; }

/* projects */
.project {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .2s ease, border-color .2s ease;
}
.project:hover { transform: translateY(-4px); border-color: var(--accent); }
.project__img {
  aspect-ratio: 16 / 10;
  position: relative;
  background: #0c0e12;
  overflow: hidden;
}
.project__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 42%;
  display: block;
  transition: transform .4s ease;
}
.project:hover .project__img img { transform: scale(1.04); }
.project__body { padding: 22px 24px 26px; }
.tag {
  display: inline-block;
  font-size: 12px; font-weight: 600; letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(69, 196, 224, .1);
  border: 1px solid rgba(69, 196, 224, .22);
  padding: 4px 12px; border-radius: 999px;
  margin-bottom: 14px;
}
.project__body h3 { font-size: 20px; margin-bottom: 8px; }
.project__body p { color: var(--muted); font-size: 15px; }

/* ===================== CONTACT ===================== */
.contact { display: grid; grid-template-columns: 1fr 1.2fr; gap: 28px; align-items: start; }
.contact__info {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 28px 28px;
}
.contact__row {
  display: flex; flex-direction: column; gap: 4px;
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
}
.contact__row:last-of-type { border-bottom: 0; }
.contact__label { font-size: 12px; text-transform: uppercase; letter-spacing: .18em; color: var(--muted); }
.contact__value { font-size: 20px; font-family: 'Space Grotesk', sans-serif; font-weight: 500; }
a.contact__row:hover .contact__value { color: var(--accent); }
.contact__value a:hover { color: var(--accent); }
.contact__socials { display: flex; gap: 12px; margin-top: 22px; }

.contact__form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 30px 32px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.contact__form label { display: flex; flex-direction: column; gap: 8px; font-size: 14px; font-weight: 500; color: var(--muted); }
.contact__form input,
.contact__form textarea {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 13px 15px;
  color: var(--text);
  font: inherit;
  font-size: 15px;
  transition: border-color .2s ease, box-shadow .2s ease;
  resize: vertical;
}
.contact__form input:focus,
.contact__form textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(69, 196, 224, .15);
}
.contact__form .btn { margin-top: 4px; }
.contact__note { font-size: 14px; color: var(--accent); }

/* ===================== FOOTER ===================== */
.footer { border-top: 1px solid var(--border); padding: 40px 0; background: var(--bg-2); }
.footer__inner { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; justify-content: space-between; }
.brand--footer .brand__name { font-size: 17px; }
.footer__links { display: flex; gap: 24px; }
.footer__links a { color: var(--muted); font-size: 14px; transition: color .2s ease; }
.footer__links a:hover { color: var(--text); }
.footer__social { display: flex; gap: 14px; }
.footer__social a { color: var(--muted); transition: color .2s ease, transform .2s ease; }
.footer__social a:hover { color: var(--accent); transform: translateY(-2px); }
.footer__copy { color: var(--muted); font-size: 14px; width: 100%; text-align: center; padding-top: 8px; }

/* ===================== RESPONSIVE ===================== */
@media (max-width: 900px) {
  .grid--cards, .grid--products, .grid--projects { grid-template-columns: repeat(2, 1fr); }
  .contact { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .nav__toggle { display: flex; }
  .nav__links {
    position: fixed;
    top: var(--nav-h); left: 0; right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: rgba(8, 9, 11, .97);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
    padding: 8px 24px 22px;
    transform: translateY(-120%);
    transition: transform .35s cubic-bezier(.4,0,.2,1);
    z-index: 90;
  }
  .nav__links.open { transform: translateY(0); }
  .nav__links > a { width: 100%; padding: 14px 0; font-size: 17px; border-bottom: 1px solid var(--border); }
  .nav__links > a.is-active::after { display: none; }
  .nav__social { padding: 16px 0 0; }
}

@media (max-width: 560px) {
  .grid--cards, .grid--products, .grid--projects { grid-template-columns: 1fr; }
  .section__foot { flex-direction: column; align-items: flex-start; }
  .footer__inner { justify-content: center; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero__scroll span { animation: none; }
}
