/* Σελίδα Tesoro 40. Όλες οι κλάσεις έχουν πρόθεμα t40- για να μη συγκρούονται με το theme */

/* ===== Design tokens (Figma) ===== */
:root {
  --t40-white: #ffffff;
  --t40-gold: #c29b50;
  --t40-navy: #0F1423;
  --t40-blue: #0F1423; /* το φόντο της ενότητας FLEET στο sevenislandsways.com/fleet */
  --t40-black: #121212;
  --t40-back: #ffffff; /* ίδιο λευκό με τη μπάρα του μενού */

  --t40-font-main: "Kanit", system-ui, sans-serif;
  --t40-font-script: "Mrs Saint Delafield", cursive;
  --t40-font-ui: "Manrope", system-ui, sans-serif;

  --header-h: 112px; /* ύψος της μπάρας του μενού */
  --stage-h: 100vh;  /* ύψος της καρφωμένης ενότητας του βίντεο "in motion" */
}

@supports (height: 100lvh) {
  :root {
    --stage-h: 100lvh;
  }
}

/* Περιθώριο δεξιά-αριστερά των κειμένων, όπως στις σελίδες του sevenislandsways.com:
   κεντραρισμένη στήλη με τα πλάτη του Bootstrap, και 15px στο κινητό */
:root {
  --side: 15px;
}

@media (min-width: 576px) {
  :root { --side: max(15px, calc((100% - 540px) / 2));
  }
}

@media (min-width: 768px) {
  :root { --side: max(15px, calc((100% - 720px) / 2));
  }
}

@media (min-width: 992px) {
  :root { --side: max(15px, calc((100% - 960px) / 2));
  }
}

@media (min-width: 1200px) {
  :root { --side: max(15px, calc((100% - 1140px) / 2));
  }
}

@media (min-width: 1400px) {
  :root { --side: max(15px, calc((100% - 1320px) / 2));
  }
}

