/* LA Marine – Rovinj Boat Rental */
:root {
  --navy: #1a2f4a;
  --navy-dark: #0f1f33;
  --navy-light: #2a4568;
  --gold: #b8942e;
  --gold-light: #d4b04a;
  --gold-dark: #967622;
  --white: #ffffff;
  --cream: #f8f6f2;
  --text: #1a2f4a;
  --text-muted: #5a6d82;
  --border: rgba(26, 47, 74, 0.12);
  --shadow: 0 4px 24px rgba(15, 31, 51, 0.1);
  --shadow-lg: 0 12px 40px rgba(15, 31, 51, 0.15);
  --radius: 12px;
  --radius-lg: 16px;
  --transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans: 'Source Sans 3', system-ui, sans-serif;
  --font-script: 'Caveat', cursive;
  --header-pad: 1rem;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 1rem;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--navy); }

/* ── Hero header ── */
.site-header {
  position: relative;
  overflow: hidden;
  border-bottom: none;
  min-height: min(92vh, 800px);
  padding: 0 var(--header-pad) 1.25rem;
  text-align: center;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: url('../cydonia-rovinj-4300772.jpg') center 32% / cover no-repeat;
  transform: scale(1.38);
  transition: transform 8s ease-out;
}

.site-header:hover .hero-bg {
  transform: scale(1.42);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom,
      rgba(15, 31, 51, 0.62) 0%,
      rgba(15, 31, 51, 0.58) 42%,
      rgba(15, 31, 51, 0.64) 78%,
      rgba(248, 246, 242, 0.94) 94%,
      var(--cream) 100%);
}

/* Flex center — avoids conflict with .reveal transform */
.hero-logo-zone {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem var(--header-pad) 9rem;
  box-sizing: border-box;
  pointer-events: none;
}

.hero-logo-zone .header-inner {
  pointer-events: auto;
  position: relative;
  left: auto;
  top: auto;
  transform: none;
  width: 100%;
  max-width: 640px;
  margin: 0;
  padding: 0;
  text-align: center;
}

.header-inner.reveal {
  opacity: 0;
  transform: translateY(20px);
}

.header-inner.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.logo-link {
  display: inline-block;
  line-height: 0;
  background: none;
  border: none;
  box-shadow: none;
}

.logo-img {
  margin: 0 auto;
  display: block;
  background: transparent;
}

.logo-img--hero {
  width: auto;
  height: min(480px, 58vh);
  max-width: min(560px, 92vw);
  transform: translateY(100px);
  object-fit: contain;
  filter:
    drop-shadow(0 2px 12px rgba(15, 31, 51, 0.65))
    drop-shadow(0 8px 32px rgba(15, 31, 51, 0.45));
}

.tagline {
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 5vw, 2.25rem);
  font-style: italic;
  font-weight: 500;
  color: var(--gold-light);
  letter-spacing: 0.05em;
  margin: 0.75rem 0 0;
  text-shadow:
    0 1px 3px rgba(15, 31, 51, 0.9),
    0 2px 16px rgba(15, 31, 51, 0.6);
}

/* Nav buttons pinned to bottom of hero */
.category-nav {
  position: absolute;
  left: 50%;
  bottom: 1.25rem;
  transform: translateX(-50%);
  z-index: 3;
  max-width: 520px;
  width: calc(100% - 2rem);
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.category-nav.reveal {
  opacity: 0;
  transform: translateX(-50%) translateY(16px);
}

.category-nav.reveal.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.nav-row {
  display: flex;
  gap: 0.65rem;
  justify-content: center;
}

.nav-btn {
  flex: 1;
  max-width: 200px;
  padding: 0.75rem 1rem;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--navy);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 2px solid rgba(26, 47, 74, 0.25);
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transition), color var(--transition), border-color var(--transition), transform 0.2s, box-shadow var(--transition);
  box-shadow: 0 2px 12px rgba(15, 31, 51, 0.08);
}

.nav-btn:hover,
.nav-btn:focus-visible {
  background: var(--navy);
  color: var(--white);
  outline: none;
}

.nav-btn.active {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--navy-dark);
}

.nav-btn:active { transform: scale(0.98); }

