/* ==========================================================================
   BEFORE YOU FALL IN LOVE (BYFIL) — BOOK-AUTHENTIC COLOR DESIGN & STYLES
   Palette derived directly from the book cover & interior pages:
   - Deep Midnight Navy (#050a24 / #0a1236)
   - Sunset Golden Yellow (#f5be3b / #e5a112)
   - Warm Book-Page Cream (#fdfaf2)
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,600;0,700;1,600&family=Outfit:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:ital,wght@0,400;0,500;0,600;0,700;1,400&display=swap');

:root {
  /* Book Cover Dark Theme: Deep Midnight Navy + Sunset Gold */
  --bg: #050a24;
  --bg-alt: #080f30;
  --cd: #0c153d;
  --cd-hover: #111d4f;
  --ln: rgba(245, 190, 59, 0.14);
  --ln-strong: rgba(245, 190, 59, 0.28);
  --tx: #fbf9f3;
  --mu: #b0b8d1;
  --pill: #121e52;
  --ac1: #f5be3b;       /* Book Cover Golden Yellow */
  --ac1-soft: rgba(245, 190, 59, 0.16);
  --ac2: #ffd978;       /* Warm Sunlight Gold Highlight */
  --bt: #f5be3b;
  --bt2: #050a24;
  --hd: rgba(5, 10, 36, 0.86);
  --shadow-lg: 0 24px 60px rgba(2, 5, 20, 0.55);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --font-display: 'Outfit', "Tw Cen MT", "Century Gothic", sans-serif;
  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans: 'Plus Jakarta Sans', "Tw Cen MT", -apple-system, BlinkMacSystemFont, sans-serif;
}

html[data-theme="light"] {
  /* Book Cover Light Theme: Warm Sunset Cream + Deep Midnight Navy + Gold */
  --bg: #fdfaf2;
  --bg-alt: #f6eed9;
  --cd: #ffffff;
  --cd-hover: #fcf6e6;
  --ln: rgba(5, 10, 36, 0.1);
  --ln-strong: rgba(5, 10, 36, 0.2);
  --tx: #050a24;
  --mu: #3d4663;
  --pill: #f2e8cf;
  --ac1: #d4920a;       /* Rich Book Gold on Cream */
  --ac1-soft: rgba(212, 146, 10, 0.14);
  --ac2: #050a24;       /* Deep Midnight Navy Accent */
  --bt: #050a24;
  --bt2: #fdfaf2;
  --hd: rgba(253, 250, 242, 0.92);
  --shadow-lg: 0 20px 50px rgba(5, 10, 36, 0.08);
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--tx);
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.7;
  transition: background-color 0.35s ease, color 0.35s ease;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  letter-spacing: -0.025em;
  color: var(--tx);
  margin-top: 0;
}

h2 {
  font-size: clamp(28px, 3.8vw, 46px);
  line-height: 1.12;
  margin-bottom: 22px;
  font-weight: 700;
}

h3 {
  font-size: clamp(20px, 2.2vw, 26px);
  line-height: 1.25;
  margin: 8px 0 12px;
  font-weight: 600;
}

p {
  margin: 0 0 18px;
  color: var(--mu);
}

.tx strong, strong {
  color: var(--tx);
}

.tx li {
  color: var(--mu);
  margin-bottom: 10px;
}

.tx a:not(.btn):not(.row) {
  color: var(--ac1);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.ac {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 600;
  font-size: 1.08em;
  color: var(--ac1);
}

/* ==========================================================================
   HEADER & NAVIGATION
   ========================================================================== */

header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 60;
  height: 72px;
  background: var(--hd);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--ln);
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 clamp(16px, 4vw, 48px);
  transition: background 0.3s, border-color 0.3s;
}

.lg {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}

.lg img {
  height: 40px;
  width: auto;
  display: block;
}

.ld { display: none !important; }
html[data-theme="dark"] .ld { display: block !important; }
html[data-theme="dark"] .ll { display: none !important; }

#lang {
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--tx);
  background: var(--cd);
  border: 1px solid var(--ln);
  border-radius: 999px;
  padding: 6px 12px;
  cursor: pointer;
}

nav#top {
  display: none;
  margin-inline: auto;
  background: var(--cd);
  border: 1px solid var(--ln);
  border-radius: 999px;
  padding: 5px 7px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.14);
  align-items: center;
  gap: 2px;
}

nav#top a, #menu a {
  text-decoration: none;
}

nav#top a {
  color: var(--mu);
  font-size: 13.5px;
  font-weight: 500;
  padding: 7px 13px;
  border-radius: 999px;
  white-space: nowrap;
  transition: all 0.2s ease;
}

nav#top a:hover {
  color: var(--tx);
}

