/* ═══════════════════════════════════════════════════════════════
   HANDS Logistics — Shared Brand Styles
   Used by: admin.html, proposal.html, index.html
═══════════════════════════════════════════════════════════════ */

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

:root {
  --white: #ffffff;
  --off-white: #f8f7f4;
  --light-grey: #efefed;
  --mid-grey: #c8c8c4;
  --text-grey: #7a7a76;
  --dark: #111110;
  --green: #a0d6b4;
  --green-dark: #6dba96;
  --red: #c94a4a;
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'DM Sans', sans-serif;
  --font-mono: 'DM Mono', monospace;
}

html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--off-white);
  color: var(--dark);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── NAV ───────────────────────────────────────────────── */
nav {
  position: sticky; top: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 48px; height: 72px;
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--light-grey);
}
.nav-brand { display: flex; align-items: center; gap: 16px; }
.nav-brand img { height: 44px; width: auto; display: block; }
.nav-brand .divider { width: 1px; height: 24px; background: var(--light-grey); }
.nav-brand .sub {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--text-grey);
}
.nav-actions { display: flex; gap: 40px; align-items: center; }
.nav-link {
  font-family: var(--font-body); font-size: 13px; font-weight: 400;
  letter-spacing: 0.06em; text-transform: uppercase; color: var(--dark);
  text-decoration: none; position: relative; cursor: pointer;
  background: transparent; border: none; padding: 0;
  transition: color 0.2s;
}
.nav-link::after {
  content: ''; position: absolute; bottom: -3px; left: 0;
  width: 0; height: 1px; background: var(--green-dark);
  transition: width 0.3s ease;
}
.nav-link:hover { color: var(--green-dark); }
.nav-link:hover::after { width: 100%; }
.nav-cta {
  background: var(--dark); color: var(--white);
  padding: 10px 24px; border-radius: 2px; border: none;
  font-family: var(--font-body); font-size: 13px; font-weight: 500;
  letter-spacing: 0.06em; text-transform: uppercase;
  cursor: pointer; transition: background 0.2s;
  text-decoration: none; display: inline-block;
}
.nav-cta:hover { background: var(--green-dark); }

/* ── BUTTONS ───────────────────────────────────────────── */
.btn-primary {
  background: var(--dark); color: var(--white);
  padding: 16px 36px; border-radius: 2px; border: none;
  font-family: var(--font-body); font-size: 13px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
  text-decoration: none; cursor: pointer;
  transition: background 0.2s, transform 0.2s;
  display: inline-flex; align-items: center; gap: 8px;
}
.btn-primary:hover:not(:disabled) { background: var(--green-dark); transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.6; cursor: wait; }

.btn-secondary {
  background: transparent; color: var(--dark);
  padding: 16px 36px; border-radius: 2px;
  border: 1px solid var(--mid-grey);
  font-family: var(--font-body); font-size: 13px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
  cursor: pointer; transition: all 0.2s;
  display: inline-flex; align-items: center; gap: 8px;
}
.btn-secondary:hover { background: var(--dark); color: var(--white); border-color: var(--dark); }

.btn-ghost {
  color: var(--dark); background: transparent; border: none;
  font-family: var(--font-body); font-size: 13px; font-weight: 400;
  letter-spacing: 0.06em; text-transform: uppercase;
  display: inline-flex; align-items: center; gap: 8px;
  cursor: pointer; padding: 0;
  transition: color 0.2s;
}
.btn-ghost:hover { color: var(--green-dark); }
.btn-ghost::after { content: '\2192'; transition: transform 0.2s; }
.btn-ghost:hover::after { transform: translateX(4px); }

/* ── HERO ──────────────────────────────────────────────── */
.hero {
  background: var(--dark); color: var(--white);
  padding: 120px 80px 80px;
  position: relative; overflow: hidden;
}
.hero::before {
  content:''; position:absolute; inset:0;
  background:
    radial-gradient(ellipse at 20% 30%, rgba(109,186,150,0.15) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 70%, rgba(160,214,180,0.08) 0%, transparent 55%);
  pointer-events: none;
}
.hero-inner { position: relative; z-index: 1; max-width: 1400px; margin: 0 auto; }
.hero-eyebrow {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--green); margin-bottom: 20px;
}
.hero-headline {
  font-family: var(--font-display);
  font-size: clamp(52px, 6vw, 88px); font-weight: 300; line-height: 1.05;
  letter-spacing: -0.01em; margin-bottom: 28px; max-width: 900px;
  color: var(--white);
}
.hero-headline em { font-style: italic; color: var(--green-dark); }
.hero-body {
  font-size: 17px; font-weight: 300;
  color: rgba(255,255,255,0.7); line-height: 1.75;
  max-width: 640px;
}

