:root {
  --color-abyss: #0a1928;
  --color-tide: #123f4a;
  --color-tide-soft: #1d5b63;
  --color-parchment: #f4e4c1;
  --color-parchment-deep: #dfc690;
  --color-brass: #c9a03d;
  --color-amber: #e6a817;
  --color-ink: #26313a;
  --color-mist: rgba(244, 228, 193, 0.76);
  --color-panel: rgba(244, 228, 193, 0.1);
  --shadow-deep: 0 24px 70px rgba(0, 0, 0, 0.34);
  --shadow-brass: 0 0 24px rgba(201, 160, 61, 0.24);
  --radius-panel: 8px;
  --radius-small: 6px;
  --max-width: 1160px;
  --header-height: 74px;
  --transition: 180ms ease;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--color-parchment);
  background:
    linear-gradient(180deg, rgba(5, 12, 22, 0.78), rgba(6, 19, 30, 0.9)),
    radial-gradient(circle at 16% 18%, rgba(230, 168, 23, 0.08), transparent 30%),
    radial-gradient(circle at 82% 4%, rgba(29, 91, 99, 0.24), transparent 36%),
    url("site-assets/maritime-collage-bg.png") center top / cover fixed,
    linear-gradient(135deg, #06101d 0%, var(--color-abyss) 48%, #0f2931 100%);
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.6;
  overflow-x: hidden;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
}

body::before {
  opacity: 0.12;
  background-image:
    linear-gradient(32deg, transparent 0 48%, rgba(244, 228, 193, 0.18) 49% 50%, transparent 51% 100%),
    linear-gradient(118deg, transparent 0 51%, rgba(244, 228, 193, 0.12) 52% 53%, transparent 54% 100%),
    linear-gradient(0deg, rgba(244, 228, 193, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(244, 228, 193, 0.05) 1px, transparent 1px);
  background-size: 560px 560px, 680px 680px, 140px 140px, 140px 140px;
}

body::after {
  opacity: 0.24;
  background:
    linear-gradient(180deg, rgba(5, 12, 22, 0.18), rgba(5, 12, 22, 0.62)),
    repeating-radial-gradient(circle at 50% 50%, rgba(244, 228, 193, 0.08) 0 1px, transparent 1px 6px);
  mix-blend-mode: overlay;
}

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

button,
input,
textarea {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: var(--header-height);
  border-bottom: 1px solid rgba(244, 228, 193, 0.16);
  background: rgba(10, 25, 40, 0.86);
  backdrop-filter: blur(16px);
}

.nav {
  width: min(100% - 32px, var(--max-width));
  min-height: var(--header-height);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  letter-spacing: 0;
  font-weight: 700;
}

.brand-mark {
  width: 38px;
  height: 38px;
  border: 1px solid rgba(201, 160, 61, 0.75);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--color-brass);
  box-shadow: var(--shadow-brass);
}

.brand-mark::before {
  content: "✦";
  transform: translateY(-1px);
}

.brand small {
  display: block;
  color: rgba(244, 228, 193, 0.68);
  font-size: 0.76rem;
  font-weight: 400;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(244, 228, 193, 0.3);
  border-radius: var(--radius-small);
  background: rgba(244, 228, 193, 0.08);
  color: var(--color-parchment);
  cursor: pointer;
}

.nav-toggle span,
.nav-toggle::before,
.nav-toggle::after {
  content: "";
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: currentColor;
  transition: transform var(--transition), opacity var(--transition);
}

.nav-toggle.is-open span {
  opacity: 0;
}