nav#top a.on {
  background: var(--ac1);
  color: #050a24 !important;
  font-weight: 700;
}

.dd {
  position: relative;
}

.dd::after {
  content: "";
  position: absolute;
  inset: 100% 0 -10px;
}

.dh {
  font: inherit;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--mu);
  background: none;
  border: 0;
  padding: 7px 13px;
  border-radius: 999px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.dh svg {
  width: 12px;
  height: 12px;
  transition: transform 0.2s ease;
}

.dh:hover, .dd.open .dh {
  color: var(--tx);
}

.dh.on {
  background: var(--ac1);
  color: #050a24 !important;
  font-weight: 700;
}

.dm {
  position: absolute;
  top: calc(100% + 8px);
  inset-inline-start: 0;
  min-width: 200px;
  background: var(--cd);
  border: 1px solid var(--ln-strong);
  border-radius: 16px;
  padding: 7px;
  display: none;
  box-shadow: var(--shadow-lg);
  z-index: 20;
}

.dd:hover .dm, .dd.open .dm {
  display: block;
  animation: fadeUp 0.2s ease both;
}

.dd:hover .dh svg, .dd.open .dh svg {
  transform: rotate(180deg);
}

.dm a {
  display: block;
  border-radius: 10px;
  padding: 9px 14px !important;
}

.dm a:hover {
  background: var(--pill);
}

.ctl {
  margin-inline-start: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

#th, #mb {
  background: var(--cd);
  border: 1px solid var(--ln);
  cursor: pointer;
  width: 40px;
  height: 40px;
  color: var(--tx);
  display: grid;
  place-items: center;
  border-radius: 50%;
  transition: all 0.2s ease;
}

#th:hover, #mb:hover {
  border-color: var(--ac1);
  background: var(--pill);
}

#th svg {
  width: 18px;
  height: 18px;
}

#mb {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  padding: 0;
}

#mb i {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--tx);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

body.o #mb i:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}
body.o #mb i:nth-child(2) {
  opacity: 0;
}
body.o #mb i:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* Slide-out Drawer Menu */
#menu {
  position: fixed;
  top: 0;
  inset-inline-end: 0;
  bottom: 0;
  width: min(440px, 100vw);
  background: var(--cd);
  border-inline-start: 1px solid var(--ln-strong);
  z-index: 55;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: 96px clamp(24px, 6vw, 44px) 40px;
  overflow-y: auto;
  transform: translateX(100%);
  opacity: 0;
  visibility: hidden;
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.35s ease, visibility 0.35s;
  box-shadow: -20px 0 60px rgba(0, 0, 0, 0.5);
}

[dir="rtl"] #menu {
  transform: translateX(-100%);
}

body.o #menu {
  transform: translateX(0);
  opacity: 1;
  visibility: visible;
}

#menu a, #menu .gh {
  color: var(--tx);
  font-family: var(--font-display);
  font-size: clamp(21px, 4.2vw, 26px);
  line-height: 1.4;
  font-weight: 700;
  padding: 10px 0;
  border-bottom: 1px solid var(--ln);
  width: 100%;
  text-align: start;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

#menu a:hover, #menu .gh:hover, #menu a.on {
  color: var(--ac1);
}

#menu .mg {
  display: flex;
  flex-direction: column;
  width: 100%;
}

#menu .gh {
  background: none;
  border: 0;
  border-bottom: 1px solid var(--ln);
  cursor: pointer;
}

#menu .gh svg {
  width: 18px;
  height: 18px;
  transform: rotate(-90deg);
  transition: transform 0.3s ease;
  color: var(--ac1);
}

[dir="rtl"] #menu .gh svg {
  transform: rotate(90deg);
}

#menu .mg.open .gh svg {
  transform: rotate(0deg);
}

#menu .ms {
  display: flex;
  flex-direction: column;
  max-height: 0;
  overflow: hidden;
  padding-inline-start: 16px;
  transition: max-height 0.35s ease;
}

#menu .mg.open .ms {
  max-height: 260px;
}

#menu .ms a {
  font-size: 17px;
  font-weight: 500;
  color: var(--mu);
  padding: 8px 0;
  border-bottom: 1px dashed var(--ln);
}

@media (min-width: 1120px) {
  nav#top {
    display: flex;
  }
  nav#top + .ctl {
    margin-inline-start: 0;
  }
  #mb {
    display: none;
  }
}

@media (min-width: 1120px) and (max-width: 1280px) {
  nav#top a,
  .dh {
    font-size: 12.5px;
    padding: 6px 10px;
  }
}

@media (max-width: 640px) {
  header {
    height: 64px;
    padding: 0 14px;
    gap: 10px;
  }
  .lg img {
    height: 32px;
  }
  #lang {
    font-size: 12px;
    padding: 5px 10px;
  }
  #th, #mb {
    width: 36px;
    height: 36px;
  }
}

