/* assets/css/site.css
   DSS Synergy AB – single stylesheet for all pages.
   Colours and shapes follow the previous site design. */

/* ---------- Fonts (self-hosted, no third-party requests) ---------- */
@font-face {
  font-family: "Poppins";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/poppins-latin-400-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Poppins";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/poppins-latin-500-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Poppins";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/poppins-latin-600-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Varela Round";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/varela-round-latin-400-normal.woff2") format("woff2");
}

/* ---------- Design tokens ---------- */
:root {
  --navy: #19234a;
  --violet: #4e46c2;
  --text: #2f3545;
  --red: #fc1f3b;
  --white: #ffffff;
  --tint: #f5f6fb;
  --line: #e3e5ef;

  --font-body: "Poppins", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-display: "Varela Round", "Poppins", system-ui, sans-serif;

  --wrap: 1140px;
  --gutter: 24px;
  --header-h: 76px;
  --radius: 15px;
  --radius-card: 15px 15px 15px 70px;
  --shadow: 0 0 20px rgba(0, 0, 0, 0.06);
  --shadow-lift: 0 10px 30px rgba(25, 35, 74, 0.12);
}

/* ---------- Base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.65;
  color: var(--text);
  background: var(--white);
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

h1,
h2,
h3,
p,
ul,
ol {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

a {
  color: var(--violet);
}

a:hover {
  color: var(--navy);
}

:focus-visible {
  outline: 3px solid var(--violet);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--navy);
  color: var(--white);
  border-radius: 8px;
  text-decoration: none;
}

.skip-link:focus {
  top: 12px;
  color: var(--white);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: var(--header-h);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--navy);
  text-decoration: none;
  white-space: nowrap;
}

.brand img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
}

.site-nav ul {
  display: flex;
  align-items: center;
  gap: 28px;
}

.site-nav a {
  font-family: var(--font-display);
  font-size: 0.95rem;
  color: var(--navy);
  text-decoration: none;
  padding-block: 8px;
  border-bottom: 2px solid transparent;
}

.site-nav a:hover {
  border-bottom-color: var(--violet);
}

.site-nav .lang {
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 30px;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 500;
}

.site-nav .lang:hover {
  border-color: var(--violet);
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--navy);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 30px;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--navy);
  box-shadow: 0 6px 0 var(--navy), 0 -6px 0 var(--navy);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 13px 26px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  border-radius: 30px;
  border: 2px solid transparent;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s;
}

.btn-primary {
  background: var(--violet);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--navy);
  color: var(--white);
}

.btn-outline {
  border-color: var(--violet);
  color: var(--violet);
  background: transparent;
}

.btn-outline:hover {
  background: var(--violet);
  color: var(--white);
}

.btn-light {
  background: var(--white);
  color: var(--violet);
}

.btn-light:hover {
  background: var(--navy);
  color: var(--white);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

/* ---------- Sections ---------- */
.section {
  padding-block: 88px;
}

.section-tint {
  background: var(--tint);
}

.section-head {
  max-width: 720px;
  margin-bottom: 44px;
}

.kicker {
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--violet);
  margin-bottom: 10px;
}

h1,
h2 {
  font-family: var(--font-display);
  font-weight: 400;
  color: var(--navy);
  line-height: 1.2;
}

h1 {
  font-size: clamp(1.9rem, 1.2rem + 2.6vw, 2.9rem);
}

h2 {
  font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.1rem);
}

h3 {
  font-family: var(--font-body);
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--navy);
}

.lead {
  margin-top: 14px;
  font-size: 1.05rem;
}

/* ---------- Hero ---------- */
.hero {
  padding-block: 72px 96px;
}

.hero .wrap {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
  gap: 56px;
}

.hero p.lead {
  max-width: 34rem;
  margin-block: 20px 30px;
}

.hero-figure {
  justify-self: center;
  width: min(100%, 390px);
  padding: 28px;
  border-radius: 100px;
  background: var(--white);
  box-shadow: var(--shadow-lift);
}

.hero-figure img {
  width: 100%;
  border-radius: 72px;
}

/* ---------- Cards ---------- */
.cards {
  display: grid;
  gap: 24px;
}

.cards-2 {
  grid-template-columns: repeat(2, 1fr);
}

.cards-3 {
  grid-template-columns: repeat(3, 1fr);
}

.card {
  padding: 34px 32px 34px 36px;
  background: var(--white);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow);
}

.card h3 {
  margin-bottom: 10px;
}

.card h3::before {
  content: "";
  display: block;
  width: 36px;
  height: 4px;
  margin-bottom: 16px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--violet), var(--red));
}

/* ---------- Motorsport feature ---------- */
.feature {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
  padding: 52px 56px;
  color: var(--white);
  border-radius: var(--radius-card);
  background: linear-gradient(344deg, var(--navy) 60%, var(--violet) 100%);
}

