/* =========================================================
   TAL – Tekniskt Anpassade Lösningar
   Vanlig CSS-fil (ersätter Tailwind CDN + tailwind-config.js)
   Filen är indelad i tydliga avsnitt:
   1. Variabler (färger, typsnitt, mellanrum)
   2. Grundstilar
   3. Layout & rutnät (grids)
   4. Header / navigering
   5. Knappar
   6. Kort & ikonrutor
   7. Sektioner (hero, CTA, etc.)
   8. Formulär
   9. Footer
   10. Hjälpklasser (små återanvändbara verktyg)
   11. Responsivitet (media queries)
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;700&family=Space+Grotesk:wght@500;600;700&display=swap');

/* -----------------------------------------------------------
   1. VARIABLER
   Ändra en färg här så uppdateras den överallt på hemsidan.
----------------------------------------------------------- */
:root {
  --color-background: #0A1930;
  --color-background-alt: #0E2140;
  --color-surface: #12294C;
  --color-surface-elevated: #1A3560;
  --color-foreground: #F4F8FC;
  --color-muted: #A9BCD9;
  --color-primary: #2F6FEB;
  --color-primary-hover: #4C86F5;
  --color-secondary: #5FA8F5;
  --color-accent: #7DD3FC;
  --color-border: #24406B;
  --color-on-primary: #FFFFFF;
  --color-destructive: #F87171;
  --color-ring: #5FA8F5;

  --color-primary-15: rgba(47, 111, 235, 0.15);
  --color-primary-30: rgba(47, 111, 235, 0.30);
  --color-primary-40: rgba(47, 111, 235, 0.40);
  --color-background-90: rgba(10, 25, 48, 0.9);

  --font-heading: 'Space Grotesk', sans-serif;
  --font-body: 'DM Sans', sans-serif;

  --shadow-glow: 0 0 32px rgba(47, 111, 235, 0.25);

  --container-width: 1280px;
}

/* -----------------------------------------------------------
   2. GRUNDSTILAR
----------------------------------------------------------- */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background-color: var(--color-background);
  color: var(--color-foreground);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

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

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

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  margin: 0;
  line-height: 1.2;
}

p {
  margin: 0;
}

ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

svg {
  flex-shrink: 0;
}

::selection {
  background-color: var(--color-primary);
  color: #FFFFFF;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--color-secondary);
  outline-offset: 2px;
}

/* Text som tonas in när man scrollar ner till den */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 600ms ease, transform 600ms ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  html {
    scroll-behavior: auto;
  }
}

/* -----------------------------------------------------------
   3. LAYOUT & RUTNÄT
----------------------------------------------------------- */
.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.container--narrow {
  max-width: 42rem; /* ca 672px, motsvarar max-w-2xl */
}

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

.mx-auto {
  margin-left: auto;
  margin-right: auto;
}

.grid {
  display: grid;
  gap: 1.5rem;
}

.grid--gap-sm { gap: 1.25rem; }
.grid--gap-lg { gap: 2.5rem; }
.grid--gap-xl { gap: 3rem; }

/* Två kolumner från 1024px och uppåt */
.grid--2 {
  grid-template-columns: 1fr;
}

/* Tre kolumner: en kolumn på mobil, tre från 768px */
.grid--3-md {
  grid-template-columns: 1fr;
}

/* Tre kolumner: en kolumn på mobil, två från 640px, tre från 1024px */
.grid--3 {
  grid-template-columns: 1fr;
}

/* Fyra kolumner: en kolumn på mobil, två från 640px, fyra från 1024px */
.grid--4 {
  grid-template-columns: 1fr;
}

/* Kort-rutnätet i "Vad vi gör" (etikett + tre kort) */
.grid--featured {
  grid-template-columns: 1fr;
}
.grid--featured-inner {
  grid-template-columns: 1fr;
}

/* Kontaktsidans rutnät: formulär + kontaktinfo */
.grid--contact {
  grid-template-columns: 1fr;
}

.span-2-lg,
.span-3-lg {
  grid-column: auto;
}

