/* =========================
   BASE CSS
   ========================= */

/* ROOT / VARIABLES */
:root {
  /* Brand */
  --color-primary: #1e3a5f;
  --color-accent: #FF8A3D;

  /* Backgrounds */
  --color-bg: #ffffff;
  --color-bg-header: #f8fafc;
  --color-bg-footer: #111827;
  --color-surface: #f6f8fa;

  /* Text */
  --color-text-dark: #1f2937;
  --color-text-light: #f6f8fa;
  --color-text-muted: #6b7280;
  --color-text-muted-light: #cbd5e1;

  /* UI */
  --color-border: #e5e7eb;

  /* Sizes */
  --header-height: 90px;
  --container: 1200px;

  /* Radius */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 24px;

  /* Shadow */
  --shadow-sm: 0 2px 8px rgba(0,0,0,.06);
  --shadow-md: 0 8px 24px rgba(0,0,0,.08);

  /* Spacing */
  --space-xxs: 0.25rem;
  --space-xs: 0.5rem;
  --space-sm: 0.75rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;
}

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

html {
  scroll-behavior: smooth;
}

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

/* TYPOGRAPHY */
h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
}

p {
  margin-top: 0;
}

/* MEDIA (IMAGES / VIDEO) */
img, video, canvas, svg {
  display: block;
  max-width: 100%;
  height: auto;
}

/* LINKS */
a {
  color: inherit;
  text-decoration: none;
}

/* LISTS */
ul, ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* FORMS */
button, input, textarea, select {
  font: inherit;
}


/* LAYOUT / CONTAINER */
.container {
  width: min(var(--container), calc(100% - 2rem));
  margin-inline: auto;
}


/* SECTIONS (SPACING SYSTEM) */
.section {
  padding: 5rem 0;
}


/* BUTTONS */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;

  padding: .9rem 1.2rem;
  border-radius: var(--radius-md);

  background: var(--color-primary);
  color: var(--color-text-light);

  border: none;
  cursor: pointer;

  transition: .2s ease;
}

.btn:hover {
  background: var(--color-accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}


/* CARDS */
.card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
}


/* UTILITIES */
.text-center {
  text-align: center;
}


/* RESPONSIVE */
@media (max-width: 768px) {
  .section {
    padding: 3rem 0;
  }

  .btn {
    width: 100%;
  }
}


/* =========================
   HEADER BASE
   ========================= */

body {
  padding-top: var(--header-height);
}

.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);

  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;

  padding: 0 2rem;

  background: var(--color-bg-header);

  z-index: 1000;

  box-shadow: 0 10px 40px rgba(0,0,0,0.06);
}


/* =========================
   LOGO
   ========================= */

.logo-link {
  justify-self: start;
}

.logo {
  height: 50px;
  width: auto;
}


/* =========================
   NAVIGATION (DESKTOP)
   ========================= */

.nav {
  justify-self: center;

  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav a {
  position: relative;

  color: var(--color-text-dark);
  text-decoration: none;
  font-weight: 500;

  transition: color 0.2s ease;
}

/* underline animation */
.nav a::after {
  content: "";

  position: absolute;
  left: 0;
  bottom: -4px;

  width: 100%;
  height: 2px;

  background: var(--color-primary);

  transform: scaleX(0);
  transform-origin: center;

  transition: transform 0.2s ease;
}

.nav a:hover {
  color: var(--color-primary);
}

.nav a:hover::after {
  transform: scaleX(1);
}


/* =========================
   HEADER ACTIONS
   ========================= */

.header-actions {
  justify-self: end;

  display: flex;
  align-items: center;
  gap: 1rem;
}


/* =========================
   LANGUAGE SWITCH
   ========================= */

.lang-switch {
  position: relative;
}

.lang-btn {
  background: none;
  border: none;

  font-size: 18px;

  cursor: pointer;
}

.lang-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;

  min-width: 140px;
  padding: 8px 0;

  background: var(--color-bg-header);

  border-radius: 12px;

  box-shadow: 0 10px 30px rgba(0,0,0,0.08);

  display: flex;
  flex-direction: column;

  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);

  transition:
    opacity 0.2s ease,
    transform 0.2s ease,
    visibility 0.2s ease;
}

.lang-switch:hover .lang-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.lang-menu a {
  padding: 10px 14px;

  color: var(--color-text-dark);
  text-decoration: none;

  transition: 0.2s ease;
}