/* ── MARQUEE ───────────────────────────────────────────── */
.marquee-strip { background: var(--green); padding: 18px 0; overflow: hidden; white-space: nowrap; }
.marquee-inner { display: inline-flex; animation: marquee 22s linear infinite; }
.marquee-item {
  font-family: var(--font-display); font-size: 18px; font-weight: 300;
  font-style: italic; letter-spacing: 0.04em; color: var(--dark);
  padding: 0 48px;
}
.marquee-dot {
  display: inline-block; width: 4px; height: 4px; border-radius: 50%;
  background: var(--dark); opacity: 0.4; vertical-align: middle;
}
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ── MAIN LAYOUT ───────────────────────────────────────── */
main {
  max-width: 1400px; margin: 0 auto;
  padding: 96px 80px;
}

.section-eyebrow {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--green-dark); margin-bottom: 12px;
}
.section-title {
  font-family: var(--font-display); font-size: 32px; font-weight: 400;
  line-height: 1.15; margin-bottom: 8px;
}
.section-sub {
  font-size: 14px; font-weight: 300; color: var(--text-grey);
  margin-bottom: 28px;
}

/* ── CARDS ─────────────────────────────────────────────── */
.card {
  background: var(--white);
  padding: 28px;
  box-shadow: 0 2px 20px rgba(0,0,0,0.12);
  margin-bottom: 32px;
}
.card-dark {
  background: var(--dark); color: var(--white);
  padding: 44px 32px;
  position: relative; overflow: hidden;
  margin-bottom: 32px;
}
.card-dark::before {
  content:''; position:absolute; inset:0;
  background:
    radial-gradient(ellipse at 85% 20%, rgba(160,214,180,0.12) 0%, transparent 55%),
    radial-gradient(ellipse at 15% 100%, rgba(109,186,150,0.08) 0%, transparent 50%);
  pointer-events: none;
}
.card-dark > * { position: relative; z-index: 1; }
.card-dark .section-eyebrow { color: var(--green); }
.card-dark .section-title { color: var(--white); }
.card-dark .section-title em { font-style: italic; color: var(--green); }

/* ── FORM FIELDS ───────────────────────────────────────── */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.field label {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.15em;
  text-transform: uppercase; color: var(--text-grey);
}
.field input, .field textarea, .field select {
  font-family: var(--font-body); font-size: 14px; color: var(--dark);
  background: var(--off-white); border: 1px solid var(--light-grey);
  padding: 12px 14px; border-radius: 2px; outline: none;
  transition: border-color 0.2s, background 0.2s;
}
.field input:focus, .field textarea:focus, .field select:focus {
  border-color: var(--green-dark); background: var(--white);
}
.field textarea { resize: vertical; min-height: 80px; font-family: var(--font-body); }
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* ── FOOTER ────────────────────────────────────────────── */
footer {
  background: var(--dark); color: rgba(255,255,255,0.55);
  padding: 72px 80px 40px;
}
.footer-inner {
  max-width: 1400px; margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 24px;
}
.footer-brand { display: flex; align-items: center; gap: 14px; }
.footer-brand img { height: 48px; width: auto; filter: brightness(0) invert(1); }
.footer-meta {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.15em;
  text-transform: uppercase; color: rgba(255,255,255,0.3);
}

/* ── TOAST ─────────────────────────────────────────────── */
.toast {
  position: fixed; bottom: 32px; left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--dark); color: var(--white);
  padding: 14px 24px;
  font-family: var(--font-mono); font-size: 12px;
  letter-spacing: 0.1em; text-transform: uppercase;
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);
  opacity: 0; transition: opacity 0.3s, transform 0.3s;
  z-index: 1100; border-left: 2px solid var(--green);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.error { border-left-color: var(--red); }

