/* ============================================================
   SHARED.CSS – navbar, footer, scene, blur card
   Importeras av alla sidor
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Tomorrow:ital,wght@1,800&family=Barlow+Semi+Condensed:wght@400;600;700&display=swap');

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

html, body {
  width: 100%; height: 100%;
  font-family: 'Barlow Semi Condensed', sans-serif;
  overflow: hidden;
}

/* ===== SCENE ===== */
#scene {
  position: fixed;
  inset: 0;
  width: 100vw; height: 100vh;
  overflow: hidden;
}

#carousel { position: absolute; inset: 0; z-index: 0; }

.slide {
  position: absolute; inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1.8s ease-in-out;
}
.slide.active { opacity: 1; }

#yt-wrap {
  display: none;
  position: absolute; inset: 0;
  z-index: 0; overflow: hidden;
  pointer-events: none;
}
#yt-wrap iframe {
  position: absolute;
  top: 50%; left: 50%;
  width: 177.78vh; height: 56.25vw;
  min-width: 100%; min-height: 100%;
  transform: translate(-50%, -50%);
  border: none;
}

#overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.10);
  z-index: 1;
}

/* ===== NAVBAR ===== */
#navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  height: 56px;
  background: rgba(255,255,255,0.14);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  border-bottom: 1px solid rgba(255,255,255,0.18);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(16px, 4vw, 40px);
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
}
.nav-logo svg { width: 28px; height: 28px; flex-shrink: 0; }
.nav-logo-img { height: 32px; width: auto; display: block; }
.nav-logo span {
  font-family: 'Tomorrow', sans-serif;
  font-style: italic;
  font-weight: 800;
  font-size: 15px;
  color: #fff;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

/* Desktop links */
.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
}
.nav-links a {
  font-family: 'Barlow Semi Condensed', sans-serif;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.82);
  text-decoration: none;
  padding: 6px 14px;
  border-radius: 20px;
  transition: background 0.2s, color 0.2s;
}
.nav-links a:hover,
.nav-links a.active {
  background: rgba(255,255,255,0.18);
  color: #fff;
}

/* Hamburger button */
#hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  flex-direction: column;
  gap: 5px;
  align-items: flex-end;
}
#hamburger span {
  display: block;
  height: 2px;
  background: rgba(255,255,255,0.85);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s, width 0.3s;
}
#hamburger span:nth-child(1) { width: 22px; }
#hamburger span:nth-child(2) { width: 16px; }
#hamburger span:nth-child(3) { width: 22px; }

#hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); width: 22px; }
#hamburger.open span:nth-child(2) { opacity: 0; }
#hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); width: 22px; }

/* Mobile drawer */
#mobile-menu {
  display: none;
  position: fixed;
  top: 56px; left: 0; right: 0;
  background: rgba(10,10,10,0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 49;
  padding: 12px 0 20px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  animation: slideDown 0.25s ease;
}
#mobile-menu.open { display: block; }
@keyframes slideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}
#mobile-menu a {
  display: block;
  font-family: 'Barlow Semi Condensed', sans-serif;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  padding: 13px clamp(20px, 6vw, 40px);
  border-bottom: 1px solid rgba(255,255,255,0.07);
  transition: background 0.15s;
}
#mobile-menu a:last-child { border-bottom: none; }
#mobile-menu a:hover,
#mobile-menu a.active { background: rgba(255,255,255,0.08); color: #fff; }

/* ===== CONTENT LAYER ===== */
#content {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 4vw, 48px);
  padding-top: calc(56px + clamp(16px, 4vw, 48px));
  padding-bottom: calc(36px + clamp(16px, 4vw, 48px));
  overflow: hidden;
}

/* ===== BLUR CARD ===== */
.text-block {
  max-width: min(700px, 94vw);
  width: 100%;
  max-height: 100%;
  overflow-y: auto;
  text-align: left;
  background: rgba(0,0,0,0.40);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 18px;
  padding: clamp(22px, 4vw, 40px) clamp(22px, 4vw, 44px);
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.2) transparent;
}
.text-block::-webkit-scrollbar { width: 4px; }
.text-block::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.2); border-radius: 2px; }

/* Stagger animation */
.text-block > * {
  opacity: 0;
  transform: translateY(14px);
  animation: fadeUp 0.65s forwards;
}
@keyframes fadeUp { to { opacity: 1; transform: translateY(0); } }
.text-block > *:nth-child(1)  { animation-delay: 0.15s; }
.text-block > *:nth-child(2)  { animation-delay: 0.22s; }
.text-block > *:nth-child(3)  { animation-delay: 0.28s; }
.text-block > *:nth-child(4)  { animation-delay: 0.33s; }
.text-block > *:nth-child(5)  { animation-delay: 0.37s; }
.text-block > *:nth-child(n+6) { animation-delay: 0.41s; }