/* ==========================================================================
   BUTTONS
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--bt);
  color: var(--bt2) !important;
  padding: 14px 28px;
  border-radius: 999px;
  text-decoration: none !important;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 16px;
  border: 1.5px solid var(--bt);
  cursor: pointer;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(245, 190, 59, 0.28);
}

.btn-secondary,
p > a.btn:nth-of-type(2) {
  background: transparent !important;
  color: var(--tx) !important;
  border-color: var(--ln-strong) !important;
}

.btn-secondary:hover,
p > a.btn:nth-of-type(2):hover {
  border-color: var(--ac1) !important;
  background: var(--ac1-soft) !important;
}

/* ==========================================================================
   PAGE SHELL
   ========================================================================== */

main {
  padding-top: 72px;
}

.page {
  display: none;
  padding: clamp(56px, 7vw, 96px) clamp(18px, 4vw, 48px);
}

.page.on {
  display: block;
}

.in {
  max-width: 1180px;
  margin: 0 auto;
}

.in-narrow {
  max-width: 860px;
  margin: 0 auto;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.page.on .in > *,
.page.on .in-narrow > * {
  animation: fadeUp 0.65s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.cf-split {
  display: grid;
  grid-template-columns: 1fr;
  max-width: 780px;
  margin-bottom: 44px;
}

/* ==========================================================================
   HERO SECTION WITH FLOWING BACKGROUND 3D BOOK OPENING PAGES
   ========================================================================== */

.hero {
  padding: 0;
  background: var(--bg);
  color: var(--tx);
}

.hero-banner {
  position: relative;
  min-height: calc(100vh - 72px);
  width: 100%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Outer semi-transparent stage (keeps opacity outside preserve-3d tree) */
.hero-book-stage {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.38;
  transition: opacity 0.4s ease;
}

html[data-theme="light"] .hero-book-stage {
  opacity: 0.30;
}

/* Soft radial vignette around the edges of the hero banner */
.hero-book-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 80% 76% at 50% 50%,
    rgba(5, 10, 36, 0.18) 0%,
    color-mix(in srgb, var(--bg) 70%, transparent) 72%,
    var(--bg) 100%
  );
  pointer-events: none;
}

/* 3D Perspective Viewport */
.hero-book-bg {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 2200px;
}

.hero-book-bg::before {
  content: "";
  position: absolute;
  width: 780px;
  height: 780px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(245, 190, 59, 0.26) 0%, transparent 68%);
  filter: blur(26px);
  pointer-events: none;
}

/* Slow, graceful 36-second 3D floating & drifting rig across the hero */
.book-flow-rig {
  --rig-drift: 1;
  position: relative;
  transform-style: preserve-3d;
  animation: bookFlowRig 36s ease-in-out infinite alternate;
  will-change: transform;
}

@keyframes bookFlowRig {
  0% {
    transform: translate3d(calc(-130px * var(--rig-drift)), calc(24px * var(--rig-drift)), -10px) rotateX(22deg) rotateY(-16deg) rotateZ(-4deg) scale(1.04);
  }
  25% {
    transform: translate3d(calc(55px * var(--rig-drift)), calc(-24px * var(--rig-drift)), 35px) rotateX(17deg) rotateY(9deg) rotateZ(2deg) scale(1.09);
  }
  50% {
    transform: translate3d(calc(140px * var(--rig-drift)), calc(16px * var(--rig-drift)), 15px) rotateX(21deg) rotateY(15deg) rotateZ(4deg) scale(1.06);
  }
  75% {
    transform: translate3d(calc(-45px * var(--rig-drift)), calc(-28px * var(--rig-drift)), 40px) rotateX(16deg) rotateY(-11deg) rotateZ(-3deg) scale(1.1);
  }
  100% {
    transform: translate3d(calc(95px * var(--rig-drift)), calc(14px * var(--rig-drift)), 20px) rotateX(20deg) rotateY(12deg) rotateZ(3deg) scale(1.07);
  }
}

.book-floor-shadow {
  position: absolute;
  top: 12%;
  left: -90%;
  width: 180%;
  height: 85%;
  background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.65) 0%, transparent 70%);
  transform: translateZ(-35px);
  pointer-events: none;
}

/* The 3D Book Assembly (spine centered at origin so open spread is balanced) */
.book-3d {
  position: relative;
  width: clamp(250px, 24vw, 330px);
  height: clamp(355px, 33vw, 465px);
  transform-style: preserve-3d;
  transition: transform 2.6s cubic-bezier(0.22, 1, 0.36, 1);
  /* When open, shift by 50% so the central spine sits right at the center of the rig */
  transform: translateX(50%);
}