/* Η βάση που έδινε το Bootstrap του παλιού template */
body { margin: 0; font-family: "Kanit", system-ui, sans-serif; line-height: 24px; color: #212529; }
.t40 img, .t40 svg { vertical-align: middle; }

.t40, .t40 *::before, .t40 *::after { box-sizing: border-box;
}

.t40 *::before, .t40 *::after { margin: 0; padding: 0;
}

.t40 :where(*) { margin: 0; padding: 0; box-sizing: border-box;
}

/* Ουδετεροποίηση των γενικών κανόνων του theme (master.css / custom.css) */
.t40 :where(h1, h2, h3, p, li, a, img, video, figure) { position: static; z-index: auto;
}

.t40 :where(h1, h2, h3, p, li) { font-family: inherit; font-size: inherit; line-height: inherit; color: inherit; letter-spacing: normal; text-transform: none;
}

.t40 :where(p, li) { font-weight: inherit;
}

.t40 :where(img, video) { display: block; max-width: none;
}

.t40 :where(a) { color: inherit; text-decoration: none; transition: none;
}

.t40 a:hover { color: inherit;
}

.t40 :where(ul, li) { list-style: none;
}

.t40 :where(button) { font: inherit; color: inherit; background: none; border: 0; cursor: pointer;
}

.t40 :where(h1, h2, h3) { font-weight: 400;
}

.t40 :focus-visible { outline: 2px solid var(--t40-gold); outline-offset: 3px;
}

.t40 { font-family: var(--t40-font-main); font-size: 16px; font-weight: 300; line-height: normal; color: var(--t40-black); background: var(--t40-white);
}

.t40-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ===== Circle buttons ===== */
.t40-circle {
  position: relative;
  flex-shrink: 0;
  width: 172px;
  height: 172px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  color: var(--t40-white);
  font-weight: 500;
  font-size: 16px;
  letter-spacing: 0.8px;
  white-space: nowrap;
  transition: border-color 0.3s, background-color 0.3s;
}

.t40-circle:hover {
  border-color: var(--t40-white);
  background-color: rgba(255, 255, 255, 0.08);
}

.t40-circle__content {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}

.t40-circle__arrow, .t40-circle__label {
  grid-area: 1 / 1;
}

.t40-circle__arrow {
  opacity: 0.5;
}

.t40-circle--scroll {
  width: 152px;
  height: 152px;
  font-size: 14px;
  font-weight: 300;
  letter-spacing: 0.7px;
  scale: 0.85; /* ολόκληρο το κουμπί 15% μικρότερο, σε κινητό και desktop */
}

/* Κινείται μόνο το βελάκι, η φράση μένει ακίνητη */
.t40-circle--scroll .t40-circle__arrow {
  animation: t40-nudge 2.2s infinite;
}

.t40-circle--scroll .t40-circle__arrow img {
  width: 89.78px;
  height: 89.78px;
}

.t40-circle--scroll .t40-circle__label {
  translate: 0 -5.5px;
}

.t40-circle--book .t40-circle__arrow img {
  width: 77.23px;
  height: 77.23px;
}

/* Κατεβαίνει (Figma: ease-out), στέκεται λίγο κάτω και ανεβαίνει ομαλά.
   Το τέλος του κύκλου συμπίπτει με την αρχή, ώστε να μην υπάρχει άλμα */
@keyframes t40-nudge {
  0% {
    translate: 0 -20px;
    animation-timing-function: cubic-bezier(0, 0, 0.58, 1);
  }
  28% {
    translate: 0 0;
  }
  38% {
    translate: 0 0;
    animation-timing-function: cubic-bezier(0.45, 0, 0.55, 1);
  }
  100% {
    translate: 0 -20px;
  }
}

/* ===== Hero ===== */
.t40-hero {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  height: 100vh;
  height: 100svh;
  min-height: 600px;
  padding: min(40.1vh, 284px) 0 13px;
  overflow: hidden;
  background: #000;
  color: var(--t40-white);
}

/* Σκίαση 30% (fill του hero στο Figma), για να διαβάζονται τα λευκά κείμενα */
.t40-hero .t40-media {
  filter: brightness(var(--film-light, 0.7));
}

.t40-hero__center {
  display: contents;
}

.t40-hero__title, .t40-hero .t40-circle, .t40-hero__bottom {
  position: relative;
}

.t40-hero__title {
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: normal;
  white-space: nowrap;
}

/* ===== Έξοδος τίτλου με το scroll =====
   Το --title-out (0 → 1) το ορίζει το script ανάλογα με το scroll. */
/* "Tesoro 40": τα γράμματα ανεβαίνουν ένα-ένα, από αριστερά, και χάνονται
   πίσω από μια μάσκα που κόβει λίγο πάνω από τα κεφαλαία */
.t40-hero__name {
  clip-path: inset(0.38em -0.2em 0.3em);
}

.t40-hero__name span {
  /* Πρόοδος του κάθε γράμματος: ξεκινά με καθυστέρηση 0.08 από το προηγούμενο */
  --p: clamp(0, (var(--title-out, 0) - var(--i) * 0.08) / 0.44, 1);
  position: relative;
  top: calc(var(--p) * var(--p) * -0.8em);
}

/* "yachts": σβήνει ακολουθώντας ανάποδα τη ροή της πένας, από το s προς το y.
   Το SVG έχει τις ίδιες διαστάσεις και θέση που θα είχε το απλό κείμενο */
.t40-hero__script {
  position: relative;
  left: 0.0831em;
  flex-shrink: 0;
  width: 2.0714em;
  height: 1.0714em;
  margin: 0.299em 0 0.1536em;
  overflow: visible;
}

.t40-hero__script text {
  fill: currentColor;
  font-family: var(--t40-font-script);
  font-size: 700px; /* μονάδες του viewBox */
}

.t40-hero__script path {
  /* Η "μύτη" του brush. Το --pen ακολουθεί ομαλά το scroll (script) και τα
     μαλακά αντίγραφα προηγούνται κατά --lead */
  --head: calc(1 - var(--pen, 0) * 1.05 + var(--lead, 0));
  /* Πόσο από τη συγκεκριμένη διαδρομή φαίνεται ακόμα (1 → 0) */
  --v: clamp(0, (var(--head) - var(--from)) / var(--len), 1);
  fill: none;
  stroke: #fff;
  stroke-width: 62;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1000px 2000px;
  stroke-dashoffset: calc((1 - var(--v)) * 1001px);
  opacity: clamp(0, var(--v) * 1000, 1);
}

/* Μαλακό τελείωμα: ημιδιαφανή αντίγραφα που σβήνουν σταδιακά μπροστά από τη μύτη */
.t40-hero__script .t40-pen-soft path {
  stroke-opacity: 0.22;
}

/* Μαύρο στη μάσκα = κρυφό. Εμφανίζεται σταδιακά καθώς η γραμμή του t τελειώνει */
.t40-hero__script path.t40-pen-eraser {
  /* Πόσο από τη γραμμή του t μένει, χωρίς το μαλακό τελείωμα */
  --left: clamp(0, (1 - var(--pen, 0) * 1.05 - var(--from)) / var(--len), 1);
  stroke: #000;
  stroke-width: 52;
  stroke-dasharray: none;
  opacity: clamp(0, (0.45 - var(--left)) / 0.35, 1);
}

/* Όταν το βίντεο αρχίζει να παίζει μόνο του (2ο σκέλος), το "Scroll to Explore"
   μετατρέπεται πρώτα σε SKIP και μετά το κουμπί φεύγει */
.t40-hero .t40-circle {
  transition: border-color 0.3s, background-color 0.3s, opacity 0.3s, visibility 0.3s;
}

.t40-hero--film .t40-circle {
  opacity: 0;
  visibility: hidden;
  /* Σβήνει όσο το "Scroll to Explore" γίνεται SKIP (αργά στην αρχή,
     ώστε να φαίνεται η μετατροπή) */
  transition:
    border-color 0.3s,
    background-color 0.3s,
    opacity 0.7s cubic-bezier(0.4, 0, 1, 1),
    visibility 0s 0.7s;
}

.t40-circle--scroll .t40-circle__label {
  transition: opacity 0.35s ease, translate 0.35s ease;
}

.t40-circle--scroll .t40-circle__arrow {
  transition: opacity 0.5s ease, rotate 0.5s ease, scale 0.5s ease;
}

/* Το SKIP κάτω δεξιά δεν υπάρχει από την αρχή: εμφανίζεται μέσα στον κύκλο
   στο 2ο σκέλος και μετά μεταφέρεται στη θέση του (κίνηση στο script) */
.t40-transition .t40-hero:not(.t40-hero--skip) .t40-hero__skip {
  visibility: hidden;
}

.t40-hero--film .t40-circle--scroll .t40-circle__label {
  opacity: 0;
  translate: 0 -18px;
}

/* Το μεγάλο βέλος στρέφεται από κάτω προς πάνω δεξιά καθώς μικραίνει */
.t40-hero--film .t40-circle--scroll .t40-circle__arrow {
  animation: none;
  opacity: 0;
  rotate: -135deg;
  scale: 0.3;
}

.t40-hero__name {
  margin-bottom: -15px;
  font-size: 50px;
  font-weight: 500;
}

.t40-hero__script {
  font-family: var(--t40-font-script);
  font-size: 50px;
  font-weight: 400;
}

.t40-hero__bottom {
  display: flex;
  justify-content: flex-end;
  width: 100%;
  padding: 0 20px;
}

.t40-hero__chevron {
  display: none;
}

.t40-hero__chevron img {
  width: 45.71px;
  height: 45.71px;
}

.t40-hero__skip {
  display: flex;
  align-items: center;
  padding: 10px 0;
  font-family: var(--t40-font-ui);
  font-weight: 400;
  font-size: 20px;
  letter-spacing: 1px;
}

.t40-hero__skip span {
  margin-right: -5px;
}

/* Το βελάκι του SKIP, καθρεφτισμένο ώστε να δείχνει πάνω δεξιά */
.t40-hero__skip img {
  width: 27px;
  height: 27px;
  scale: 1 -1;
}

/* ===== Κουμπί ήχου (equalizer) στο κέντρο της κάτω σειράς ===== */
.t40-hero__sound {
  position: absolute;
  top: 50%;
  left: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 44px;
  translate: -50% -50%;
}

.t40-equalizer {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 22px;
}

/* Ήχος off: οι γραμμές μένουν κάτω, με ύψος 1px */
.t40-equalizer span {
  width: 2px;
  height: 1px;
  background: var(--t40-white);
  transition: height 0.2s ease-out;
}

/* Ήχος on: οι γραμμές κινούνται, η καθεμία με δικό της ρυθμό */
.t40-hero__sound[aria-pressed="true"] .t40-equalizer span {
  animation: t40-equalize 0.9s ease-in-out infinite alternate;
}

.t40-hero__sound[aria-pressed="true"] .t40-equalizer span:nth-child(1) { animation-duration: 0.55s; animation-delay: -0.2s;
}

.t40-hero__sound[aria-pressed="true"] .t40-equalizer span:nth-child(2) { animation-duration: 0.4s;  animation-delay: -0.35s;
}

.t40-hero__sound[aria-pressed="true"] .t40-equalizer span:nth-child(3) { animation-duration: 0.65s; animation-delay: -0.1s;
}

.t40-hero__sound[aria-pressed="true"] .t40-equalizer span:nth-child(4) { animation-duration: 0.45s; animation-delay: -0.3s;
}

.t40-hero__sound[aria-pressed="true"] .t40-equalizer span:nth-child(5) { animation-duration: 0.6s;  animation-delay: -0.45s;
}

@keyframes t40-equalize {
  from { height: 4px; }
  to   { height: 22px; }
}

/* ===== Description ===== */
.t40-about {
  padding-top: var(--header-h); /* χώρος για τη μπάρα του μενού πάνω από το banner */
  background: var(--t40-back);
}

/* ===== Μετάβαση hero → πρώτη εικόνα =====
   Ενεργή μόνο όταν το script βάζει την κλάση .transition (όχι με reduced motion).
   Η ενότητα "Description" μένει καρφωμένη από κάτω, ενώ το βίντεο κλείνει με
   μάσκα πάνω στη θέση της πρώτης εικόνας. */
.t40-transition .t40-about-pin {
  margin-top: calc(-1 * var(--hero-h));
}

/* Χώρος scroll όσο διαρκεί η μετάβαση */
.t40-transition .t40-about-pin::after {
  content: "";
  display: block;
  height: var(--hero-h);
}

.t40-transition .t40-about {
  position: sticky;
  top: 0;
  z-index: 1;
}

.t40-transition .t40-hero__film {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--hero-h);
  z-index: 2;
  overflow: hidden;
}