/* -----------------------------------------------------------
   4. HEADER / NAVIGERING
----------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: var(--color-background-90);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--color-border);
}

.header-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 1.5rem;
  padding: 1.5rem 3rem;
}

.logo-link {
  flex-shrink: 0;
}

.logo-img {
  width: 66px;
  height: 66px;
  border-radius: 0.75rem;
}

.main-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  column-gap: 42px;
  row-gap: 0.5rem;
  font-size: 21px;
  font-weight: 500;
  color: var(--color-muted);
}

.nav-link {
  position: relative;
  cursor: pointer;
  transition: color 200ms ease;
}
.nav-link:hover {
  color: var(--color-foreground);
}
.nav-link.active {
  color: var(--color-foreground);
}
.nav-link.active::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -6px;
  height: 2px;
  background: var(--color-primary);
  border-radius: 2px;
}

.header-cta {
  font-size: 21px;
  padding: 15px 30px;
  border-radius: 0.75rem;
  white-space: nowrap;
}

/* -----------------------------------------------------------
   5. KNAPPAR
----------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 600;
  border-radius: 0.5rem;
  padding: 0.875rem 1.75rem;
  border: none;
  cursor: pointer;
  transition: background-color 200ms ease, border-color 200ms ease, transform 200ms ease;
}

.btn-primary {
  background-color: var(--color-primary);
  color: #FFFFFF;
}
.btn-primary:hover {
  background-color: var(--color-primary-hover);
}

.btn-secondary {
  background-color: transparent;
  color: var(--color-foreground);
  border: 1px solid var(--color-border);
}
.btn-secondary:hover {
  border-color: var(--color-secondary);
  background-color: var(--color-surface);
}

.btn-glow {
  box-shadow: var(--shadow-glow);
}

.btn-block {
  width: 100%;
}

.btn-lg {
  padding: 1rem 2rem;
}

.btn-sm {
  font-size: 0.875rem;
  padding: 0.625rem 1.25rem;
}

.icon-20 { width: 20px; height: 20px; }
.icon-16 { width: 16px; height: 16px; }
.icon-18 { width: 18px; height: 18px; }
.icon-24 { width: 24px; height: 24px; }
.icon-28 { width: 28px; height: 28px; }

/* -----------------------------------------------------------
   6. KORT & IKONRUTOR
----------------------------------------------------------- */
.card {
  border: 1px solid var(--color-border);
  border-radius: 1rem;
  padding: 1.75rem;
}

.card--surface {
  background-color: var(--color-surface);
}

.card--alt {
  background-color: var(--color-background-alt);
}

.card--hover {
  transition: transform 200ms ease, background-color 200ms ease, border-color 200ms ease;
}
.card--hover:hover {
  transform: translateY(-4px);
  background-color: var(--color-surface-elevated);
  border-color: var(--color-secondary);
}
@media (prefers-reduced-motion: reduce) {
  .card--hover:hover { transform: none; }
}

.icon-box {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.5rem;
  background-color: var(--color-primary-15);
  color: var(--color-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-bottom: 1rem;
}
.icon-box--md { width: 3rem; height: 3rem; margin-bottom: 1.25rem; }
.icon-box--sm { width: 2.25rem; height: 2.25rem; margin-bottom: 0; }
.icon-box--lg { width: 3.5rem; height: 3.5rem; border-radius: 0.75rem; margin: 0 auto 1.5rem; }

.step-number {
  display: block;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 2.25rem;
  color: var(--color-accent);
  opacity: 0.5;
}
.step-number--sm {
  font-size: 0.875rem;
  opacity: 1;
}

.check-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  color: var(--color-muted);
  font-size: 0.875rem;
}
.check-list--muted-icon svg {
  color: var(--color-muted);
}
.check-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.625rem;
}
.check-list svg {
  color: var(--color-secondary);
  margin-top: 2px;
}
.check-list--cross svg {
  color: var(--color-muted);
}