.nav-toggle.is-open::before {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.is-open::after {
  transform: translateY(-7px) rotate(-45deg);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  position: relative;
  display: block;
  padding: 10px 12px;
  border-radius: var(--radius-small);
  color: rgba(244, 228, 193, 0.82);
  font-size: 0.95rem;
  transition: color var(--transition), background var(--transition), transform var(--transition);
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: var(--color-parchment);
  background: rgba(201, 160, 61, 0.12);
  transform: translateY(-1px);
  outline: none;
}

.section {
  width: min(100% - 32px, var(--max-width));
  margin: 0 auto;
  padding: 84px 0;
}

.hero {
  min-height: calc(100vh - var(--header-height));
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.8fr);
  align-items: center;
  gap: 56px;
  padding-top: 72px;
  padding-bottom: 78px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
  color: var(--color-brass);
  text-transform: uppercase;
  font-family: Arial, sans-serif;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
}

.eyebrow::before {
  content: "";
  width: 42px;
  height: 1px;
  background: currentColor;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin-bottom: 20px;
  color: var(--color-parchment);
  font-size: clamp(3rem, 8vw, 6.7rem);
  line-height: 0.92;
  letter-spacing: 0;
  text-wrap: balance;
}

h2 {
  margin-bottom: 18px;
  color: var(--color-parchment);
  font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.04;
  text-wrap: balance;
}

h3 {
  color: var(--color-parchment);
  font-size: 1.35rem;
  line-height: 1.15;
}

.hero-copy {
  max-width: 640px;
  color: rgba(244, 228, 193, 0.8);
  font-size: 1.18rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid rgba(201, 160, 61, 0.72);
  border-radius: var(--radius-small);
  background: linear-gradient(180deg, rgba(230, 168, 23, 0.94), rgba(201, 160, 61, 0.86));
  color: #17202a;
  font-family: Arial, sans-serif;
  font-weight: 700;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 14px 36px rgba(230, 168, 23, 0.25);
  outline: none;
}

.button-secondary {
  background: rgba(244, 228, 193, 0.07);
  color: var(--color-parchment);
}

.captain-frame {
  position: relative;
  isolation: isolate;
  min-height: 520px;
  padding: 20px;
  border: 1px solid rgba(201, 160, 61, 0.38);
  border-radius: var(--radius-panel);
  background: rgba(244, 228, 193, 0.08);
  box-shadow: var(--shadow-deep);
  animation: revealPhoto 900ms ease both;
}

.captain-frame::before {
  content: "";
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(244, 228, 193, 0.24);
  border-radius: var(--radius-small);
  pointer-events: none;
}

.captain-photo {
  position: relative;
  margin: 0;
  min-height: 480px;
  border-radius: var(--radius-small);
  overflow: hidden;
  background: linear-gradient(135deg, #26313a, #0a1928);
  filter: sepia(0.14) saturate(0.96) contrast(1.04);
}

.captain-photo img {
  display: block;
  width: 100%;
  height: 480px;
  object-fit: cover;
  object-position: center 22%;
  transform: scale(1.02);
}

.captain-photo::before,
.captain-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.captain-photo::before {
  background:
    linear-gradient(180deg, transparent 42%, rgba(10, 25, 40, 0.7) 100%),
    radial-gradient(circle at 50% 20%, transparent 0 42%, rgba(10, 25, 40, 0.28) 100%);
}

.captain-photo::after {
  opacity: 0.24;
  background:
    repeating-linear-gradient(0deg, rgba(244, 228, 193, 0.24) 0 1px, transparent 1px 5px),
    repeating-linear-gradient(90deg, rgba(10, 25, 40, 0.22) 0 1px, transparent 1px 7px);
  mix-blend-mode: overlay;
}

.captain-photo figcaption {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 16px;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 10px;
  border: 1px solid rgba(244, 228, 193, 0.28);
  border-radius: var(--radius-small);
  background: rgba(10, 25, 40, 0.42);
  color: rgba(244, 228, 193, 0.78);
  font-family: Arial, sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.helm {
  position: absolute;
  right: -26px;
  top: -30px;
  z-index: 4;
  display: block;
  width: 148px;
  height: 148px;
  border-radius: 50%;
  filter: drop-shadow(0 18px 24px rgba(0, 0, 0, 0.45)) drop-shadow(0 0 18px rgba(201, 160, 61, 0.32));
  box-shadow:
    0 0 0 1px rgba(244, 228, 193, 0.18),
    0 0 26px rgba(201, 160, 61, 0.24);
  animation: helmSteer 32s cubic-bezier(0.42, 0, 0.25, 1) infinite;
  transform-origin: center;
}

.section-heading {
  max-width: 720px;
  margin-bottom: 34px;
}

.section-heading p {
  color: rgba(244, 228, 193, 0.76);
  font-size: 1.08rem;
}

.section-heading .logbook-voyage-subtitle {
  color: var(--color-brass);
  font-family: Arial, sans-serif;
  font-size: 1.5rem;
  margin-bottom: 8px;
}

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) repeat(3, minmax(160px, 0.6fr));
  gap: 18px;
  align-items: stretch;
}

