/* ==========================================================================
   Ondus Boracay — Voucher Landing Page
   ========================================================================== */

:root {
  /* Palette */
  --cream: #faf6ef;
  --cream-deep: #f2ebdf;
  --white: #ffffff;
  --navy: #14213d;
  --navy-soft: #26365a;
  --gold: #b8975a;
  --gold-light: #d9c297;
  --ink: #2b2f38;
  --muted: #6b6f78;
  --line: #e4dccd;
  --error: #a4402f;
  --success: #3f6b4f;

  /* Type */
  --font-serif: "Cormorant Garamond", "Times New Roman", serif;
  --font-sans: "Jost", "Helvetica Neue", Arial, sans-serif;

  /* Layout */
  --container: 1200px;
  --gutter: 24px;
  --radius: 2px;
  --shadow: 0 30px 60px -30px rgba(20, 33, 61, 0.35);
}

/* ---------- Base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.eyebrow {
  margin: 0 0 16px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
}

.eyebrow-center {
  text-align: center;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(250, 246, 239, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--navy);
}

.brand-logo {
  width: auto;
  height: 60px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.brand-name {
  font-family: var(--font-serif);
  font-size: 26px;
  font-weight: 500;
  letter-spacing: 0.32em;
}

.brand-sub {
  margin-top: 6px;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.5em;
  color: var(--gold);
}

.header-nav a {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--navy);
  padding-bottom: 4px;
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s ease;
}

.header-nav a:hover,
.header-nav a:focus-visible {
  border-color: var(--gold);
}

/* ---------- Voucher section ---------- */
.voucher-section {
  padding: 72px 0 96px;
}

.voucher-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 80px;
  align-items: center;
}

/* Hero visual */
.hero-visual {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 45%;
}

/* Thin gold inset frame */
.hero-visual::after {
  content: "";
  position: absolute;
  inset: 16px;
  border: 1px solid rgba(217, 194, 151, 0.55);
  pointer-events: none;
}

/* Claim panel */
.claim-panel {
  max-width: 460px;
}

.claim-heading,
.section-heading {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 400;
  color: var(--navy);
  line-height: 1.05;
}

.claim-heading {
  font-size: clamp(40px, 5vw, 60px);
}

.claim-copy {
  margin: 24px 0 40px;
  font-size: 17px;
  color: var(--muted);
}

/* Form */
.claim-form {
  display: flex;
  flex-direction: column;
}

.field-label {
  margin-bottom: 10px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--navy);
}

.field-input {
  width: 100%;
  height: 56px;
  padding: 0 18px;
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 400;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.field-input::placeholder {
  color: #a9a59c;
}

.field-input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(184, 151, 90, 0.18);
}

.field-input[aria-invalid="true"] {
  border-color: var(--error);
}

.form-message {
  min-height: 24px;
  margin: 8px 0 12px;
  font-size: 14px;
  font-weight: 400;
}

.form-message.is-error {
  color: var(--error);
}

.form-message.is-success {
  color: var(--success);
}

.btn-primary {
  position: relative;
  height: 56px;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--white);
  background: var(--navy);
  border: 1px solid var(--navy);
  border-radius: var(--radius);
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.btn-primary:hover {
  background: var(--navy-soft);
  border-color: var(--gold);
}

.btn-primary:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.btn-primary:disabled {
  cursor: wait;
  opacity: 0.8;
}

.btn-primary.is-loading .btn-label {
  visibility: hidden;
}

.btn-primary.is-loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 18px;
  margin: -9px 0 0 -9px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: var(--gold-light);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.privacy-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 24px 0 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
}

.privacy-note img {
  flex-shrink: 0;
  margin-top: 4px;
}

/* ---------- Verified voucher ---------- */
.claim-heading:focus {
  outline: none;
}

.discount-display {
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.discount-value {
  font-family: var(--font-serif);
  font-size: clamp(56px, 7vw, 76px);
  font-weight: 400;
  line-height: 1;
  color: var(--gold);
}

.discount-label {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--navy);
}

.voucher-details {
  margin: 0 0 32px;
}

.detail-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.detail-row dt {
  flex-shrink: 0;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold);
}

.detail-row dd {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 20px;
  line-height: 1.35;
  color: var(--navy);
  text-align: right;
  word-break: break-word;
}

.detail-row .detail-code {
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.16em;
}

.btn-block {
  width: 100%;
}

.btn-block:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

/* ---------- Contact section ---------- */
.contact-section {
  padding: 96px 0;
  background: var(--cream-deep);
  border-top: 1px solid var(--line);
  text-align: center;
}

.section-heading {
  font-size: clamp(34px, 4vw, 46px);
}

.section-copy {
  max-width: 520px;
  margin: 20px auto 56px;
  color: var(--muted);
}

.contact-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  max-width: 900px;
  margin: 0 auto;
  padding: 0;
  list-style: none;
}

.contact-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 8px 24px;
}

.contact-item + .contact-item {
  border-left: 1px solid var(--line);
}

.contact-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
}

.contact-value {
  font-family: var(--font-serif);
  font-size: 21px;
  color: var(--navy);
  text-decoration: none;
  word-break: break-word;
}

a.contact-value:hover,
a.contact-value:focus-visible {
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-underline-offset: 4px;
}

/* ---------- Footer ---------- */
.site-footer {
  padding: 56px 0 40px;
  background: var(--navy);
  color: rgba(255, 255, 255, 0.7);
  text-align: center;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.footer-brand {
  align-items: center;
  color: var(--white);
}

.footer-brand .brand-sub {
  color: var(--gold-light);
}

.footer-address {
  margin: 24px 0 8px;
  font-size: 14px;
}

.footer-copy {
  margin: 0;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.5);
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .voucher-grid {
    grid-template-columns: 1fr;
    gap: 56px;
  }

  .hero-visual {
    aspect-ratio: 16 / 11;
  }

  .claim-panel {
    max-width: 560px;
    margin: 0 auto;
    text-align: center;
  }

  .claim-form {
    text-align: left;
  }

  .privacy-note {
    justify-content: center;
    text-align: left;
  }

  .discount-display {
    justify-content: center;
  }
}

@media (max-width: 640px) {
  :root {
    --gutter: 16px;
  }

  .header-inner {
    height: 68px;
  }

  .brand-logo {
    height: 50px;
  }

  .brand-name {
    font-size: 22px;
  }

  .header-nav a {
    font-size: 11px;
    letter-spacing: 0.14em;
  }

  .voucher-section {
    padding: 0 0 64px;
  }

  /* Full-bleed visual on phones */
  .voucher-grid {
    padding: 0;
    gap: 40px;
  }

  .hero-visual {
    aspect-ratio: 4 / 4.2;
    box-shadow: none;
  }

  .claim-panel {
    padding: 0 var(--gutter);
  }

  .claim-copy {
    font-size: 16px;
    margin: 20px 0 32px;
  }

  .contact-section {
    padding: 72px 0;
  }

  .contact-list {
    grid-template-columns: 1fr;
  }

  .contact-item {
    padding: 20px 0;
  }

  .contact-item + .contact-item {
    border-left: 0;
    border-top: 1px solid var(--line);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition: none !important;
    animation-duration: 1.5s !important;
  }
}