/* -----------------------------------------------------------
   7. SEKTIONER
----------------------------------------------------------- */
.section {
  padding: 5rem 0;
  border-top: 1px solid var(--color-border);
}
.section--first {
  border-top: none;
}
.section--no-border {
  border-top: none;
}
.section--alt {
  background-color: var(--color-background-alt);
}
.section--tight {
  padding: 4rem 0;
}
.section--roomy {
  padding: 5rem 0 7rem;
}

.eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.section-heading {
  font-weight: 600;
  font-size: 1.875rem;
  margin-top: 0.75rem;
}

.section-lead {
  color: var(--color-muted);
  margin-top: 1rem;
}

/* Hero (startsidan) */
.hero {
  position: relative;
  overflow: hidden;
}
.hero-glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(60% 50% at 80% 0%, rgba(47, 111, 235, 0.18), transparent 70%);
}
.hero-inner {
  position: relative;
  padding: 5rem 0 6rem;
}
.hero-content {
  max-width: 48rem;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-accent);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 9999px;
  padding: 0.375rem 1rem;
}
.hero-title {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 2.25rem;
  line-height: 1.15;
  margin-top: 1.5rem;
}
.hero-lead {
  font-size: 1.125rem;
  color: var(--color-muted);
  margin-top: 1.5rem;
  max-width: 40rem;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin-top: 2.25rem;
}
.hero-trust {
  display: flex;
  flex-wrap: wrap;
  column-gap: 2rem;
  row-gap: 0.75rem;
  margin-top: 3rem;
  font-size: 0.875rem;
  color: var(--color-muted);
}
.hero-trust span {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}
.hero-trust svg {
  color: var(--color-secondary);
}

/* Enklare hero (undersidor) */
.page-hero {
  padding: 4rem 0;
}
.page-hero-title {
  font-weight: 600;
  font-size: 2.25rem;
  margin-top: 0.75rem;
  max-width: 48rem;
}
.page-hero-lead {
  font-size: 1.125rem;
  color: var(--color-muted);
  margin-top: 1.5rem;
  max-width: 42rem;
}

/* Avslutande CTA-banderoll */
.cta-section {
  text-align: center;
}
.cta-content {
  max-width: 42rem;
  margin: 0 auto;
}
.cta-title {
  font-weight: 600;
  font-size: 1.875rem;
}
.cta-lead {
  color: var(--color-muted);
  margin-top: 1rem;
}
.cta-section .btn {
  margin-top: 2rem;
}

/* -----------------------------------------------------------
   8. FORMULÄR (kontaktsidan)
----------------------------------------------------------- */
.form-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
.form-field {
  margin-top: 1.25rem;
}
.form-field:first-child {
  margin-top: 0;
}
.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
}
.form-required {
  color: var(--color-destructive);
}
.form-input {
  width: 100%;
  background-color: var(--color-surface);
  color: var(--color-foreground);
  padding: 14px 16px;
  border: 1px solid var(--color-border);
  border-radius: 0.5rem;
  font-size: 16px;
  font-family: var(--font-body);
  transition: border-color 200ms ease;
}
.form-input:focus {
  border-color: var(--color-ring);
  outline: none;
  box-shadow: 0 0 0 3px rgba(95, 168, 245, 0.25);
}
textarea.form-input {
  resize: none;
}
.form-error {
  font-size: 0.75rem;
  color: var(--color-destructive);
  margin-top: 0.375rem;
}
.form-error.hidden {
  display: none;
}
.form-submit {
  width: 100%;
  margin-top: 1.75rem;
}
.form-note {
  font-size: 0.75rem;
  color: var(--color-muted);
  margin-top: 1rem;
  text-align: center;
}
.form-success {
  text-align: center;
  padding: 2.5rem 0;
}
.form-success.hidden {
  display: none;
}
.form-success .icon-box--lg {
  color: var(--color-secondary);
  background-color: var(--color-primary-15);
}
.form-success h2 {
  font-weight: 600;
  font-size: 1.5rem;
}
.form-success p {
  color: var(--color-muted);
  margin-top: 0.75rem;
}