/* Τα στοιχεία του hero μένουν πάνω από το βίντεο και σβήνουν όταν φεύγουμε */
.t40-transition .t40-hero__center, .t40-transition .t40-hero__title, .t40-transition .t40-hero .t40-circle, .t40-transition .t40-hero__bottom {
  z-index: 3;
}

.t40-transition .t40-hero__title, .t40-transition .t40-hero__center, .t40-transition .t40-hero__bottom {
  opacity: calc(1 - var(--leave, 0) * 4);
}

.t40-transition .t40-hero .t40-circle {
  translate: 0 calc(var(--leave, 0) * -60px);
}

.t40-transition .t40-hero--leaving :is(.t40-circle, .t40-hero__bottom a, .t40-hero__bottom button) {
  visibility: hidden;
}

/* Το κείμενο εμφανίζεται γράμμα-γράμμα, από δεξιά με fade, όταν το script
   βάζει σε κάθε κείμενο την κλάση .text-in. Τα γράμματα μένουν inline για να
   μην αλλάζει η αναδίπλωση των γραμμών */
.t40-transition .t40-about {
  overflow-x: clip;
}

.t40-transition .t40-letter {
  position: relative;
  left: 70px;
  opacity: 0;
  /* Απόκρυψη όταν γυρίζουμε πίσω: γρήγορη και ταυτόχρονη */
  transition: left 0.2s, opacity 0.2s;
}

.t40-transition .t40-text-in .t40-letter {
  left: 0;
  opacity: 1;
  transition:
    left var(--duration) cubic-bezier(0.25, 0.46, 0.45, 0.94) var(--delay),
    opacity var(--duration) cubic-bezier(0.25, 0.46, 0.45, 0.94) var(--delay);
}

.t40-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ===== Banner: ξεκινά κάτω από τη μπάρα του μενού. Εδώ καταλήγει το βίντεο ===== */
.t40-banner {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
}

/* Το τελευταίο καρέ του βίντεο. Με το .transition το script του δίνει το μέγεθος
   και τη θέση που έχει το βίντεο στο τέλος της μετάβασης */
.t40-banner img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 65% 40%;
}