@media (max-width: 480px) {
  .hero-logo-zone {
    padding-bottom: 8rem;
  }

  .logo-img--hero {
    height: min(400px, 62vh);
    max-width: 94vw;
  }

  .site-header {
    min-height: min(88vh, 700px);
  }

  .category-nav {
    bottom: 0.85rem;
  }
}

@media (min-width: 768px) {
  .hero-logo-zone {
    padding-bottom: 10rem;
  }

  .logo-img--hero {
    height: min(560px, 62vh);
    max-width: min(640px, 88vw);
  }
}

@media (min-width: 1200px) {
  .logo-img--hero {
    height: min(620px, 64vh);
    max-width: 680px;
  }
}

/* ── Sections ── */
.section {
  padding: 3rem var(--header-pad);
  max-width: 640px;
  margin: 0 auto;
}

#boats {
  padding-top: 2rem;
}

.section--alt { background: var(--white); max-width: none; }
.section--alt > * { max-width: 640px; margin-left: auto; margin-right: auto; }

.section--contact {
  background: var(--navy-dark);
  color: var(--white);
  max-width: none;
  padding-bottom: 4rem;
}

.section--contact .section-head h2,
.section--contact .section-sub { color: var(--white); }
.section--contact .section-sub { opacity: 0.85; }

.section-head { text-align: center; margin-bottom: 2rem; }

.section-head h2 {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 6vw, 2.5rem);
  font-weight: 700;
  color: var(--navy);
  margin: 0 0 0.35rem;
  letter-spacing: 0.02em;
}

.section-sub {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* ── Boat cards (stacked like primjer.jpeg) ── */
.boat-list {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.boat-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: box-shadow var(--transition), transform var(--transition);
}

.boat-card:hover { box-shadow: var(--shadow-lg); }

.boat-card-image-wrap {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--navy-light);
}

.boat-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.price-badge,
.availability-badge {
  position: absolute;
  padding: 0.35rem 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: 6px;
}

.price-badge {
  top: 0.75rem;
  right: 0.75rem;
  background: rgba(26, 47, 74, 0.88);
  color: var(--white);
}

.availability-badge {
  top: 0.75rem;
  left: 0.75rem;
  background: var(--gold);
  color: var(--navy-dark);
}

.boat-card-body { padding: 1.25rem 1.35rem 1.5rem; }

.boat-name {
  font-family: var(--font-serif);
  font-size: 1.65rem;
  font-weight: 700;
  color: var(--navy);
  margin: 0 0 0.25rem;
}

.badge-inline {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gold-dark);
  vertical-align: middle;
}

.boat-specs {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0 0 0.85rem;
}

.boat-quick-facts {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  font-size: 0.9rem;
  font-weight: 500;
}

.boat-quick-facts .icon { margin-right: 0.2rem; }

.boat-teaser {
  margin: 0 0 1.25rem;
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* Placeholder boat 4 */
.boat-card--placeholder .placeholder-visual {
  width: 100%;
  height: 100%;
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--navy-light) 0%, var(--navy) 100%);
  color: rgba(255, 255, 255, 0.7);
  font-style: italic;
  font-family: var(--font-serif);
  font-size: 1.2rem;
}

/* ── Buttons ── */
.btn {
  display: inline-block;
  width: 100%;
  text-align: center;
  padding: 0.85rem 1.5rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-decoration: none;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transition), color var(--transition), transform 0.2s, opacity var(--transition);
}

.btn-primary {
  background: var(--gold);
  color: var(--navy-dark);
}

.btn-primary:hover:not(:disabled),
.btn-primary:focus-visible {
  background: var(--gold-light);
  outline: 2px solid var(--navy);
  outline-offset: 2px;
}

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-outline {
  background: transparent;
  color: var(--navy);
  border: 2px solid var(--navy);
}

.btn-outline:hover,
.btn-outline:focus-visible {
  background: var(--navy);
  color: var(--white);
}