.book-3d.is-closed-front {
  transform: translateX(0%);
}

.book-3d.is-closed-back {
  transform: translateX(100%);
}

/* 3D Spine at the left edge of the right page stack */
.book-spine {
  position: absolute;
  top: 0;
  left: -24px;
  width: 24px;
  height: 100%;
  background: linear-gradient(90deg, #b8820c, #f5be3b 48%, #9e6d06);
  transform-origin: right center;
  transform: rotateY(-90deg);
  border-radius: 3px 0 0 3px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.book-spine span {
  writing-mode: vertical-rl;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: #050a24;
  text-transform: uppercase;
}

/* Individual Flippable Sheet (Front + Back page) */
.book-sheet {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform-origin: left center;
  transform-style: preserve-3d;
  transition: transform 2.8s cubic-bezier(0.25, 0.8, 0.25, 1);
  /* translateZ BEFORE rotateY so depth offset stays in book-space (+Z toward viewer) */
  transform: translateZ(var(--wz, 2px)) rotateY(var(--ry, -12deg));
}

.book-sheet.flipped {
  transform: translateZ(var(--wz, 2px)) rotateY(var(--ry, -168deg));
}

.sheet-face {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border-radius: 3px 12px 12px 3px;
  background: #fffdf7;
  box-shadow:
    0 14px 36px rgba(2, 5, 20, 0.4),
    inset 0 0 0 1px rgba(5, 10, 36, 0.12);
}

.sheet-face.sheet-front {
  transform: translateZ(0.6px);
}

.sheet-face.sheet-back {
  transform: rotateY(180deg) translateZ(0.6px);
  border-radius: 12px 3px 3px 12px;
}

.sheet-face img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;
}

/* Realistic book crease / gutter shadow */
.sheet-face.sheet-front::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(5, 10, 36, 0.28) 0%, rgba(5, 10, 36, 0.06) 10%, transparent 24%, transparent 92%, rgba(5, 10, 36, 0.08) 100%);
  pointer-events: none;
}

.sheet-face.sheet-back::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(270deg, rgba(5, 10, 36, 0.28) 0%, rgba(5, 10, 36, 0.06) 10%, transparent 24%, transparent 92%, rgba(5, 10, 36, 0.08) 100%);
  pointer-events: none;
}

/* Foreground Hero Copy Container (Centered & crisp over the semi-transparent book) */
.hero-foreground {
  position: relative;
  z-index: 4;
  max-width: 960px;
  width: 100%;
  margin: 0 auto;
  padding: clamp(44px, 6vw, 84px) clamp(20px, 4vw, 48px);
  display: flex;
  justify-content: center;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 820px;
  text-shadow: 0 2px 18px rgba(5, 10, 36, 0.85);
}

html[data-theme="light"] .hero-copy {
  text-shadow: 0 2px 18px rgba(253, 250, 242, 0.9);
}

.hero .tag {
  font-family: var(--font-display);
  font-size: clamp(12px, 1.35vw, 14px);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ac1);
  margin: 0 0 16px;
  padding: 0;
  background: none;
  border: 0;
}

.hero .tag strong {
  color: var(--ac1);
  font-weight: 700;
}

.hero h1 {
  font-size: clamp(32px, 4.5vw, 58px);
  line-height: 1.1;
  margin: 0 auto 20px;
  font-weight: 700;
  color: var(--tx);
  text-shadow: 0 4px 28px color-mix(in srgb, var(--bg) 85%, transparent);
}

.hero .w {
  display: inline-block;
  opacity: 0;
  transform: translateY(0.45em);
  filter: blur(8px);
  transition: color 0.3s ease;
}

.hero.go .w {
  animation: wordReveal 0.8s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
  animation-delay: calc(var(--i, 0) * 55ms);
}

.hero h1 .w:hover {
  color: var(--ac1);
}

@keyframes wordReveal {
  to {
    opacity: 1;
    transform: none;
    filter: none;
  }
}

.hero-copy p {
  font-size: 18.5px;
  line-height: 1.65;
  margin-bottom: 14px;
  max-width: 650px;
  color: var(--tx);
  opacity: 0.92;
  text-shadow: 0 2px 18px color-mix(in srgb, var(--bg) 90%, transparent);
}

.hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 14px;
  margin-top: 22px;
}

/* Stats Counter Bar */
.cn {
  display: grid !important;
  grid-template-columns: repeat(3, auto);
  justify-content: center;
  gap: 6px clamp(26px, 5vw, 54px);
  margin-top: 32px !important;
  padding-top: 22px !important;
  border-top: 1px solid var(--ln-strong) !important;
  width: 100%;
  max-width: 580px;
  text-align: start;
}