.t40-about__text {
  display: flex;
  flex-direction: column;
  gap: 40px;
  padding: 50px var(--side) 0;
}

.t40-about__intro {
  display: flex;
  flex-direction: column;
  gap: 20px;
  opacity: 0.8;
}

.t40-about__title {
  font-size: 40px;
  line-height: 30px;
  color: var(--t40-gold);
}

.t40-about__lead {
  font-size: 30px;
  line-height: 40px;
}

.t40-about__body {
  font-size: 16px;
  line-height: 24px;
  opacity: 0.8;
}

/* ===== Gallery: διάταξη όπως στο spykercars.com/c8-preliator =====
   Κινητό: μία στήλη, με τις μικρές εικόνες εναλλάξ δεξιά και αριστερά */
.t40-gallery {
  display: flex;
  flex-direction: column;
  gap: 48px;
  padding: 50px 20px 60px;
}

.t40-gallery__item--2, .t40-gallery__item--5 {
  align-self: flex-end;
  width: 82%;
}

.t40-gallery__item--3 {
  width: 82%;
}

.t40-gallery__frame {
  position: relative;
  overflow: hidden;
}

.t40-gallery__item--2 .t40-gallery__frame { aspect-ratio: 1.6;
}

.t40-gallery__item--3 .t40-gallery__frame { aspect-ratio: 3 / 4;
}

.t40-gallery__item--4 .t40-gallery__frame { aspect-ratio: 4 / 3;
}

.t40-gallery__item--5 .t40-gallery__frame { aspect-ratio: 1.6;
}

.t40-gallery__frame img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.t40-gallery__item--4 img {
  object-position: 50% 45%;
}

/* Parallax: η εικόνα είναι πιο ψηλή από το κάδρο και γλιστρά κάθετα μέσα του */
.t40-transition .t40-gallery__frame img {
  top: -22%;
  bottom: auto;
  height: 144%;
}

/* Η είσοδος των εικόνων ακολουθεί το scroll με μικρή, απαλή καθυστέρηση */
.t40-transition .t40-gallery__frame {
  transition: transform 0.6s cubic-bezier(0.2, 0.6, 0.3, 1), opacity 0.6s ease;
}

/* ===== The T40 in motion + Specifications =====
   Χωρίς κίνηση (reduced motion): βίντεο και από κάτω το κείμενο */
.t40-motion {
  background: var(--t40-back);
  overflow-anchor: none; /* το ύψος αλλάζει από το script, χωρίς να μετακινεί το scroll */
}

.t40-motion__film {
  position: relative;
  height: 100vh;
  height: 100svh;
  min-height: 600px;
  overflow: hidden;
  background: var(--t40-back); /* ποτέ μαύρο, ούτε πριν φορτώσει η εικόνα */
}

/* Το βίντεο γεμίζει το κάδρο. Στο scroll, το script του δίνει το μέγεθος της
   μάσκας και κρατά το θέμα μέσα της */
.t40-motion__film .t40-media {
  object-fit: cover;
  object-position: 50% 40%;
}

.t40-motion__panel {
  display: flex;
  flex-direction: column;
  gap: 40px;
  padding: 50px 20px;
}

/* Με κίνηση: η ενότητα μένει καρφωμένη όσο το scroll παίζει το βίντεο. Το ύψος
   της (δηλαδή πόσο scroll χρειάζεται) το ορίζει το script */
.t40-transition .t40-motion__stage {
  position: sticky;
  top: 0;
  z-index: 2;
  height: var(--stage-h);
  overflow: hidden;
  background: var(--t40-back);
}

.t40-transition .t40-motion__inner, .t40-transition .t40-motion__film, .t40-transition .t40-motion__panel {
  position: absolute;
}

.t40-transition .t40-motion__inner {
  inset: var(--header-h) 0 0; /* όλη η οθόνη κάτω από τη μπάρα του μενού */
}

.t40-transition .t40-motion__film {
  inset: 0;
  z-index: 1; /* πάνω από το κείμενο, ώσπου να μαζέψει η μάσκα */
  height: auto;
  min-height: 0;
}

/* "Scroll to Explore" πάνω στο βίντεο, όταν αυτό περιμένει το scroll (το script
   βάζει την .is-waiting και το ύψος, ίδιο με του κύκλου στο hero) */
.t40-motion__film .t40-circle--motion {
  display: none;
}

.t40-transition .t40-motion__film .t40-circle--motion {
  display: block;
  position: absolute;
  left: 50%;
  translate: -50% 0;
  background-color: rgba(0, 0, 0, 0.08);
  text-shadow: 0 0 8px rgba(0, 0, 0, 0.35); /* να διαβάζεται και σε ανοιχτά πλάνα */
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0s 0.4s, border-color 0.3s;
}

.t40-transition .t40-motion__film .t40-circle--motion.t40-is-waiting {
  opacity: 1;
  visibility: visible;
  transition-delay: 0s;
}

/* Κινητό: το κείμενο εμφανίζεται κάτω από το βίντεο */
.t40-transition .t40-motion__panel {
  right: 0;
  bottom: 0;
  left: 0;
  height: 50%;
  gap: 20px;
  padding: 24px 20px 0;
}