.parchment,
.fact,
.route-card,
.ai-panel,
.contact-panel {
  border: 1px solid rgba(201, 160, 61, 0.32);
  border-radius: var(--radius-panel);
  background:
    linear-gradient(135deg, rgba(244, 228, 193, 0.16), rgba(244, 228, 193, 0.06)),
    rgba(10, 25, 40, 0.54);
  box-shadow: 0 16px 50px rgba(0, 0, 0, 0.2);
}

.parchment {
  padding: 28px;
}

.parchment p {
  margin-bottom: 0;
  color: rgba(244, 228, 193, 0.82);
}

.fact {
  padding: 22px;
}

.fact strong {
  display: block;
  color: var(--color-amber);
  font-family: Arial, sans-serif;
  font-size: 2rem;
  line-height: 1;
}

.fact span {
  display: block;
  margin-top: 12px;
  color: rgba(244, 228, 193, 0.76);
  font-size: 0.98rem;
}

.routes-map {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  padding: 28px;
  border: 1px solid rgba(201, 160, 61, 0.22);
  border-radius: var(--radius-panel);
  background:
    linear-gradient(180deg, rgba(6, 13, 22, 0.52), rgba(6, 13, 22, 0.86)),
    url("site-assets/routes-dark-map.png") center / cover;
  box-shadow: inset 0 0 70px rgba(10, 25, 40, 0.7);
}

.routes-map::before {
  content: "";
  position: absolute;
  inset: -28px -16px;
  z-index: -1;
  opacity: 0.26;
  background:
    radial-gradient(circle at 16% 24%, transparent 0 30px, rgba(244, 228, 193, 0.6) 31px 32px, transparent 33px),
    radial-gradient(circle at 58% 64%, transparent 0 44px, rgba(244, 228, 193, 0.54) 45px 46px, transparent 47px),
    radial-gradient(circle at 82% 22%, transparent 0 28px, rgba(244, 228, 193, 0.48) 29px 30px, transparent 31px);
}

.route-card {
  position: relative;
  min-height: 420px;
  padding: 0 22px 24px;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(10, 25, 40, 0.18), rgba(10, 25, 40, 0.82) 42%),
    rgba(10, 25, 40, 0.82);
  backdrop-filter: blur(4px);
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.route-card:hover {
  transform: translateY(-5px);
  border-color: rgba(230, 168, 23, 0.72);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28), var(--shadow-brass);
}

.route-card::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.14;
  background:
    linear-gradient(120deg, transparent 0 46%, rgba(230, 168, 23, 0.8) 47% 48%, transparent 49% 100%),
    radial-gradient(circle at 76% 18%, rgba(230, 168, 23, 0.5), transparent 18%);
  transition: transform 600ms ease;
}

.route-card:hover::before {
  transform: scale(1.08);
}

.route-image {
  position: relative;
  z-index: 1;
  display: block;
  width: calc(100% + 44px);
  height: 180px;
  margin: 0 -22px 22px;
  object-fit: cover;
  border-bottom: 1px solid rgba(201, 160, 61, 0.34);
  filter: saturate(1.08) contrast(1.04);
  transition: transform 500ms ease, filter 500ms ease;
}