.form-blur {
  inset: 0;
  background: transparent;
  backdrop-filter: blur(8px);
  position: absolute;
  border-radius: 1rem;
  text-align: center;
  align-content: center;
  font-family: 'DM Sans';
  font-size: 22px;
  font-weight: 500;
  box-shadow: 0 0 15px 5px #12294c;
  
}

.form-wrapper {
  position: relative;
}

.nomark{
  user-select: none;
}

/* -----------------------------------------------------------
   9. FOOTER
----------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--color-border);
  background-color: var(--color-background-alt);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  padding: 4rem 0;
}
.footer-logo {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.5rem;
  margin-bottom: 1rem;
}
.footer-about {
  font-size: 0.875rem;
  color: var(--color-muted);
  max-width: 20rem;
}
.footer-heading {
  font-weight: 600;
  font-size: 0.875rem;
  margin-bottom: 1rem;
}
.footer-nav {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  font-size: 0.875rem;
  color: var(--color-muted);
}
.footer-nav a,
.footer-contact a {
  transition: color 200ms ease;
}
.footer-nav a:hover,
.footer-contact a:hover {
  color: var(--color-foreground);
}
.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  font-size: 0.875rem;
  color: var(--color-muted);
}
.footer-contact a,
.footer-contact span {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}
.footer-cta-text {
  font-size: 0.875rem;
  color: var(--color-muted);
  margin-bottom: 1rem;
}
.footer-bottom {
  border-top: 1px solid var(--color-border);
  padding: 1.5rem;
  text-align: center;
  font-size: 0.75rem;
  color: var(--color-muted);
}

/* -----------------------------------------------------------
   10. HJÄLPKLASSER
----------------------------------------------------------- */
.underline-link {
  color: var(--color-secondary);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 200ms ease;
}
.underline-link:hover {
  color: var(--color-accent);
}

.price-figure {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 2.25rem;
  margin-top: 0.75rem;
}
.price-figure span {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 1rem;
  color: var(--color-muted);
}

/* -----------------------------------------------------------
   11. RESPONSIVITET
----------------------------------------------------------- */
@media (min-width: 640px) {
  .grid--3 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid--4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid--featured-inner {
    grid-template-columns: repeat(3, 1fr);
  }
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .form-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 768px) {
  .grid--3-md {
    grid-template-columns: repeat(3, 1fr);
  }
  .grid--services {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {

  .container {
    padding-left: 2rem;
    padding-right: 2rem;
  }

  .header-cta {
    justify-self: end;
  }

  .grid--2,
  .grid--contact-info {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid--3 {
    grid-template-columns: repeat(3, 1fr);
  }
  .grid--4 {
    grid-template-columns: repeat(4, 1fr);
  }
  .footer-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .grid--featured {
    grid-template-columns: 1fr 2fr;
  }
  .grid--contact {
    grid-template-columns: repeat(5, 1fr);
  }
  .span-3-lg {
    grid-column: span 3;
  }
  .span-2-lg {
    grid-column: span 2;
  }

  .hero-inner {
    padding: 7rem 0 8rem;
  }
  .hero-title {
    font-size: 3.75rem;
  }
  .page-hero-title {
    font-size: 3rem;
  }
  .section-heading {
    font-size: 2.25rem;
  }
  .cta-title {
    font-size: 2.25rem;
  }
  .section {
    padding: 6rem 0;
  }
  .section--tight {
    padding: 5rem 0;
  }
  .section--roomy {
    padding: 7rem 0;
  }
  .page-hero {
    padding: 5rem 0;
  }
}

@media (min-width: 480px) {
  .mobile-menu,.nav-toggle {
    display: none;
  }

  .hero-title,
  .page-hero-title {
    font-size: 3rem;
  }
}

@media (max-width: 480px) {
  .main-nav,.header-cta {
    display: none;
  }

  .mobile-menu {
    align-self: flex-end;
    display: none;
  }

  .nav-toggle {
    background-color: transparent;
    color: white;
    width: fit-content;
    font-size: 60px;
    border: none;
    justify-self: end;
  }
}