.cn p {
  margin: 0;
  font-size: 14px;
  line-height: 1.35;
  text-shadow: none;
}

.cn p:nth-child(1) { grid-row: 1 / 3; grid-column: 1; }
.cn p:nth-child(2) { grid-column: 2 / 4; grid-row: 1; }
.cn p:nth-child(3) { grid-column: 2; grid-row: 2; }
.cn p:nth-child(4) { grid-column: 3; grid-row: 2; }

.cn .lb {
  display: block;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--mu);
}

.cn .nm {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  line-height: 1.05;
  color: var(--ac1);
  font-variant-numeric: tabular-nums;
}

.cn p:nth-child(n+3) .nm {
  display: inline;
  color: var(--tx);
}

.cn .un {
  font-size: 14px;
  color: var(--mu);
}

@media (max-width: 1024px) {
  .book-flow-rig {
    --rig-drift: 0.65;
  }
  .book-3d {
    width: clamp(200px, 26vw, 250px);
    height: clamp(285px, 37vw, 355px);
  }
}

@media (max-width: 768px) {
  .book-flow-rig {
    --rig-drift: 0.42;
  }
  .book-3d {
    width: clamp(160px, 34vw, 200px);
    height: clamp(228px, 48vw, 285px);
  }
  .hero-copy p {
    font-size: 16.5px;
  }
}

@media (max-width: 540px) {
  main {
    padding-top: 64px;
  }
  .hero-banner {
    min-height: calc(100svh - 64px);
  }
  .book-flow-rig {
    --rig-drift: 0.28;
  }
  .book-3d {
    width: clamp(134px, 38vw, 158px);
    height: clamp(192px, 54vw, 226px);
  }
  .book-spine {
    left: -16px;
    width: 16px;
  }
  .book-spine span {
    font-size: 8.5px;
  }
  .hero-foreground {
    padding: 36px 18px 44px;
  }
  .hero h1 {
    font-size: clamp(27px, 7.6vw, 36px);
    line-height: 1.14;
    margin-bottom: 16px;
  }
  .hero-copy p {
    font-size: 15.5px;
    line-height: 1.58;
    margin-bottom: 12px;
  }
  .hero-cta-row {
    width: 100%;
    flex-direction: column;
    gap: 10px;
  }
  .hero-cta-row .btn {
    width: 100%;
    padding: 13px 22px;
  }
  .cn {
    gap: 6px 20px;
    margin-top: 26px !important;
    padding-top: 18px !important;
  }
  .cn .nm {
    font-size: clamp(24px, 6.5vw, 32px);
  }
}

/* ==========================================================================
   COSARAF-INSPIRED VERTICAL ACCORDION (Clean, Badge-Free)
   ========================================================================== */

.cosaraf-section {
  padding: clamp(60px, 8vw, 110px) clamp(20px, 4vw, 48px);
  border-top: 1px solid var(--ln);
  background: var(--bg-alt);
}

.v-accordion {
  display: flex;
  flex-direction: row;
  min-height: 430px;
  gap: 8px;
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.v-acc-item {
  display: flex;
  flex-direction: row;
  background: var(--cd);
  border: 1px solid var(--ln);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: flex 0.65s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.3s ease;
  flex: 0 0 76px;
  position: relative;
}

.v-acc-item.active {
  flex: 1 1 auto;
  border-color: var(--ac1);
}

.v-acc-trigger {
  width: 76px;
  flex-shrink: 0;
  background: var(--cd);
  border: 0;
  border-inline-end: 1px solid var(--ln);
  color: var(--tx);
  padding: 24px 12px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  transition: background 0.25s ease;
}

.v-acc-trigger:hover {
  background: var(--cd-hover);
}

.v-acc-title-vert {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.03em;
  white-space: nowrap;
  color: var(--mu);
  transition: color 0.25s ease;
}

.v-acc-item.active .v-acc-title-vert {
  color: var(--ac1);
}

.v-acc-num {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  color: var(--ac1);
}

.v-acc-panel {
  position: relative;
  flex: 1;
  padding: clamp(24px, 4vw, 44px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.45s ease 0.1s;
  min-width: 300px;
}

.v-acc-item.active .v-acc-panel {
  opacity: 1;
  pointer-events: auto;
}

.v-acc-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.1;
  pointer-events: none;
}

.v-acc-content {
  position: relative;
  z-index: 2;
  max-width: 580px;
}

.v-acc-arrow-link {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--ac1);
  text-decoration: none;
  margin-top: 20px;
}

.v-acc-arrow-link svg {
  width: 44px;
  height: 24px;
  transition: transform 0.3s ease;
}

.v-acc-arrow-link:hover svg {
  transform: translateX(8px);
}