.route-card:hover .route-image {
  transform: scale(1.04);
  filter: saturate(1.18) contrast(1.08);
}

.route-card h3,
.route-card p,
.risk,
.route-line {
  position: relative;
  z-index: 1;
}

.route-card p {
  color: rgba(244, 228, 193, 0.78);
}

.risk {
  display: inline-flex;
  margin-top: 8px;
  padding: 5px 9px;
  border: 1px solid rgba(230, 168, 23, 0.36);
  border-radius: 999px;
  color: var(--color-amber);
  font-family: Arial, sans-serif;
  font-size: 0.78rem;
  text-transform: uppercase;
}

.route-line {
  height: 84px;
  margin-top: 28px;
  border-bottom: 2px dashed rgba(244, 228, 193, 0.42);
  border-radius: 0 0 50% 50%;
}

.ship-dot {
  position: absolute;
  left: 12%;
  bottom: 60px;
  z-index: 2;
  color: var(--color-amber);
  font-size: 1.1rem;
  animation: sail 4.4s ease-in-out infinite;
}

.logbook-panel {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(201, 160, 61, 0.34);
  border-radius: var(--radius-panel);
  background:
    linear-gradient(135deg, rgba(244, 228, 193, 0.12), rgba(244, 228, 193, 0.04)),
    linear-gradient(180deg, rgba(7, 15, 25, 0.92), rgba(10, 25, 40, 0.88)),
    url("site-assets/routes-dark-map.png") center / cover;
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.28), inset 0 0 0 1px rgba(244, 228, 193, 0.06);
}

.logbook-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.28;
  background:
    linear-gradient(90deg, transparent 0 49%, rgba(244, 228, 193, 0.22) 49% 50%, transparent 50%),
    repeating-linear-gradient(0deg, transparent 0 38px, rgba(244, 228, 193, 0.08) 39px 40px);
  pointer-events: none;
}

.logbook-topline {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
  padding: 18px 22px;
  border-bottom: 1px solid rgba(201, 160, 61, 0.26);
  color: rgba(244, 228, 193, 0.72);
  font-family: Arial, sans-serif;
  font-size: 0.82rem;
  text-transform: uppercase;
}

.logbook-slider {
  position: relative;
  z-index: 1;
  min-height: 500px;
}

.log-slide {
  display: none;
  padding: 34px clamp(22px, 5vw, 58px) 28px;
}

.log-slide.is-active {
  display: block;
  animation: logFade 260ms ease both;
}

.log-date {
  margin-bottom: 14px;
  color: var(--color-amber);
  font-family: Arial, sans-serif;
  font-size: 0.86rem;
  text-transform: uppercase;
}

.log-slide h3 {
  max-width: 720px;
  margin-bottom: 22px;
  font-size: clamp(1.1rem, 2.5vw, 1.8rem);
}

.log-slide ul {
  display: grid;
  gap: 14px;
  max-width: 920px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.log-slide li {
  padding: 14px 16px;
  border: 1px solid rgba(244, 228, 193, 0.12);
  border-radius: var(--radius-small);
  background: rgba(10, 25, 40, 0.46);
  color: rgba(244, 228, 193, 0.82);
}

.log-slide time {
  display: inline-block;
  min-width: 54px;
  margin-right: 8px;
  color: var(--color-brass);
  font-family: Arial, sans-serif;
  font-weight: 700;
}

.log-event {
  max-width: 920px;
  margin: 20px 0 0;
  padding: 16px 18px;
  border-left: 3px solid var(--color-amber);
  border-radius: 0 var(--radius-small) var(--radius-small) 0;
  background: rgba(230, 168, 23, 0.09);
  color: rgba(244, 228, 193, 0.88);
}

.logbook-controls {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 22px 22px;
  border-top: 1px solid rgba(201, 160, 61, 0.24);
}

.icon-button {
  width: 44px;
  height: 44px;
  border: 1px solid rgba(201, 160, 61, 0.52);
  border-radius: 50%;
  background: rgba(10, 25, 40, 0.72);
  color: var(--color-parchment);
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  transition: transform var(--transition), border-color var(--transition), background var(--transition);
}

.icon-button:hover,
.icon-button:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(230, 168, 23, 0.82);
  background: rgba(230, 168, 23, 0.14);
  outline: none;
}