/* ── Tours ── */
.tour-grid {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.tour-card {
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  text-align: center;
}

.tour-card--featured {
  border-color: var(--gold);
  box-shadow: 0 0 0 1px var(--gold);
}

.tour-icon { font-size: 2rem; margin-bottom: 0.5rem; }

.tour-card h3,
.tour-highlight h3 {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  color: var(--navy);
  margin: 0 0 0.25rem;
}

.tour-duration {
  font-weight: 700;
  color: var(--gold-dark);
  margin: 0 0 0.75rem;
  font-size: 1.05rem;
}

.tour-card .tour-price {
  font-family: var(--font-serif);
  font-size: 1.85rem;
  font-weight: 700;
  color: var(--navy);
  margin: 0 0 0.75rem;
}

.tour-card p:not(.tour-duration):not(.tour-price) { color: var(--text-muted); margin: 0 0 1rem; font-size: 0.95rem; }

.tour-includes {
  list-style: none;
  padding: 0;
  margin: 0 0 1.25rem;
  font-size: 0.9rem;
}

.tour-includes li::before {
  content: '✓ ';
  color: var(--gold);
  font-weight: 700;
}

.tour-highlight {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.tour-highlight-content { padding: 1.5rem; }

.tour-price {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 700;
  color: var(--navy);
  margin: 0 0 0.75rem;
}

.tour-price .per-trip {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
}

.tour-highlight-visual {
  height: 140px;
  flex-shrink: 0;
}

.sunset-gradient {
  background: linear-gradient(135deg, #e8a838 0%, #c45c3a 40%, #4a3f6b 100%);
}

.sunrise-gradient {
  background: linear-gradient(135deg, #f0d890 0%, #e8a050 35%, #6a8fc4 100%);
}

@media (min-width: 600px) {
  .tour-highlight { flex-direction: row; }
  .tour-highlight-visual { width: 200px; height: auto; min-height: 100%; }
}

/* ── Destinations (Explore Istria) ── */
.section--destinations {
  max-width: none;
  background: var(--white);
  padding-bottom: 3.5rem;
}

.section--destinations > * {
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.destinations-tagline {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.15rem !important;
  color: var(--gold-dark) !important;
  letter-spacing: 0.03em;
}

.destinations-intro {
  max-width: 540px;
  margin: 1rem auto 0;
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.65;
}

.destinations-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
  margin-bottom: 2rem;
}

.dest-item {
  margin: 0;
}

.dest-item--wide {
  grid-column: 1 / -1;
}

.dest-image-wrap {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  box-shadow: var(--shadow);
}

.dest-item--wide .dest-image-wrap {
  aspect-ratio: 16 / 9;
}

.dest-image-wrap--tall {
  aspect-ratio: 3 / 4;
}

.dest-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.dest-img--red-island {
  object-position: center 38%;
}

.dest-img--two-sisters {
  object-position: center 45%;
}

.dest-img--banjole {
  object-position: center 50%;
}

.dest-item--wide .dest-img--banjole {
  object-position: center 42%;
}

.dest-item:hover .dest-image-wrap img {
  transform: scale(1.05);
}

.dest-label {
  position: absolute;
  bottom: 0.85rem;
  left: 0.85rem;
  font-family: var(--font-script);
  font-size: clamp(1.35rem, 4vw, 1.85rem);
  font-weight: 600;
  color: var(--white);
  text-shadow:
    0 1px 2px rgba(0, 0, 0, 0.4),
    0 2px 12px rgba(0, 0, 0, 0.35);
  line-height: 1.1;
  pointer-events: none;
}

.dest-label--right {
  left: auto;
  right: 0.85rem;
  text-align: right;
}

.dest-image-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15, 31, 51, 0.45) 0%, transparent 50%);
  pointer-events: none;
}

.dest-item figcaption {
  margin-top: 0.55rem;
  padding: 0 0.15rem;
  font-size: 0.82rem;
  line-height: 1.45;
  color: var(--text-muted);
}

.destinations-cta {
  text-align: center;
  margin: 0;
}

.destinations-cta .btn {
  max-width: 320px;
  margin: 0 auto;
}

@media (min-width: 600px) {
  .destinations-grid {
    gap: 1rem;
  }

  .dest-item figcaption {
    font-size: 0.88rem;
  }
}

/* ── Scroll reveal animations ── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 0.75s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.75s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.12s; }
.reveal-delay-2 { transition-delay: 0.24s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  .reveal,
  .reveal.is-visible {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .hero-bg,
  .site-header:hover .hero-bg,
  .dest-image-wrap img,
  .dest-item:hover .dest-image-wrap img {
    transform: none;
    transition: none;
  }
}

/* ── Contact ── */
.contact-grid {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.contact-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 1.25rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: var(--white);
  transition: background var(--transition), border-color var(--transition), transform 0.2s;
}

.contact-card:hover,
.contact-card:focus-visible {
  background: rgba(255, 255, 255, 0.14);
  border-color: var(--gold);
  outline: none;
  transform: translateY(-2px);
}

.contact-icon { color: var(--gold); }

.contact-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  opacity: 0.8;
}