/* ── MODAL ─────────────────────────────────────────────── */
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(17,17,16,0.72);
  backdrop-filter: blur(6px);
  display: none; align-items: center; justify-content: center;
  z-index: 1000; padding: 24px;
}
.modal-backdrop.open { display: flex; }
.modal {
  background: var(--white); max-width: 640px; width: 100%;
  max-height: 90vh; overflow-y: auto;
  box-shadow: 0 24px 64px rgba(0,0,0,0.3);
}
.modal-head {
  padding: 24px 28px; border-bottom: 1px solid var(--light-grey);
  display: flex; align-items: center; justify-content: space-between;
}
.modal-head h3 { font-family: var(--font-display); font-size: 24px; font-weight: 400; }
.modal-close {
  background: transparent; border: none; cursor: pointer;
  font-size: 24px; color: var(--text-grey); padding: 4px 10px;
}
.modal-close:hover { color: var(--dark); }
.modal-body { padding: 24px 28px; }
.modal-actions {
  display: flex; gap: 12px; justify-content: flex-end;
  padding: 20px 28px; border-top: 1px solid var(--light-grey);
  background: var(--off-white);
}

/* ── RESPONSIVE ────────────────────────────────────────── */
@media (max-width: 1024px) {
  nav, main, .hero, footer { padding-left: 40px; padding-right: 40px; }
  .hero { padding: 96px 40px 64px; }
  main { padding: 64px 40px; }
  .hero-headline { font-size: clamp(42px, 6vw, 64px); }
}
@media (max-width: 640px) {
  nav, main, .hero, footer { padding-left: 24px; padding-right: 24px; }
  .hero { padding: 80px 24px 48px; }
  main { padding: 48px 24px; }
  .nav-actions { gap: 16px; }
  .nav-link { display: none; }
  .nav-brand .sub { display: none; }
  .field-grid { grid-template-columns: 1fr; }
}

@media print {
  nav, .marquee-strip, .modal-backdrop, .admin-only, footer { display: none !important; }
  body { background: white; }
  .card, .card-dark { box-shadow: none; page-break-inside: avoid; }
}

/* ═══════════════════════════════════════════════════════════════
   RECAP-SPECIFIC STYLES
═══════════════════════════════════════════════════════════════ */

/* Recap hero (vs proposal hero — uses photo backdrop instead of gradient) */
.recap-hero {
  position: relative;
  min-height: 480px;
  display: flex; align-items: flex-end;
  padding: 80px 80px 64px;
  color: var(--white);
  background: var(--dark);
  overflow: hidden;
}
.recap-hero-bg {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  opacity: 0.55;
  z-index: 0;
}
.recap-hero::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(17,17,16,0.35) 0%, rgba(17,17,16,0.85) 100%);
  z-index: 1;
}
.recap-hero-inner { position: relative; z-index: 2; max-width: 1400px; width: 100%; margin: 0 auto; }
.recap-hero-eyebrow {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--green); margin-bottom: 18px;
}
.recap-hero-headline {
  font-family: var(--font-display);
  font-size: clamp(48px, 6vw, 80px); font-weight: 300; line-height: 1.05;
  letter-spacing: -0.01em; margin-bottom: 16px; max-width: 900px;
}
.recap-hero-headline em { font-style: italic; color: var(--green-dark); }
.recap-hero-meta {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.18em;
  text-transform: uppercase; color: rgba(255,255,255,0.7);
}

/* Metrics strip */
.metrics-strip {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0; background: var(--dark); color: var(--white);
}
.metric-cell {
  padding: 36px 28px; text-align: center;
  border-right: 1px solid rgba(255,255,255,0.08);
}
.metric-cell:last-child { border-right: none; }
.metric-value {
  font-family: var(--font-display);
  font-size: 48px; font-weight: 300; line-height: 1;
  color: var(--green); margin-bottom: 8px;
}
.metric-label {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.2em;
  text-transform: uppercase; color: rgba(255,255,255,0.55);
}
@media (max-width: 720px) {
  .metric-cell { border-right: none; border-bottom: 1px solid rgba(255,255,255,0.08); }
  .metric-cell:last-child { border-bottom: none; }
  .metric-value { font-size: 36px; }
}