.log-dots {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.log-dot {
  width: 10px;
  height: 10px;
  border: 1px solid rgba(244, 228, 193, 0.5);
  border-radius: 50%;
  background: rgba(244, 228, 193, 0.14);
  cursor: pointer;
}

.log-dot.is-active {
  border-color: var(--color-amber);
  background: var(--color-amber);
  box-shadow: 0 0 14px rgba(230, 168, 23, 0.42);
}

.ai-panel,
.contact-panel {
  padding: 28px;
}

.ai-panel {
  position: relative;
  overflow: hidden;
  min-height: 430px;
  display: grid;
  align-content: end;
  background:
    linear-gradient(90deg, rgba(6, 13, 22, 0.88), rgba(6, 13, 22, 0.58) 58%, rgba(6, 13, 22, 0.78)),
    url("site-assets/ai-steampunk-panel.png") center / cover;
}

.ai-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, transparent 0 38%, rgba(230, 168, 23, 0.12) 39% 40%, transparent 41% 100%),
    linear-gradient(0deg, transparent 0 52%, rgba(230, 168, 23, 0.1) 53% 54%, transparent 55% 100%),
    radial-gradient(circle at 72% 38%, rgba(230, 168, 23, 0.22), transparent 24%);
  background-size: 120px 120px;
  opacity: 0.8;
  pointer-events: none;
}

.ai-panel > * {
  position: relative;
  z-index: 1;
  max-width: 580px;
}

.contact-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(210px, 0.72fr);
  gap: 18px;
  align-items: stretch;
  max-width: 900px;
  margin: 0 auto;
  padding: 18px;
}

.contact-form-side {
  padding: 10px;
}

.contact-form-side h2 {
  font-size: clamp(1.8rem, 3vw, 2.6rem);
}

.contact-panel textarea {
  min-height: 86px;
}

.contact-visual {
  position: relative;
  min-height: 100%;
  margin: 0;
  border-radius: var(--radius-small);
  overflow: hidden;
  border: 1px solid rgba(201, 160, 61, 0.28);
  background: rgba(10, 25, 40, 0.56);
}

.contact-visual img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 300px;
  object-fit: cover;
  filter: saturate(1.02) contrast(1.04) brightness(0.9);
}

.contact-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, transparent 48%, rgba(10, 25, 40, 0.42)),
    radial-gradient(circle at 20% 14%, rgba(230, 168, 23, 0.16), transparent 28%);
  pointer-events: none;
}

.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--color-amber);
  font-family: Arial, sans-serif;
  font-size: 0.82rem;
  text-transform: uppercase;
}

.status-chip::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--color-amber);
  box-shadow: 0 0 14px var(--color-amber);
}

form {
  display: grid;
  gap: 14px;
}

label {
  display: grid;
  gap: 7px;
  color: rgba(244, 228, 193, 0.78);
  font-family: Arial, sans-serif;
  font-size: 0.9rem;
}

input,
textarea {
  width: 100%;
  border: 1px solid rgba(201, 160, 61, 0.32);
  border-radius: var(--radius-small);
  background: rgba(10, 25, 40, 0.58);
  color: var(--color-parchment);
  padding: 12px 13px;
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}

textarea {
  min-height: 126px;
  resize: vertical;
}