@media (max-width: 900px) {
  .v-accordion {
    flex-direction: column;
    min-height: auto;
  }
  .v-acc-item {
    flex-direction: column;
    flex: none;
  }
  .v-acc-trigger {
    width: 100%;
    flex-direction: row;
    padding: 18px 22px;
    border-inline-end: 0;
    border-bottom: 1px solid var(--ln);
  }
  .v-acc-title-vert {
    writing-mode: horizontal-tb;
    transform: none;
  }
  .v-acc-panel {
    display: none;
    min-width: 0;
  }
  .v-acc-item.active .v-acc-panel {
    display: flex;
  }
}

/* ==========================================================================
   GLOBAL NETWORK REACH SECTION (Book Midnight Navy & Gold Map)
   ========================================================================== */

.network-map-card {
  background: #050a24;
  color: #fbf9f3;
  border: 1px solid var(--ln-strong);
  border-radius: var(--radius-lg);
  padding: clamp(28px, 5vw, 52px);
  position: relative;
  overflow: hidden;
  margin-top: 48px;
}

.network-grid {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 36px;
  align-items: center;
}

.network-tabs {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 20px;
}

.net-tab {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(245, 190, 59, 0.16);
  border-radius: 14px;
  padding: 14px 18px;
  color: #fbf9f3;
  text-align: start;
  cursor: pointer;
  transition: all 0.25s ease;
}

.net-tab:hover, .net-tab.active {
  border-color: var(--ac1);
  background: rgba(245, 190, 59, 0.12);
}

.net-tab strong {
  color: #fff;
  display: flex;
  justify-content: space-between;
  font-size: 16px;
}

.net-tab small {
  display: block;
  color: #b0b8d1;
  margin-top: 4px;
  font-size: 13.5px;
}

.network-svg-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  background: radial-gradient(circle at 50% 50%, rgba(245, 190, 59, 0.1), transparent 70%);
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.network-svg-wrap svg {
  width: 100%;
  height: 100%;
}

.arc-line {
  fill: none;
  stroke: #f5be3b;
  stroke-width: 2;
  stroke-dasharray: 6 6;
  animation: dashMove 18s linear infinite;
}

.ray-line {
  stroke: #ffd978;
  stroke-width: 1;
  opacity: 0.45;
}

@keyframes dashMove {
  to {
    stroke-dashoffset: -240;
  }
}

@media (max-width: 960px) {
  .network-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .network-tabs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
}

@media (max-width: 560px) {
  .network-map-card {
    padding: 22px 16px;
    margin-top: 32px;
  }
  .network-tabs {
    grid-template-columns: 1fr;
  }
  .network-svg-wrap {
    aspect-ratio: 4 / 3;
  }
}

/* ==========================================================================
   ABOUT, AUTHOR, GALLERY MARQUEE, TESTIMONIALS
   ========================================================================== */

.g {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 22px;
  margin-top: 38px;
}

.g img {
  width: 100%;
  border-radius: 20px;
  border: 1px solid var(--ln);
  box-shadow: var(--shadow-lg);
}

.bio::after {
  content: "";
  display: block;
  clear: both;
}

.hs {
  float: inline-start;
  width: 280px;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 22px;
  margin: 0 34px 18px 0;
  border: 1px solid var(--ln-strong);
  box-shadow: var(--shadow-lg);
}

[dir="rtl"] .hs {
  margin: 0 0 18px 34px;
}

.gt {
  font-size: clamp(20px, 2.6vw, 28px);
  margin: 72px 0 22px;
}

.mq {
  overflow: hidden;
  margin: 0 calc(50% - 50vw);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.mt {
  display: flex;
  gap: 16px;
  width: max-content;
  animation: mq 55s linear infinite;
}

.mq:hover .mt {
  animation-play-state: paused;
}

.mt img {
  height: 170px;
  width: 255px;
  object-fit: cover;
  border-radius: 14px;
  border: 1px solid var(--ln);
  flex: none;
}

@keyframes mq {
  to { transform: translateX(-50%); }
}

blockquote {
  margin: 0 0 22px;
  background: var(--cd);
  border: 1px solid var(--ln);
  border-inline-start: 4px solid var(--ac1);
  border-radius: 18px;
  padding: 26px 28px;
  box-shadow: var(--shadow-lg);
}

blockquote p {
  color: var(--tx);
  font-size: 17.5px;
}

/* ==========================================================================
   THOUGHTS (GITHUB MARKDOWN BLOG ENGINE — CLEAN & MINIMAL)
   ========================================================================== */

#thoughts .in {
  max-width: 1120px;
}

.fq {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr);
  gap: clamp(28px, 6vw, 80px);
  align-items: start;
}

.fl {
  position: sticky;
  top: 104px;
}

