/* ── Fonts ───────────────────────────────────────────────────────────────── */
@font-face {
  font-family: 'Carlito';
  src: url('/fonts/Carlito-Regular.ttf') format('truetype');
  font-weight: 400;
}
@font-face {
  font-family: 'Carlito';
  src: url('/fonts/Carlito-Bold.ttf') format('truetype');
  font-weight: 700;
}
/* ── Tokens ──────────────────────────────────────────────────────────────── */
:root {
  --navy:         #050d50;
  --blue:         #004489;
  --accent:       #3399CC;
  --cyan:         #66CCFF;
  --orange:       #F7AA14;
  --text:         #323E48;
  --bg:           #f4f6f8;
  --white:        #ffffff;
  --border:       #e0e0e0;
  --shadow:       0 2px 10px rgba(0,0,0,0.08);
  --shadow-hover: 0 8px 24px rgba(0,0,0,0.13);
  --radius:       6px;
}
/* ── Reset ───────────────────────────────────────────────────────────────── */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: 'Carlito', 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  font-size: 16px;
}
/* ── Card ────────────────────────────────────────────────────────────────── */
.card {
  background: var(--white);
  border-radius: var(--radius);
  border-top: 4px solid var(--accent);
  padding: 48px 40px;
  max-width: 480px;
  width: 100%;
  text-align: center;
  box-shadow: var(--shadow);
}
/* ── Buttons ─────────────────────────────────────────────────────────────── */
.btn {
  display: inline-block;
  background: var(--orange);
  color: var(--navy);
  font-family: 'Carlito', sans-serif;
  font-weight: 700;
  font-size: 15px;
  padding: 12px 28px;
  border-radius: 4px;
  text-decoration: none;
  cursor: pointer;
  border: 2px solid var(--orange);
  transition: background 0.2s, border-color 0.2s;
}
.btn:hover { background: #e69b00; border-color: #e69b00; }
.logout-btn {
  background: transparent;
  border: 2px solid var(--blue);
  color: var(--blue);
  font-family: 'Carlito', sans-serif;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 16px;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s;
}
.logout-btn:hover { background: rgba(0,68,137,0.08); }
/* ── Footers ─────────────────────────────────────────────────────────────── */
.footer {
  margin-top: 24px;
  font-size: 12px;
  color: #9aaab8;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  max-width: 480px;
  width: 100%;
}
.footer img { width: 28px; height: 28px; border-radius: var(--radius); -o-object-fit: cover; object-fit: cover; }
.app-footer {
  width: 100%;
  background: var(--navy);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  border-radius: 8px;
  margin-top: 40px;
  font-size: 12px;
  color: rgba(255,255,255,0.5);
}
.app-footer a { color: rgba(255,255,255,0.5); text-decoration: underline; }
.app-footer-logo { display: flex; align-items: center; gap: 8px; }
.app-footer-logo img { height: 18px; opacity: 0.6; }
/* ── App nav ─────────────────────────────────────────────────────────────── */
.app-nav {
  width: 100%;
  background: var(--navy);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px;
  height: 48px;
  margin-bottom: 24px;
  border-radius: 8px;
}
.app-nav-brand {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
}
.app-nav-links { display: flex; gap: 4px; align-items: center; }
.app-nav-links a,
.app-nav-links button {
  font-family: 'Carlito', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px 12px;
  border-radius: 4px;
  transition: background 0.15s, color 0.15s;
}
.app-nav-links a:hover,
.app-nav-links button:hover {
  background: rgba(255,255,255,0.12);
  color: #fff;
}
.app-nav-links a.active { color: #fff; background: rgba(255,255,255,0.15); }
.app-nav-welcome { font-size: 13px; color: rgba(255,255,255,0.5); }
.app-nav-hamburger {
  display: none;
  background: none;
  border: none;
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
}
@media (max-width: 460px) {
  .app-nav {
    flex-wrap: wrap;
    height: auto;
    padding: 10px 16px;
    gap: 0;
  }
  .app-nav-brand { padding: 2px 0; }
  .app-nav-hamburger { display: block; }
  .app-nav-links {
    display: none;
    flex-direction: column;
    width: 100%;
    padding: 6px 0 4px;
    gap: 0;
  }
  .app-nav-links.open { display: flex; }
  .app-nav-links a,
  .app-nav-links button {
    padding: 8px 4px;
    text-align: left;
    border-radius: 0;
    border-bottom: 1px solid rgba(255,255,255,0.07);
  }
  .app-nav-links a:last-child,
  .app-nav-links button:last-child { border-bottom: none; }
  .app-nav-welcome { padding: 8px 4px; border-bottom: 1px solid rgba(255,255,255,0.07); }
}
/* ── Modal ───────────────────────────────────────────────────────────────── */
.overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(5,13,80,0.5);
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 100;
}
.overlay.open { display: flex; }
.modal {
  background: var(--white);
  border-radius: var(--radius);
  border-top: 4px solid var(--accent);
  padding: 36px 32px;
  max-width: 400px;
  width: 100%;
  box-shadow: 0 8px 32px rgba(5,13,80,0.18);
  position: relative;
}
.modal-close {
  position: absolute;
  top: 16px;
  right: 20px;
  background: none;
  border: none;
  font-size: 20px;
  color: #9aaab8;
  cursor: pointer;
}
.modal-close:hover { color: var(--navy); }
.modal h2 { font-size: 20px; font-weight: 700; margin-bottom: 20px; text-align: center; }
.modal-title { font-size: 20px; font-weight: 700; color: var(--navy); margin-bottom: 20px; text-align: center; }
/* ── Form ────────────────────────────────────────────────────────────────── */
.form { display: flex; flex-direction: column; gap: 12px; }
.form input,
.form select {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 11px 14px;
  font-size: 15px;
  font-family: 'Carlito', sans-serif;
  color: var(--text);
  background: #fafafa;
  outline: none;
  transition: border-color 0.2s;
}
.form input:focus,
.form select:focus { border-color: var(--accent); }
.form select { background: #fafafa; }
.form .btn { width: 100%; text-align: center; margin-top: 4px; }
.form-error { font-size: 13px; color: #cc3333; text-align: center; min-height: 18px; }
/* ── Trips page shell ────────────────────────────────────────────────────── */
#trips-page { width: 100%; max-width: 480px; }
.trips-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 24px;
}
.trips-header h2 { font-size: 22px; font-weight: 700; color: var(--navy); }
/* ── Trip card ───────────────────────────────────────────────────────────── */
.trip-card {
  background: var(--white);
  border-radius: var(--radius);
  border-top: 4px solid var(--accent);
  padding: 18px 20px;
  margin-bottom: 12px;
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s;
}
.trip-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }
.trip-card .trip-name { font-weight: 700; font-size: 16px; color: var(--navy); margin-bottom: 4px; }
.trip-card .trip-meta { font-size: 12px; color: #9aaab8; }
/* ── Cookie banner ───────────────────────────────────────────────────────── */
#cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--navy);
  color: rgba(255,255,255,0.85);
  padding: 14px 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
  z-index: 9999;
  box-shadow: 0 -2px 12px rgba(5,13,80,0.3);
}
#cookie-banner a { color: var(--accent); text-decoration: underline; }
.cookie-banner-btn {
  background: var(--orange);
  color: var(--navy);
  font-family: 'Carlito', sans-serif;
  font-size: 13px;
  font-weight: 700;
  padding: 8px 22px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  flex-shrink: 0;
  white-space: nowrap;
}
.cookie-banner-btn:hover { background: #e69b00; }
/* ── Responsive: full-width layout on larger screens ─────────────────────── */
@media (min-width: 480px) {
  body {
    display: block;
    padding: 0;
  }

  /* Card pages (privacy, cookie-policy) stay centered */
  .card {
    margin: 48px auto;
  }

  /* Policy page simple footer stays centred */
  .footer {
    max-width: none;
    margin: 24px auto;
    padding: 0 32px;
    justify-content: center;
  }

  /* App pages expand to full width, capped at 1080px */
  #trips-page {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 32px 40px;
  }

  /* Nav goes edge-to-edge and sticks to the top */
  .app-nav {
    border-radius: 0;
    margin-bottom: 24px;
    position: sticky;
    top: 0;
    z-index: 50;
  }

  /* Footer goes edge-to-edge */
  .app-footer {
    border-radius: 0;
    margin-top: 40px;
  }
}
/* ── Auth card content ───────────────────────────────────────────────────── */
.logo { font-size: 48px; margin-bottom: 16px; }
h1 { font-size: 32px; font-weight: 700; color: var(--navy); margin-bottom: 8px; }
.tagline { font-size: 15px; color: var(--accent); letter-spacing: 0.02em; margin-bottom: 36px; }
.features {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 36px;
  flex-wrap: wrap;
}
.feature { font-size: 13px; color: var(--text); display: flex; flex-direction: column; align-items: center; gap: 6px; }
.feature span { font-size: 28px; }
/* ── Register form extras ────────────────────────────────────────────────── */
.register-only { display: none; }
.captcha { display: flex; align-items: center; gap: 10px; }
.captcha label { font-size: 14px; color: var(--text); white-space: nowrap; }
.captcha input { flex: 1; }
.switch-link { text-align: center; font-size: 13px; color: #9aaab8; margin-top: 4px; }
.switch-link a { color: var(--accent); cursor: pointer; text-decoration: none; font-weight: 600; }
.switch-link a:hover { color: var(--blue); }