input:focus,
textarea:focus {
  border-color: rgba(230, 168, 23, 0.76);
  box-shadow: 0 0 0 3px rgba(230, 168, 23, 0.12);
}

.form-message {
  min-height: 24px;
  margin: 0;
  color: var(--color-amber);
  font-family: Arial, sans-serif;
  font-size: 0.92rem;
}

.site-footer {
  border-top: 1px solid rgba(244, 228, 193, 0.14);
  padding: 28px 0;
  color: rgba(244, 228, 193, 0.62);
  font-family: Arial, sans-serif;
  font-size: 0.9rem;
  text-align: center;
}

@keyframes helmSteer {
  0% { transform: rotate(0deg); }
  7% { transform: rotate(-8deg); }
  14% { transform: rotate(5deg); }
  22% { transform: rotate(-14deg); }
  30% { transform: rotate(9deg); }
  38% { transform: rotate(-4deg); }
  48% { transform: rotate(12deg); }
  57% { transform: rotate(-10deg); }
  66% { transform: rotate(6deg); }
  74% { transform: rotate(-16deg); }
  79% { transform: rotate(12deg); }
  82% { transform: rotate(188deg); }
  84% { transform: rotate(270deg); }
  86% { transform: rotate(360deg); }
  90% { transform: rotate(344deg); }
  94% { transform: rotate(372deg); }
  100% { transform: rotate(360deg); }
}

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

@keyframes revealPhoto {
  from {
    opacity: 0;
    filter: sepia(0.7) blur(8px);
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    filter: sepia(0);
    transform: translateY(0);
  }
}

@keyframes sail {
  0%,
  100% {
    transform: translate(0, 0) rotate(-7deg);
  }
  50% {
    transform: translate(138px, -18px) rotate(7deg);
  }
}

@media (max-width: 900px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    left: 16px;
    right: 16px;
    top: calc(var(--header-height) - 4px);
    display: grid;
    gap: 4px;
    padding: 12px;
    border: 1px solid rgba(244, 228, 193, 0.16);
    border-radius: var(--radius-panel);
    background: rgba(10, 25, 40, 0.96);
    box-shadow: var(--shadow-deep);
    transform: translateY(-10px);
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition), transform var(--transition);
  }

  .nav-links.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .hero,
  .about-grid,
  .routes-map {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    gap: 36px;
  }

  .captain-frame {
    min-height: 420px;
  }

  .captain-photo {
    min-height: 380px;
  }

  .helm {
    right: 8px;
    top: 8px;
    width: 96px;
    height: 96px;
  }

}

@media (max-width: 560px) {
  .section {
    width: min(100% - 24px, var(--max-width));
    padding: 58px 0;
  }

  .hero {
    padding-top: 44px;
  }

  h1 {
    font-size: 3rem;
  }

  .actions {
    display: grid;
  }

  .button {
    width: 100%;
  }

  .logbook-topline,
  .logbook-controls {
    padding-left: 16px;
    padding-right: 16px;
  }

  .logbook-slider {
    min-height: 620px;
  }

  .log-slide {
    padding: 24px 16px 20px;
  }

  .log-slide li {
    padding: 12px;
  }

  .log-slide time {
    display: block;
    margin-bottom: 4px;
  }

  .parchment,
  .fact,
  .route-card,
  .ai-panel,
  .contact-panel {
    padding: 20px;
  }

  .routes-map {
    padding: 14px;
  }

  .route-card {
    padding: 0 18px 22px;
  }

  .route-image {
    width: calc(100% + 36px);
    height: 150px;
    margin: 0 -18px 18px;
  }

  .ai-panel {
    min-height: 440px;
    background-position: 58% center;
  }

  .contact-panel {
    grid-template-columns: 1fr;
    padding: 14px;
  }

  .contact-visual img {
    min-height: 220px;
  }

  .captain-frame {
    min-height: 350px;
    padding: 12px;
  }

  .captain-photo {
    min-height: 326px;
  }
}