/* Photo gallery — masonry-ish grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 4px;
}
.gallery-tile {
  aspect-ratio: 4 / 3;
  position: relative; overflow: hidden;
  background: var(--off-white); cursor: pointer;
}
.gallery-tile img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.4s ease;
}
.gallery-tile:hover img { transform: scale(1.04); }
.gallery-tile-caption {
  position: absolute; bottom: 0; left: 0; right: 0;
  padding: 14px 18px;
  background: linear-gradient(180deg, transparent 0%, rgba(17,17,16,0.85) 100%);
  color: var(--white);
  font-size: 12px; line-height: 1.4;
  opacity: 0; transition: opacity 0.2s;
}
.gallery-tile:hover .gallery-tile-caption { opacity: 1; }
.gallery-tile-caption:empty { display: none; }

/* Deck card (PDF embed) */
.deck-card {
  background: var(--white);
  box-shadow: 0 2px 20px rgba(0,0,0,0.12);
  margin-bottom: 32px;
}
.deck-card-head {
  padding: 20px 28px;
  border-bottom: 1px solid var(--light-grey);
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 12px;
}
.deck-card-title { font-family: var(--font-display); font-size: 22px; font-weight: 400; }
.deck-frame {
  width: 100%;
  min-height: 720px;
  /* For slide decks (typically 16:9), the iframe height needs to scale with width */
  aspect-ratio: 16 / 9;
  border: none;
  background: var(--off-white);
  display: block;
}
@media (min-width: 1100px) {
  .deck-frame { min-height: 820px; }
}

/* Delivered checklist */
.delivered-list { list-style: none; padding: 0; margin: 0; }
.delivered-list li {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--light-grey);
}
.delivered-list li:last-child { border-bottom: none; }
.delivered-check {
  flex: 0 0 auto;
  width: 22px; height: 22px;
  border-radius: 50%; background: var(--green);
  color: var(--dark);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 600;
  margin-top: 2px;
}
.delivered-text { flex: 1; }
.delivered-title { font-weight: 500; color: var(--dark); margin-bottom: 2px; }
.delivered-detail { font-size: 13px; color: var(--text-grey); }

/* Lightbox (shared between proposal slides and recap gallery) */
.lightbox-overlay {
  position: fixed; inset: 0;
  background: rgba(17,17,16,0.92);
  display: none; align-items: center; justify-content: center;
  z-index: 1200; padding: 32px;
  cursor: zoom-out;
}
.lightbox-overlay.open { display: flex; }
.lightbox-image {
  max-width: 100%; max-height: 80vh;
  object-fit: contain;
  box-shadow: 0 24px 64px rgba(0,0,0,0.5);
}
.lightbox-caption {
  position: absolute; bottom: 32px; left: 50%;
  transform: translateX(-50%);
  color: var(--white); font-size: 13px;
  font-family: var(--font-mono); letter-spacing: 0.1em;
  text-transform: uppercase;
  background: rgba(0,0,0,0.6);
  padding: 8px 16px;
  max-width: 80vw;
  text-align: center;
}

/* Recap status pill (for admin list) */
.recap-pill {
  display: inline-block;
  font-family: var(--font-mono); font-size: 9px;
  letter-spacing: 0.15em; text-transform: uppercase;
  padding: 3px 8px; border-radius: 2px;
  margin-left: 8px;
}
.recap-pill.draft { background: var(--light-grey); color: var(--text-grey); }
.recap-pill.live  { background: var(--green); color: var(--dark); }

@media (max-width: 1024px) {
  .recap-hero { padding: 64px 40px 48px; min-height: 380px; }
}
@media (max-width: 640px) {
  .recap-hero { padding: 48px 24px 32px; min-height: 320px; }
}

@media print {
  .recap-hero-bg { opacity: 0.3; }
  .gallery-tile { break-inside: avoid; }
  .deck-frame { display: none !important; }
}

/* ── Custom HTML Embed (recap) ─────────────────────────────
   Optional per-recap module rendered in a sandboxed iframe.
   Full width of the recap-inner column, auto-resized by JS. */
.custom-embed-section { padding-top: 48px; padding-bottom: 48px; }
.custom-embed-frame {
  display: block;
  width: 100%;
  min-height: 600px;
  border: 0;
  background: transparent;
  color-scheme: light;
  transition: height 0.25s ease;
}
@media (max-width: 640px) {
  .custom-embed-frame { min-height: 480px; }
}

/* ── Full-bleed embed (recap.embedUrl) ─────────────────────
   Renders a same-origin page (e.g. a deck) filling the viewport
   under the sticky 72px nav. Height is set inline by JS. */
.fullbleed-embed-frame {
  display: block;
  width: 100%;
  border: 0;
  background: #0d0d0d;
}