.feature h3 {
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 400;
  color: var(--white);
}

.feature .tagline {
  margin-top: 6px;
  font-size: 1.05rem;
  font-weight: 500;
}

.feature p + p {
  margin-top: 14px;
}

.feature .statement {
  padding-left: 22px;
  border-left: 4px solid var(--red);
  font-family: var(--font-display);
  font-size: 1.25rem;
  line-height: 1.45;
}

.feature .btn {
  margin-top: 26px;
}

/* ---------- How we work ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  counter-reset: step;
}

.steps li {
  counter-increment: step;
  padding-top: 20px;
  border-top: 2px solid var(--line);
}

.steps li::before {
  content: "0" counter(step);
  display: block;
  margin-bottom: 8px;
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--violet);
}

.steps h3 {
  margin-bottom: 8px;
}

.note {
  margin-top: 36px;
  font-weight: 500;
  color: var(--navy);
}

/* ---------- Team ---------- */
.team {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}

.person {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 26px;
  align-items: start;
  padding: 28px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.person img {
  width: 180px;
  aspect-ratio: 5 / 6;
  object-fit: cover;
  border-radius: 12px;
}

.person h3 {
  color: var(--violet);
}

.person .role {
  margin-block: 2px 12px;
  font-weight: 500;
  color: var(--navy);
}

.person .btn-row {
  margin-top: 18px;
}

.person .btn {
  padding: 9px 18px;
  font-size: 0.875rem;
}

/* ---------- Contact ---------- */
.contact-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 48px;
  align-items: center;
  padding: 52px 56px;
  color: var(--white);
  border-radius: var(--radius-card);
  background: linear-gradient(130deg, var(--navy) 35%, var(--violet) 100%);
}

.contact-panel h2 {
  color: var(--white);
}

.contact-panel .kicker {
  color: var(--white);
  opacity: 0.85;
}

.contact-panel .btn-row {
  margin-top: 28px;
}

.contact-panel .btn-outline {
  border-color: var(--white);
  color: var(--white);
}

.contact-panel .btn-outline:hover {
  background: var(--white);
  color: var(--navy);
}

.contact-panel img {
  width: 300px;
  border-radius: 12px;
}

/* ---------- Footer ---------- */
.site-footer {
  padding-block: 56px 28px;
  color: var(--white);
  font-size: 0.925rem;
  background: linear-gradient(344deg, var(--navy) 76%, var(--violet) 100%);
}

.site-footer a {
  color: var(--white);
}

.site-footer a:hover {
  text-decoration-thickness: 2px;
  color: var(--white);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
}

.site-footer h2 {
  margin-bottom: 14px;
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--white);
}

.site-footer li + li {
  margin-top: 6px;
}

.footer-legal {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  font-size: 0.85rem;
}

/* ---------- Text pages (privacy policy, 404) ---------- */
.prose {
  max-width: 760px;
  padding-block: 64px 88px;
}

.prose h1 {
  margin-bottom: 8px;
}

.prose h2 {
  margin-block: 36px 10px;
  font-size: 1.35rem;
}

.prose p + p,
.prose ul + p,
.prose p + ul {
  margin-top: 12px;
}

.prose ul {
  padding-left: 22px;
  list-style: disc;
}

.prose li + li {
  margin-top: 4px;
}

.prose .meta {
  color: #5b6072;
  font-size: 0.925rem;
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero .wrap,
  .feature,
  .contact-panel {
    grid-template-columns: 1fr;
  }

  .hero-figure {
    width: min(100%, 300px);
    border-radius: 80px;
  }

  .hero-figure img {
    border-radius: 56px;
  }

  .cards-3,
  .steps,
  .team {
    grid-template-columns: 1fr;
  }

  .contact-panel img {
    width: min(100%, 300px);
  }
}

@media (max-width: 820px) {
  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: var(--white);
    border-top: 1px solid var(--line);
    box-shadow: 0 12px 20px rgba(0, 0, 0, 0.08);
  }

  .site-nav.is-open {
    display: block;
  }

  .site-nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px var(--gutter) 16px;
  }

  .site-nav a {
    display: block;
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
  }

  .site-nav .lang {
    display: inline-block;
    margin-top: 14px;
    padding: 8px 16px;
    border: 1px solid var(--line);
  }
}

@media (max-width: 640px) {
  .section {
    padding-block: 60px;
  }

  .hero {
    padding-block: 44px 64px;
  }

  .cards-2,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .card,
  .feature,
  .contact-panel {
    padding: 30px 26px;
  }

  .person {
    grid-template-columns: 1fr;
  }

  .person img {
    width: 100%;
    max-width: 260px;
  }

  .hero .btn,
  .contact-panel .btn {
    flex: 1 1 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .btn {
    transition: none;
  }
}