.ph {
  font-family: var(--font-display);
  font-size: clamp(34px, 4.6vw, 54px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--tx);
  margin-bottom: 18px;
}

.blog-search-input {
  width: 100%;
  font: inherit;
  font-size: 15px;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid var(--ln-strong);
  background: var(--cd);
  color: var(--tx);
  outline: none;
  margin-top: 12px;
}

.blog-search-input:focus {
  border-color: var(--ac1);
}

.fr {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  background: var(--cd);
  border: 1px solid var(--ln);
  border-radius: 16px;
  padding: 16px 18px 16px 22px;
  text-decoration: none !important;
  color: var(--tx);
  transition: border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

.row h3 {
  margin: 0;
  font-size: 17.5px;
  font-weight: 500;
  line-height: 1.4;
  color: var(--tx);
}

.row .rd {
  flex: none;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--ac1);
  background: none;
  border: 0;
  padding: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: transform 0.25s ease, color 0.25s ease;
}

.row .rd::after {
  content: "→";
  font-size: 16px;
  transition: transform 0.25s ease;
}

.row:hover {
  border-color: var(--ac1);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.row:hover .rd::after {
  transform: translateX(4px);
}

.back {
  display: inline-block;
  font-size: 26px;
  text-decoration: none !important;
  color: var(--ac1);
  margin-bottom: 12px;
}

@media (max-width: 900px) {
  .fq {
    grid-template-columns: 1fr;
  }
  .fl {
    position: static;
  }
}

@media (max-width: 540px) {
  .row {
    padding: 14px 16px;
    gap: 12px;
  }
  .row h3 {
    font-size: 16px;
  }
}

/* ==========================================================================
   FORMS, PRIVACY COMPLIANCE NOTICES & CHECKOUT CARDS
   ========================================================================== */

.cards-2col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 28px;
  margin-top: 32px;
}

.surface-card {
  background: var(--cd);
  border: 1px solid var(--ln-strong);
  border-radius: var(--radius-lg);
  padding: clamp(24px, 4vw, 38px);
  box-shadow: var(--shadow-lg);
}

.price-tag {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 800;
  color: var(--ac1);
  margin: 4px 0 14px;
}

.price-tag small {
  font-size: 15px;
  font-weight: 500;
  color: var(--mu);
}

.byfil-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 18px;
}

.byfil-form label {
  font-size: 14px;
  font-weight: 600;
  color: var(--tx);
  margin-bottom: -8px;
}

.byfil-form input[type="text"],
.byfil-form input[type="email"],
.byfil-form select,
.byfil-form textarea {
  font: inherit;
  font-size: 16px;
  color: var(--tx);
  background: var(--bg);
  border: 1px solid var(--ln-strong);
  border-radius: 12px;
  padding: 13px 16px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.byfil-form input:focus,
.byfil-form select:focus,
.byfil-form textarea:focus {
  border-color: var(--ac1);
  box-shadow: 0 0 0 4px var(--ac1-soft);
}

/* Document 3: Unticked-by-default Consent Checkbox Row */
.consent-checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--bg);
  border: 1px solid var(--ln);
  border-radius: 12px;
  padding: 14px 16px;
  margin-top: 6px;
}

.consent-checkbox-row input[type="checkbox"] {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  flex-shrink: 0;
  accent-color: var(--ac1);
  cursor: pointer;
}

.consent-checkbox-row label {
  font-size: 13.5px !important;
  font-weight: 400 !important;
  line-height: 1.55;
  color: var(--mu) !important;
  margin: 0 !important;
  cursor: pointer;
}

/* Document 4 & 5 Legal Notices */
.legal-notice-box {
  background: var(--bg);
  border: 1px solid var(--ln-strong);
  border-inline-start: 3px solid var(--ac1);
  border-radius: 12px;
  padding: 14px 18px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--mu);
  margin: 14px 0;
}

.legal-notice-box strong {
  color: var(--tx);
}

.er {
  color: #f87171 !important;
  font-size: 14px;
  font-weight: 600;
  margin: 4px 0 0;
}

.ok {
  color: var(--ac1) !important;
  font-size: 15px;
  font-weight: 600;
  margin: 8px 0 0;
}

[hidden] {
  display: none !important;
}

iframe#quiz {
  width: 100%;
  height: 820px;
  border: 1px solid var(--ln-strong);
  border-radius: 22px;
  margin-top: 36px;
  background: var(--bg);
  box-shadow: var(--shadow-lg);
}

/* ==========================================================================
   PRIVACY POLICY & COOKIE NOTICE PAGE + FIRST-VISIT COOKIE BANNER
   ========================================================================== */