.t40-transition .t40-motion__scroll {
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

/* Οι ομάδες πατούν η μία πάνω στην άλλη: το script δείχνει μία κάθε φορά */
.t40-transition .t40-motion__scroll .t40-specs__list {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
}

.t40-transition .t40-specs__group {
  grid-area: 1 / 1;
  align-self: start;
  justify-self: end;
  visibility: hidden;
}

.t40-transition .t40-specs__group.t40-is-on {
  visibility: inherit;
}

/* Στενές οθόνες: τίτλος αριστερά και στοιχεία δεξιά, με την ίδια πάνω γραμμή */
@media (max-width: 900px) {
  .t40-transition .t40-motion__panel {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 16px;
    /* Μόνο όσο ύψος χρειάζεται η μεγαλύτερη ομάδα (πατούν όλες στο ίδιο κελί):
       το υπόλοιπο μένει στο βίντεο και δεν μένει λευκό κενό πριν από το Gallery */
    height: auto;
    padding-top: min(64px, 8vh);
    padding-bottom: 32px;
    /* στενή κεντραρισμένη στήλη, ως 540px */
    padding-inline: max(20px, calc((100% - 540px) / 2));
  }

  .t40-transition .t40-motion__panel .t40-specs__title {
    align-self: start;
    margin-top: 4px; /* τα κεφαλαία στην ίδια ευθεία με του τίτλου της ομάδας */
  }

  .t40-transition .t40-motion__panel .t40-specs__group {
    max-width: 275px; /* οι μεγάλες γραμμές αναδιπλώνονται */
  }
}

/* Κινητό: μικρότερα γράμματα, ώστε να χωρούν οι δύο στήλες δίπλα δίπλα */
@media (max-width: 599px) {
  .t40-transition .t40-motion__panel .t40-specs__title {
    font-size: 22px;
    margin-top: 3px;
  }

  .t40-transition .t40-motion__panel .t40-specs__group {
    max-width: 185px;
  }

  .t40-transition .t40-motion__panel .t40-specs__group h3 {
    font-size: 17px;
  }

  .t40-transition .t40-motion__panel .t40-specs__group ul {
    font-size: 14px;
    line-height: 20px;
  }
}

/* ===== Gallery: στήσιμο όπως στο sevenislandsways.com/tours/sunset-tour =====
   Τίτλος στη μέση και από κάτω φωτογραφίες σε μία σειρά, εναλλάξ χαμηλά και ψηλά.
   Χωρίς κίνηση (reduced motion) η σειρά κυλάει με το χέρι */
.t40-reel {
  background: var(--t40-back);
}

.t40-reel__stage {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 40px;
  padding: 60px 0 0;
}

.t40-reel__title {
  padding: 0 20px; /* στην ίδια ευθεία με την αριστερή άκρη των φωτογραφιών */
  font-size: 40px;
  font-weight: 500;
  line-height: 1;
  color: var(--t40-navy);
}

.t40-reel__view {
  margin: 0 20px;
  overflow-x: auto;
  scrollbar-width: none;
}

.t40-reel__view::-webkit-scrollbar {
  display: none;
}

.t40-reel__track {
  --per: 1;      /* πόσες φωτογραφίες χωρούν στην οθόνη */
  --space: 20px;
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: var(--space);
}

/* Όσο πλάτος του αναλογεί, αλλά ποτέ τόσο που το τετράγωνο να μη χωρά στο ύψος */
.t40-reel__item {
  flex: 0 0 min(
    calc((100% - (var(--per) - 1) * var(--space)) / var(--per)),
    calc(var(--stage-h) - var(--header-h) - var(--reel-around, 200px))
  );
}

/* Τετράγωνο κάδρο· η φωτογραφία το γεμίζει κρατώντας τις αναλογίες της */
.t40-reel__frame {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
}

.t40-reel__frame img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (min-width: 640px) {
  .t40-reel__track {
    --per: 2;
    --space: 30px;
  }

  .t40-reel__item:nth-child(odd) {
    padding-top: 50px;
  }
}

/* Στην πρώτη (κάθετη) φωτογραφία το σκάφος είναι χαμηλά: να μην κόβεται */
.t40-reel__item:first-child img {
  object-position: 50% 80%;
}

/* Με κίνηση: η ενότητα μένει καρφωμένη όσο το scroll μετακινεί τις φωτογραφίες */
.t40-transition .t40-reel__stage {
  position: sticky;
  top: 0;
  height: var(--stage-h);
  padding: var(--header-h) 0 0;
  overflow: hidden;
}

/* Στενές οθόνες: το Gallery έρχεται πιο κοντά στην προηγούμενη ενότητα. Ξεκινά όσο
   ψηλά είναι το κενό που αφήνει για τη μπάρα (εκείνο μένει πίσω της) και ο τίτλος
   του στέκεται ψηλά */
@media (max-width: 900px) {
  .t40-transition .t40-reel {
    margin-top: calc(-1 * var(--header-h));
  }

  .t40-transition .t40-reel__stage {
    justify-content: flex-start;
    padding-top: calc(var(--header-h) + 24px);
  }
}

/* Κόβει μόνο στα πλάγια, ώστε στο τέλος οι φωτογραφίες να φεύγουν προς τα πάνω */
.t40-transition .t40-reel__view {
  overflow-x: clip;
  overflow-y: visible;
  will-change: translate; /* ανεβαίνει στη μέση της οθόνης πριν κυλήσει η σειρά */
}

.t40-transition .t40-reel__track, .t40-transition .t40-reel__frame img {
  transition: translate 0.4s cubic-bezier(0.2, 0.6, 0.3, 1);
}

/* Η εικόνα είναι πιο φαρδιά από το κάδρο (25% περιθώριο σε κάθε πλευρά), ώστε
   να γλιστρά οριζόντια χωρίς να δείχνει κενά */
.t40-transition .t40-reel__frame img {
  right: auto;
  left: -25%;
  width: 150%;
  max-width: none;
}

/* Ο τίτλος εμφανίζεται όπως στο site: γυρίζει προς τα εμπρός */
.t40-transition .t40-reel__title {
  opacity: 0;
  transform: perspective(400px) translateY(20px) rotateX(-80deg);
  transform-origin: 20px 0 -50px; /* η προοπτική δεν μετακινεί την αριστερή άκρη */
}

.t40-transition .t40-reel.t40-is-in .t40-reel__title {
  opacity: 1;
  transform: perspective(400px);
  transition: opacity 1s ease 0.2s, transform 1s cubic-bezier(0.2, 0.6, 0.3, 1) 0.2s;
}

.t40-specs__title {
  font-size: 30px;
  line-height: 30px;
  color: var(--t40-gold);
}

.t40-specs__list {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

/* Και στις στενές οθόνες: ο τίτλος αριστερά, τα στοιχεία δεξιά */
.t40-specs__group {
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: right;
  opacity: 0.8;
}

.t40-specs__group h3 {
  font-size: 20px;
  line-height: 30px;
}

.t40-specs__group ul {
  font-size: 16px;
  line-height: 22px;
}

/* ===== Quote ===== */
.t40-quote {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: center;
  gap: 50px;
  height: 100vh;
  height: 100svh;
  min-height: 600px;
  padding: 30px var(--side);
  text-align: right;
  background: var(--t40-blue);
  color: var(--t40-white);
}

.t40-quote__title {
  font-size: 70px;
  line-height: 70px;
}

.t40-quote__text {
  width: 326px;
  max-width: 100%;
  padding: 0 29px;
  font-size: 20px;
  line-height: 30px;
  opacity: 0.8;
}

/* Στο τέλος του Gallery το quote ανοίγει από πάνω του: το μπλε με fade, τα
   γράμματα με την κίνηση του τίτλου του hero παιγμένη ανάποδα */
.t40-transition .t40-quote {
  position: absolute;
  inset: var(--header-h) 0 0;
  z-index: 2;
  height: auto;
  min-height: 0;
  background: rgb(15 20 35 / var(--blue-in, 0));
  pointer-events: none;
}

.t40-transition .t40-quote__text {
  opacity: calc(var(--shown, 0) * 0.8);
  position: relative;
  top: var(--lift, 0px);
}

/* Τίτλοι κομμένοι σε γράμματα (script): κάθε λέξη έχει μια μάσκα λίγο πάνω από
   τα κεφαλαία, και τα γράμματα ανεβαίνουν πίσω της ένα-ένα (--t: 0 → 1) */
.t40-split .t40-word {
  display: inline-block;
  margin: -0.25em 0;
  line-height: 1.5;
  clip-path: inset(0.2em -0.15em -0.2em);
}

.t40-split .t40-char {
  /* Πρόοδος του κάθε γράμματος: ξεκινά λίγο μετά το προηγούμενο */
  --p: clamp(0, (var(--t, 0) - var(--i) * var(--step)) / 0.44, 1);
  position: relative;
  top: calc(var(--p) * var(--p) * -1.4em);
}

/* ===== Book now ===== */
.t40-book {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100vh;
  height: 100svh;
  min-height: 600px;
  overflow: hidden;
  background: #000;
}

.t40-book__stage, .t40-book__film {
  position: absolute;
  inset: 0;
}

.t40-book__film {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Με κίνηση: η ενότητα μένει καρφωμένη όσο το scroll παίζει το βίντεο, μετά η
   μάσκα του μαζεύει και από κάτω ανεβαίνει το footer (ύψη από το script) */
.t40-transition .t40-book {
  display: block;
  min-height: 0;
  overflow: visible;
  background: none;
}

.t40-transition .t40-book__stage {
  position: sticky;
  inset: auto;
  top: 0;
  z-index: 2;
  height: var(--stage-h);
  pointer-events: none; /* ό,τι κόβει η μάσκα δεν εμποδίζει τα κλικ στο footer */
}

.t40-transition .t40-book__film {
  inset: var(--header-h) 0 0;
  display: block;
  overflow: hidden;
  background: #000;
  pointer-events: auto;
}

.t40-transition .t40-book .t40-circle--book {
  position: absolute;
  top: 50%;
  left: 50%;
  translate: -50% -50%;
}

/* ===================================================
   Desktop (Figma frame 1920 x 1080)
   --u = 1px του design
   =================================================== */
@media (min-width: 901px) {
  :root {
    --u: min(calc(100vw / 1920), calc(100vh / 1000));
    --header-h: max(80px, calc(120 * var(--u)));
  }

  .t40-circle, .t40-circle--scroll {
    width: max(130px, calc(172 * var(--u)));
    height: max(130px, calc(172 * var(--u)));
    font-size: max(13px, calc(16 * var(--u)));
    letter-spacing: 0.05em;
  }

  .t40-circle--scroll .t40-circle__arrow img {
    width: max(82px, calc(109.22 * var(--u)));
    height: max(82px, calc(109.22 * var(--u)));
  }

  .t40-circle--scroll .t40-circle__label {
    translate: none;
  }

  .t40-circle--book .t40-circle__arrow img {
    width: max(58px, calc(77.23 * var(--u)));
    height: max(58px, calc(77.23 * var(--u)));
  }

  /* ===== Hero ===== */
  .t40-hero {
    justify-content: flex-end;
    height: 100vh;
    padding: calc(30 * var(--u));
  }

  .t40-hero__center {
    position: absolute;
    top: calc(50% + 65 * var(--u));
    left: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    height: calc(566 * var(--u));
    min-height: 380px;
    translate: -50% -50%;
  }

  .t40-hero__name {
    margin-bottom: calc(-34 * var(--u));
    font-size: calc(128 * var(--u));
  }

  .t40-hero__script {
    font-size: calc(70 * var(--u));
  }

  .t40-hero__bottom {
    justify-content: space-between;
    align-items: center;
    padding: 0;
  }

  .t40-hero__chevron {
    display: block;
  }

  .t40-hero__skip {
    padding: 10px;
  }

  /* ===== Description ===== */
  .t40-about {
    min-height: 100vh;
  }

  /* Περιθώριο μόνο αριστερά, δεξιά ως την άκρη της οθόνης */
  .t40-banner {
    height: min(690px, 71vh);
    margin-left: min(100px, 5.2vw);
    aspect-ratio: auto;
  }

  /* Κείμενα όπως στο Figma (node 84:726): δύο ίσες στήλες, ευθυγραμμισμένες κάτω */
  .t40-about__text {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: end;
    column-gap: calc(139 * var(--u));
    /* πάνω: απόσταση από το banner, κάτω: κενό ως τις φωτογραφίες */
    padding: calc(260 * var(--u)) var(--side) calc(200 * var(--u));
  }

  .t40-about__intro {
    gap: calc(58 * var(--u));
  }

  .t40-about__title {
    font-size: calc(70 * var(--u));
    line-height: calc(30 * var(--u));
  }

  .t40-about__lead {
    font-size: max(24px, calc(50 * var(--u)));
    line-height: 1.2;
  }

  .t40-about__body {
    font-size: max(14px, calc(20 * var(--u)));
    line-height: 1.5;
  }

  /* Πλέγμα 12 στηλών με τις αναλογίες του Spyker (1440px μέσα σε 2000px) */
  .t40-gallery {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    align-items: start;
    gap: 4vw 1.2vw;
    width: 72vw;
    margin: 0 auto;
    padding: 0 0 10vw;
  }

  .t40-gallery__item--2 { grid-area: 1 / 8 / auto / span 5; margin-top: 7vw; width: auto;
  }

  .t40-gallery__item--3 { grid-area: 2 / 2 / auto / span 5; margin-top: -12.4vw; width: auto;
  }

  .t40-gallery__item--4 { grid-area: 3 / 3 / auto / span 8;
  }

  .t40-gallery__item--5 { grid-area: 4 / 2 / auto / span 5; width: auto;
  }

  /* ===== The T40 in motion + Specifications (Figma 25:751) ===== */
  .t40-motion__panel {
    --panel-right: max(40px, calc(100 * var(--u)));
    gap: calc(140 * var(--u));
    width: max(320px, calc(520 * var(--u)));
    padding: calc(50 * var(--u)) var(--panel-right) calc(60 * var(--u)) calc(30 * var(--u));
    text-align: right;
  }

  /* Χωρίς κίνηση: βίντεο αριστερά, κείμενο δεξιά */
  .t40-motion__stage {
    padding-top: var(--header-h);
  }

  .t40-motion__inner {
    display: flex;
    height: calc(100vh - var(--header-h));
  }

  .t40-motion__film {
    flex: 1;
    height: auto;
    min-height: 0;
  }

  .t40-motion__panel {
    flex-shrink: 0;
    overflow-y: auto;
  }

  .t40-transition .t40-motion__stage {
    padding-top: 0;
  }

  .t40-transition .t40-motion__inner {
    display: block;
    height: auto;
  }

  .t40-transition .t40-motion__panel {
    left: auto;
    top: 0;
    height: auto;
    gap: calc(40 * var(--u));
    /* ο τίτλος ψηλά και οι ομάδες χαμηλά, με σχεδόν ίσο κενό από τις άκρες */
    padding:
      calc((var(--stage-h) - var(--header-h)) * 0.12) var(--panel-right)
      calc((var(--stage-h) - var(--header-h)) * 0.13) calc(30 * var(--u));
    overflow: hidden;
  }

  /* Κάθε ομάδα τελειώνει στο ίδιο ύψος, όσες γραμμές κι αν έχει */
  .t40-transition .t40-motion__scroll {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
  }

  .t40-transition .t40-specs__group {
    align-self: end;
  }

  /* ===== Gallery (διαστάσεις του site στα 1920px) ===== */
  .t40-reel__stage {
    gap: calc(100 * var(--u)); /* κενό τίτλου – φωτογραφιών */
  }

  /* Αριστερά, στην ίδια ευθεία με τα κείμενα του "Description" */
  .t40-reel__title {
    padding: 0 var(--side);
    font-size: max(34px, calc(60 * var(--u)));
    text-align: left;
  }

  /* Η προοπτική της εμφάνισης μεγεθύνει λίγο τον τίτλο: να μένει σταθερή η
     αριστερή του άκρη */
  .t40-transition .t40-reel__title {
    transform-origin: var(--side) 0 -50px;
  }

  /* Φωτογραφίες όπως στο site: 4 στην οθόνη (3 ως τα 1199px), ύψος 498px, κενό
     30px, εναλλάξ 100px πιο χαμηλά. Σε χαμηλές οθόνες μικραίνουν ώστε να χωράνε */
  .t40-reel__view {
    margin: 0;
  }

  .t40-reel__track {
    --per: 3;
  }

  .t40-reel__item {
    flex-basis: calc((100% - (var(--per) - 1) * var(--space)) / var(--per));
  }

  .t40-reel__item:nth-child(odd) {
    padding-top: min(100px, 10vh);
  }

  .t40-reel__frame {
    aspect-ratio: auto;
    height: min(498px, calc(var(--stage-h) - var(--header-h) - 300 * var(--u)));
  }

  /* Το gallery ξεκινά ψηλά, λίγο κάτω από τη μπάρα του μενού */
  .t40-transition .t40-reel__stage {
    justify-content: flex-start;
    padding-top: calc(var(--header-h) + 30 * var(--u));
  }

  .t40-specs__title {
    font-size: max(30px, calc(50 * var(--u)));
    font-weight: 500;
    color: var(--t40-black);
  }

  .t40-specs__list {
    align-items: flex-end;
    gap: calc(167 * var(--u));
  }

  .t40-specs__group {
    flex-shrink: 0;
    gap: calc(22 * var(--u));
    width: 100%;
  }

  .t40-specs__group h3 {
    font-size: max(20px, calc(30 * var(--u)));
    font-weight: 500;
    line-height: 1.2;
  }

  .t40-specs__group ul {
    font-size: max(14px, calc(20 * var(--u)));
    font-weight: 400;
    line-height: 1.5;
  }

  /* ===== Quote ===== */
  .t40-quote {
    gap: calc(77 * var(--u));
    height: 100vh;
    padding: calc(30 * var(--u)) var(--side);
  }

  .t40-quote__title {
    font-size: calc(100 * var(--u));
    line-height: 1;
  }

  .t40-quote__text {
    width: max(280px, calc(326 * var(--u)));
    padding: 0 calc(29 * var(--u));
    font-size: max(15px, calc(20 * var(--u)));
    line-height: 1.5;
  }

  /* ===== Book now ===== */
  .t40-book {
    display: block;
    height: 100vh;
  }

  .t40-book .t40-media {
    object-position: 50% 45%;
  }

  .t40-circle--book {
    position: absolute;
    top: 45%;
    left: 50%;
    translate: -50% -50%;
  }
}

/* Πλατιές οθόνες: 4 φωτογραφίες, και από 1920px το αριστερό περιθώριο του site */
@media (min-width: 1200px) {
  .t40-reel__track {
    --per: 4;
  }
}

@media (min-width: 1920px) {
  .t40-reel__view {
    margin-left: 100px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .t40-circle--scroll .t40-circle__arrow {
    animation: none;
  }

  /* Χωρίς κίνηση: σταθερά ύψη όταν ο ήχος είναι on */
  .t40-hero__sound[aria-pressed="true"] .t40-equalizer span {
    height: 14px;
    animation: none !important;
  }

  .t40-hero__sound[aria-pressed="true"] .t40-equalizer span:nth-child(even) {
    height: 22px;
  }
}

/* ==========================================================
   ΠΑΡΑΛΛΑΓΗ: στο desktop τα τρία βίντεο (hero, "in motion",
   "book") κάθονται κάτω από τη μπάρα, πιο κοντά στην πάνω
   πλευρά. Το banner έχει την ίδια θέση
   ========================================================== */
@media (min-width: 901px) {
  :root {
    /* Το ελεύθερο ύψος μοιράζεται 1/3 πάνω και 2/3 κάτω από το βίντεο */
    --video-space: 15vh;
    --video-gap-top: calc(var(--video-space) / 3);
    --video-gap-bottom: calc(var(--video-space) * 2 / 3);
    --video-h: calc(100vh - var(--header-h) - var(--video-space));
    --video-top: calc(var(--header-h) + var(--video-gap-top));
  }

  /* Ίδια θέση και ύψος με το βίντεο, ώστε η μετάβαση του hero να καταλήγει
     ακριβώς πάνω του */
  .t40-transition .t40-about {
    padding-top: var(--video-top);
  }

  .t40-transition .t40-banner {
    height: var(--video-h);
  }

  /* Hero */
  .t40-transition .t40-hero {
    min-height: 0;
    /* τα κουμπιά της κάτω σειράς μένουν μέσα στο βίντεο */
    padding-bottom: calc(var(--video-gap-bottom) + 30 * var(--u));
  }

  .t40-transition .t40-hero .t40-media {
    top: var(--video-top);
    height: var(--video-h);
  }

  /* Τίτλος και κύκλος στη μέση του βίντεο */
  .t40-transition .t40-hero__center {
    top: calc(var(--video-top) + var(--video-h) / 2);
    height: min(calc(566 * var(--u)), calc(var(--video-h) - 60 * var(--u)));
    min-height: 0;
  }

  /* The T40 in motion + Specifications */
  .t40-transition .t40-motion__inner {
    top: var(--video-top);
    bottom: auto;
    height: var(--video-h);
  }

  .t40-transition .t40-motion__panel {
    padding-top: calc(var(--video-h) * 0.12);
    padding-bottom: calc(var(--video-h) * 0.13);
  }

  /* Το Gallery έρχεται πιο κοντά: καλύπτει το κενό που μένει κάτω από το βίντεο */
  .t40-transition .t40-reel {
    margin-top: calc(-1 * var(--video-gap-bottom));
  }

  /* Book: γύρω από το βίντεο μένει λευκό, εκεί κάτω ανεβαίνει στο τέλος το footer */
  .t40-transition .t40-book__film {
    background: var(--t40-back);
  }

  .t40-transition .t40-book__film .t40-media {
    top: var(--video-gap-top); /* η μάσκα ξεκινά ήδη κάτω από τη μπάρα */
    bottom: auto;
  }
}

/* ===================================================
   Ενσωμάτωση στο theme (header / footer του project).
   Το αρχείο φορτώνεται μόνο σε αυτή τη σελίδα
   =================================================== */

/* Κινητό: το βίντεο του hero ξεκινά κάτω από τη μπάρα */
@media (max-width: 900px) {
  .t40-transition .t40-hero .t40-media {
    top: var(--header-h);
    height: calc(100% - var(--header-h));
  }
}

/* Το footer ανεβαίνει κάτω από το τελευταίο banner */
.t40-transition .sw-footer {
  position: relative;
  z-index: 1;
  margin-top: calc(-1 * var(--book-peek, 0px));
}