.contact-value {
  font-weight: 600;
  font-size: 1rem;
  word-break: break-all;
}

.qr-block {
  text-align: center;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.qr-block h3 {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  margin: 0 0 0.5rem;
}

.qr-hint {
  font-size: 0.85rem;
  opacity: 0.75;
  max-width: 420px;
  margin: 0 auto 1rem;
}

.qr-hint code {
  background: rgba(255, 255, 255, 0.1);
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  font-size: 0.8rem;
}

.qr-image {
  margin: 0 auto;
  border-radius: var(--radius);
  background: var(--white);
  padding: 8px;
}

/* ── Footer ── */
.site-footer {
  text-align: center;
  padding: 2rem var(--header-pad);
  background: var(--navy-dark);
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
}

.footer-logo {
  margin: 0 auto 0.75rem;
  opacity: 0.98;
  width: auto;
  height: 72px;
  max-width: 160px;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.2));
}

.back-top {
  display: inline-block;
  margin-top: 0.75rem;
  color: var(--gold);
  text-decoration: none;
  font-weight: 600;
}

.back-top:hover { text-decoration: underline; }

/* ── Modal ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(15, 31, 51, 0.75);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition), visibility var(--transition);
}

.modal-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.modal-overlay[hidden] { display: none; }
.modal-overlay.is-open { display: flex; }

.modal {
  background: var(--white);
  width: 100%;
  max-width: 640px;
  max-height: 92vh;
  overflow-y: auto;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  transform: translateY(100%);
  transition: transform var(--transition);
  position: relative;
}

.modal-overlay.is-open .modal { transform: translateY(0); }

@media (min-width: 600px) {
  .modal-overlay { align-items: center; padding: 1rem; }
  .modal {
    border-radius: var(--radius-lg);
    max-height: 90vh;
    transform: translateY(20px) scale(0.96);
    opacity: 0;
  }
  .modal-overlay.is-open .modal {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

.modal-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 2;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  color: var(--navy);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: background 0.2s;
}

.modal-close:hover { background: var(--gold); }

.modal-gallery {
  position: relative;
  background: var(--navy-dark);
  aspect-ratio: 4 / 3;
}

.modal-main-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: var(--navy);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s;
}

.gallery-btn:hover { background: var(--gold); }
.gallery-prev { left: 0.5rem; }
.gallery-next { right: 0.5rem; }

.gallery-dots {
  position: absolute;
  bottom: 0.75rem;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 0.4rem;
}

.gallery-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  padding: 0;
  background: rgba(255, 255, 255, 0.45);
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}

.gallery-dot.active {
  background: var(--gold);
  transform: scale(1.2);
}

.modal-body { padding: 1.5rem; }

.modal-body h2 {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  color: var(--navy);
  margin: 0 0 0.25rem;
  padding-right: 2rem;
}

.modal-subtitle {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin: 0 0 1rem;
}

.modal-pricing {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.price-chip {
  flex: 1;
  min-width: 120px;
  padding: 0.65rem 1rem;
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
}

.price-chip span {
  display: block;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.price-chip strong {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  color: var(--navy);
}

.modal-description {
  font-size: 0.95rem;
  color: var(--text);
  margin-bottom: 1.5rem;
}

.modal-description h4 {
  font-family: var(--font-serif);
  color: var(--navy);
  margin: 1.25rem 0 0.5rem;
  font-size: 1.15rem;
}

.modal-description ul {
  padding-left: 1.2rem;
  margin: 0.5rem 0;
}

.modal-description li { margin-bottom: 0.35rem; }

.modal-note {
  background: rgba(184, 148, 46, 0.15);
  border-left: 3px solid var(--gold);
  padding: 0.65rem 1rem;
  border-radius: 0 var(--radius) var(--radius) 0;
}

body.modal-open { overflow: hidden; }

/* Wider screens */
@media (min-width: 768px) {
  :root { --header-pad: 2rem; }
  .section { max-width: 720px; }
  .section--alt > * { max-width: 720px; }
  .contact-grid {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
  }
  .contact-card { flex: 1; min-width: 180px; max-width: 220px; }
}