.lang-menu a:hover {
  background: var(--color-surface);
  color: var(--color-primary);
}


/* =========================
   HEADER BUTTON
   ========================= */

.btn-header {
  padding: 0.7rem 1rem;

  border-radius: 999px;

  font-size: 0.9rem;
  font-weight: 600;
}


/* =========================
   HAMBURGER
   ========================= */

.hamburger {
  display: none;

  justify-self: start;

  background: none;
  border: none;

  font-size: 28px;

  cursor: pointer;
}


/* =========================
   MOBILE MENU
   ========================= */

.mobile-menu {
  position: fixed;

  top: var(--header-height);
  left: 0;

  width: 100%;

  padding: 20px 25px;

  background: #fff;

  display: none;

  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.mobile-menu.open {
  display: block;
  animation: slideDown 0.2s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mobile-menu a {
  display: block;

  padding: 14px 0;

  color: var(--color-text-dark);
  text-decoration: none;

  font-size: 1.1rem;
  font-weight: 500;

  border-bottom: 1px solid #f1f1f1;

  transition: color 0.2s ease;
}

.mobile-menu a:hover {
  color: var(--color-primary);
}


/* =========================
   RESPONSIVE
   ========================= */

@media (max-width: 1000px) {

  .header {
    grid-template-columns: auto 1fr auto;
    padding: 0 1rem;
  }

  .hamburger {
    display: block;
  }

  .logo-link {
    justify-self: center;
  }

  .nav {
    display: none;
  }

  .header-actions {
    gap: 0.5rem;
  }

  .btn-header {
    padding: 0.6rem 0.9rem;
    font-size: 0.85rem;
  }
}


/* =========================
   FOOTER
   ========================= */

.footer {
  background: var(--color-bg-footer);
  color: var(--color-text-light);
  padding: 5rem 2rem 2rem;
}

/* GRID */
.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: start;
}

/* GENEREL KOLONNE */
.footer-col {
  display: flex;
  flex-direction: column;
}

/* KOLONNE 1 */
.footer-col:first-child {
  align-items: flex-start;
  text-align: left;
}

/* KOLONNE 2 & 3*/
.footer-center, footer-right {
  align-items: flex-start;
  text-align: left;
}

/* LOGO */
.footer-logo {
  width: 370px;
  margin-bottom: 0.5rem;
}

/* TEKST */
.footer-text {
  margin-bottom: 1rem;
}

.footer-note {
  margin-top: var(--space-xxs);
  font-size: 0.85rem;
  color: var(--color-text-muted-light);
  line-height: 1.4;
}

/* LINKS */
.footer-link {
  display: inline-block;
  width: fit-content;
  margin-top: var(--space-xxs);
  color: var(--color-text-light);
  transition: 0.2s ease;
}

.footer-link:hover {
  color: var(--color-accent);
  transform: translateX(4px);
}

/* KNAP */
.footer-btn {
  margin-top: var(--space-sm);
  width: fit-content;
  transition: 0.2s ease;
}

.footer-btn:hover {
  background: var(--color-accent);
  color: var(--color-text-light);
  transform: translateX(4px);
}

/* OVERSKRIFTER */
.footer h4 {
  margin-bottom: 1rem;
}

/* BUND */
.footer-bottom {
  margin-top: 3rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--color-text-muted-light);
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 1.5rem;
}

/* MOBILE */
@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .footer-col,
  .footer-center,
  .footer-right {
    align-items: center;
    text-align: center;
  }
}


/* =========================
   Cookies
   ========================= */
.cookie-banner {
  position: fixed;
  bottom: 20px;
  left: 20px;
  right: 20px;

  background: white;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);

  padding: 1rem;
  border-radius: var(--radius-md);

  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;

  z-index: 9999;
}

.cookie-actions {
  display: flex;
  gap: 0.5rem;
}

.cookie-banner button {
  padding: 0.5rem 1rem;
  border-radius: 999px;
  border: none;
  cursor: pointer;
}

#accept-cookies {
  background: var(--color-primary);
  color: var(--color-text-light);
}

#decline-cookies {
  background: #eee;
  color: var(--color-text);
}

.cookie-link {
  display: inline-block;
  padding: 8px 12px;
  text-decoration: none;

  color: var(--color-text);
  border: 1px solid #ddd;
  border-radius: 6px;

  font-size: 14px;
}

.cookie-link:hover {
  background: var(--color-bg-header-secondary);
}