/* ===== TYPOGRAPHY ===== */
.page-title {
  font-family: 'Tomorrow', sans-serif;
  font-style: italic;
  font-weight: 800;
  font-size: clamp(22px, 4vw, 40px);
  line-height: 1.1;
  color: #fff;
  margin-bottom: 16px;
}

.section-title {
  font-family: 'Tomorrow', sans-serif;
  font-style: italic;
  font-weight: 800;
  font-size: clamp(14px, 2.4vw, 20px);
  color: #fff;
  margin-top: 22px;
  margin-bottom: 8px;
}

.body-text {
  font-family: 'Barlow Semi Condensed', sans-serif;
  font-weight: 400;
  font-size: clamp(13px, 1.7vw, 15px);
  line-height: 1.65;
  color: rgba(255,255,255,0.85);
  margin-bottom: 8px;
}

.fine-text {
  font-family: 'Barlow Semi Condensed', sans-serif;
  font-size: clamp(11px, 1.3vw, 12px);
  color: rgba(255,255,255,0.45);
  line-height: 1.5;
  margin-bottom: 8px;
}

hr.divider {
  border: none;
  border-top: 1px solid rgba(255,255,255,0.12);
  margin: 18px 0;
}

ul.req-list, ul.feature-list {
  list-style: none;
  padding: 0;
  margin-bottom: 8px;
}
ul.req-list li, ul.feature-list li {
  font-family: 'Barlow Semi Condensed', sans-serif;
  font-size: clamp(13px, 1.7vw, 15px);
  color: rgba(255,255,255,0.82);
  line-height: 1.65;
  padding-left: 15px;
  position: relative;
}
ul.req-list li::before  { content: "–"; position: absolute; left: 0; color: #0099cc; }
ul.feature-list li::before { content: "·"; position: absolute; left: 0; color: #0099cc; font-size: 18px; line-height: 1.35; }

.doc-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: 'Barlow Semi Condensed', sans-serif;
  font-weight: 600;
  font-size: clamp(13px, 1.7vw, 15px);
  color: #33bbee;
  text-decoration: none;
  margin-bottom: 6px;
  transition: color 0.2s;
}
.doc-link:hover { color: #fff; }

/* ===== DOWNLOAD BUTTON ===== */
.btn-wrap {
  display: flex;
  justify-content: center;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
}

.dl-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #0099cc;
  color: #fff;
  font-family: 'Tomorrow', sans-serif;
  font-style: italic;
  font-weight: 800;
  font-size: clamp(16px, 2.6vw, 24px);
  letter-spacing: 0.02em;
  padding: clamp(11px, 1.8vw, 16px) clamp(24px, 4vw, 48px);
  border: none;
  border-radius: 50px;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.3s, transform 0.2s, box-shadow 0.3s;
  box-shadow: 0 8px 32px rgba(0,153,204,0.42);
  white-space: nowrap;
}
.dl-btn:hover {
  background: #007aa8;
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 12px 44px rgba(0,153,204,0.52);
}

.driver-note {
  font-family: 'Barlow Semi Condensed', sans-serif;
  font-size: clamp(11px, 1.3vw, 12px);
  color: rgba(255,255,255,0.5);
  line-height: 1.5;
  text-align: center;
  max-width: 500px;
}

/* ===== FOOTER ===== */
#footer {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 50;
  height: 32px;
  background: rgba(0,0,0,0.35);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
}
#footer p {
  font-family: 'Barlow Semi Condensed', sans-serif;
  font-size: 11px;
  color: rgba(255,255,255,0.38);
  letter-spacing: 0.05em;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 600px) {
  .nav-links { display: none; }
  #hamburger { display: flex; }
}

/* ============================================================
   POPUP – alltid dold tills .open läggs till
   ============================================================ */
#popup-bg {
  display: none !important;
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.65);
  z-index: 100;
  align-items: center;
  justify-content: center;
  padding: 16px;
  backdrop-filter: blur(6px);
}
#popup-bg.open { display: flex !important; }

#popup {
  background: #fff; color: #111;
  border-radius: 20px;
  width: 100%; max-width: 560px;
  max-height: 92vh; overflow-y: auto;
  padding: clamp(24px,5vw,44px);
  position: relative;
  box-shadow: 0 28px 80px rgba(0,0,0,0.35);
  animation: popIn 0.35s cubic-bezier(0.34,1.56,0.64,1);
  font-family: 'Barlow Semi Condensed', sans-serif;
}
#popup::-webkit-scrollbar { width: 5px; }
#popup::-webkit-scrollbar-thumb { background: #ddd; border-radius: 3px; }
@keyframes popIn { from{opacity:0;transform:scale(0.88) translateY(16px)} to{opacity:1;transform:scale(1) translateY(0)} }

#popup-close {
  position: absolute; top: 18px; right: 20px;
  background: #f0f0f0; border: none; border-radius: 50%;
  width: 34px; height: 34px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; color: #555; transition: background 0.2s;
}
#popup-close:hover { background: #ddd; }