.legal-doc-card {
  background: var(--cd);
  border: 1px solid var(--ln);
  border-radius: var(--radius-lg);
  padding: clamp(24px, 4vw, 44px);
  margin-bottom: 28px;
}

.legal-doc-card h3 {
  color: var(--ac1);
  margin-top: 24px;
  margin-bottom: 10px;
}

.cookie-banner {
  position: fixed;
  bottom: 20px;
  inset-inline: 20px;
  max-width: 940px;
  margin: 0 auto;
  background: var(--cd);
  border: 1px solid var(--ln-strong);
  border-radius: 20px;
  padding: 20px 24px;
  z-index: 90;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.65);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  animation: fadeUp 0.4s ease both;
}

.cookie-banner-text {
  flex: 1 1 460px;
}

.cookie-banner-text h4 {
  margin: 0 0 6px;
  font-size: 16.5px;
  color: var(--tx);
}

.cookie-banner-text p {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--mu);
}

.cookie-banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cookie-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(5, 10, 36, 0.78);
  backdrop-filter: blur(8px);
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
}

.cookie-modal {
  background: var(--cd);
  border: 1px solid var(--ln-strong);
  border-radius: 22px;
  max-width: 560px;
  width: 100%;
  padding: 30px;
  box-shadow: var(--shadow-lg);
}

.cookie-tier {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--ln);
}

/* ==========================================================================
   CTA & FOOTER
   ========================================================================== */

.cta {
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: clamp(70px, 10vw, 120px) 24px;
  color: #fbf9f3;
  background: #04081e;
  border-top: 1px solid var(--ln);
}

.cta img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 38%;
  opacity: 0.2;
}

.cta::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(5, 10, 36, 0.65), rgba(5, 10, 36, 0.9));
}

.cta > div {
  position: relative;
  z-index: 1;
  max-width: 820px;
  margin: auto;
}

.cta p {
  color: #fbf9f3;
  font-family: var(--font-display);
  font-size: clamp(26px, 4.2vw, 46px);
  font-weight: 800;
  line-height: 1.15;
  margin: 0 0 28px;
}

footer {
  background: #030617;
  color: #f1f1f6;
  border-top: 1px solid rgba(245, 190, 59, 0.14);
  font-size: 15px;
}

.ft {
  max-width: 1180px;
  margin: auto;
  padding: 64px 24px 34px;
}

.fgrid {
  display: grid;
  grid-template-columns: repeat(3, 1fr) 1.4fr;
  gap: 36px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(245, 190, 59, 0.12);
}

.fcol {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

footer a {
  color: #d5d8e6;
  text-decoration: none;
  transition: color 0.2s ease;
}

footer a:hover {
  color: var(--ac1);
}

.fcol .fh {
  font-weight: 700;
  color: #fff;
}

.fcol small {
  color: #9a9db0;
  font-size: 14.5px;
  line-height: 1.65;
}

.fbot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 28px;
  padding-top: 28px;
  color: #9a9db0;
  font-size: 13.5px;
}

.link-btn {
  background: none;
  border: 0;
  color: #9a9db0;
  font: inherit;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.link-btn:hover {
  color: var(--ac1);
}

#lang2 {
  font: inherit;
  font-size: 13.5px;
  color: #f1f1f6;
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(245, 190, 59, 0.25);
  padding: 4px 2px;
  cursor: pointer;
}

#lang2 option {
  color: #111;
}

.soc {
  display: flex;
  gap: 12px;
  margin-inline-start: auto;
}

.soc a {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #f1f1f6 !important;
  border: 1px solid rgba(245, 190, 59, 0.25);
  transition: all 0.25s ease;
}

.soc a:hover {
  background: var(--ac1);
  color: #050a24 !important;
  border-color: var(--ac1);
  transform: translateY(-2px);
}

.soc svg {
  width: 18px;
  height: 18px;
}

@media (max-width: 860px) {
  .fgrid { grid-template-columns: repeat(2, 1fr); }
  .hs { float: none; display: block; margin: 0 0 24px; width: 100%; max-width: 320px; }
  iframe#quiz { height: 740px; }
}

@media (max-width: 600px) {
  .cookie-banner {
    inset-inline: 12px;
    bottom: 12px;
    padding: 16px;
    gap: 14px;
  }
  .cookie-banner-actions {
    width: 100%;
  }
  .cookie-banner-actions .btn {
    flex: 1 1 auto;
    justify-content: center;
  }
  .cookie-modal {
    padding: 22px 18px;
  }
  blockquote {
    padding: 20px;
  }
  iframe#quiz {
    height: 680px;
    border-radius: 16px;
  }
}

@media (max-width: 480px) {
  .fgrid { grid-template-columns: 1fr; gap: 28px; }
  .soc { margin-inline-start: 0; width: 100%; }
}