#popup h2 {
  font-family: 'Barlow Semi Condensed', sans-serif;
  font-weight: 700; font-size: clamp(17px,3vw,22px);
  line-height: 1.25; color: #111;
  margin-bottom: 20px; padding-right: 40px;
}
#popup h3 { font-family:'Barlow Semi Condensed',sans-serif; font-weight:700; font-size:20px; color:#111; margin-bottom:8px; }
#popup > p { font-size:14px; color:#666; font-family:'Barlow Semi Condensed',sans-serif; }

.q-block { margin-bottom:18px; padding-bottom:18px; border-bottom:1px solid #f0f0f0; }
.q-block strong { display:block; font-family:'Barlow Semi Condensed',sans-serif; font-weight:700; font-size:15px; color:#111; margin-bottom:8px; }
.radio-group { display:flex; flex-direction:column; gap:6px; }
.radio-option {
  display:flex; align-items:flex-start; gap:10px; cursor:pointer;
  font-size:13px; font-family:'Barlow Semi Condensed',sans-serif;
  color:#333; padding:8px 12px; border-radius:10px;
  border:1.5px solid #e8e8e8; transition:border-color 0.2s,background 0.2s; line-height:1.4;
}
.radio-option:hover { border-color:#bbb; background:#fafafa; }
.radio-option input[type="radio"] { accent-color:#0099cc; width:16px; height:16px; flex-shrink:0; margin-top:2px; }
.radio-option:has(input:checked) { border-color:#0099cc; background:#f0faff; }
.radio-option:has(input:checked) span { font-weight:600; }

.conditional-input { display:none; margin-top:8px; }
.conditional-input.visible { display:block; }
.conditional-input label { display:block; font-size:12px; font-weight:600; color:#666; margin-bottom:5px; font-family:'Barlow Semi Condensed',sans-serif; }
.conditional-input input[type="text"] {
  width:100%; padding:9px 13px; border:1.5px solid #ccc; border-radius:8px;
  font-size:13px; font-family:'Barlow Semi Condensed',sans-serif; outline:none; color:#111; transition:border-color 0.2s;
}
.conditional-input input[type="text"]:focus { border-color:#0099cc; }

.email-section { margin-top:20px; padding-top:18px; border-top:1px solid #efefef; }
.email-section > label { display:block; font-size:12px; font-weight:600; color:#555; font-family:'Barlow Semi Condensed',sans-serif; margin-bottom:3px; }
.email-note { font-size:12px; color:#999; line-height:1.5; margin-bottom:9px; font-family:'Barlow Semi Condensed',sans-serif; }
#email-input {
  width:100%; padding:11px 14px; border:1.5px solid #e0e0e0; border-radius:10px;
  font-size:14px; font-family:'Barlow Semi Condensed',sans-serif; outline:none; color:#111; margin-bottom:12px; transition:border-color 0.2s;
}
#email-input:focus { border-color:#0099cc; }
#email-input::placeholder { color:#ccc; }

.checkbox-row { display:flex; align-items:flex-start; gap:9px; margin-bottom:16px; cursor:pointer; }
.checkbox-row input[type="checkbox"] { accent-color:#0099cc; width:15px; height:15px; flex-shrink:0; margin-top:3px; }
.checkbox-row span { font-size:12px; color:#666; line-height:1.5; font-family:'Barlow Semi Condensed',sans-serif; }

#send-btn {
  width:100%; padding:13px; background:#0099cc; color:#fff; border:none;
  border-radius:50px; font-family:'Tomorrow',sans-serif; font-style:italic; font-weight:800;
  font-size:18px; cursor:pointer; transition:background 0.25s,transform 0.2s;
  box-shadow:0 5px 20px rgba(0,153,204,0.35);
}
#send-btn:hover { background:#007aa8; transform:translateY(-1px); }

#form-success { display:none; text-align:center; padding:36px 0 16px; }
#form-success .check { font-size:48px; margin-bottom:14px; }

/* ============================================================
   MOBILE EMAIL VIEW (inside popup)
   ============================================================ */
#mobile-view .email-section input[type="email"] {
  margin-bottom: 14px;
}
#mobile-send-btn {
  width: 100%;
  padding: 13px;
  background: #0099cc;
  color: #fff;
  border: none;
  border-radius: 50px;
  font-family: 'Tomorrow', sans-serif;
  font-style: italic;
  font-weight: 800;
  font-size: 18px;
  cursor: pointer;
  transition: background 0.25s, transform 0.2s;
  box-shadow: 0 5px 20px rgba(0,153,204,0.35);
}
#mobile-send-btn:hover { background: #007aa8; transform: translateY(-1px); }

#mobile-success h3 {
  font-family: 'Barlow Semi Condensed', sans-serif;
  font-weight: 700;
  font-size: 22px;
  color: #111;
  margin-bottom: 10px;
}
#mobile-success p {
  color: #666;
  font-size: 15px;
  font-family: 'Barlow Semi Condensed', sans-serif;
}
