/* =============================================================================
   DestinationAGo — OSM Business Listing Styles
   Shared by: index.html (form) + confirmation.html (payment confirmed)
============================================================================= */

/* =========================================================
   DESIGN TOKENS — DestinationAGo brand
========================================================= */
:root {
  --blue:        #1E45A8;
  --blue-light:  #2B57D4;
  --blue-pale:   #F0F4FF;
  --jade:        #00A882;
  --jade-light:  #ECFDF5;
  --saffron:     #E6A020;
  --saffron-dark:#C4871A;
  --dark:        #111827;
  --gray-800:    #1F2937;
  --gray-600:    #4B5563;
  --gray-400:    #9CA3AF;
  --gray-200:    #E5E7EB;
  --gray-100:    #F9FAFB;
  --white:       #FFFFFF;
  --error:       #DC2626;
  --error-bg:    #FEF2F2;
  --warn-bg:     #FFFBEB;
  --warn-border: #F59E0B;
  --radius:      10px;
  --shadow:      0 4px 24px rgba(30,69,168,0.10);
}

/* =========================================================
   RESET & BASE
========================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Segoe UI', system-ui, -apple-system, Arial, sans-serif;
  background: var(--blue-pale);
  color: var(--dark);
  min-height: 100vh;
  line-height: 1.6;
}

/* =========================================================
   LAYOUT
========================================================= */
.page-wrap {
  max-width: 680px;
  margin: 0 auto;
  padding: 32px 16px 64px;
}

/* confirmation.html uses narrower max-width */
.page-wrap.narrow {
  max-width: 620px;
}

/* =========================================================
   HEADER
========================================================= */
.site-header {
  background: var(--blue);
  padding: 24px 32px;
  text-align: center;
  border-radius: var(--radius) var(--radius) 0 0;
}

.site-header h1 {
  color: var(--white);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.site-header span {
  color: var(--saffron);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.site-header p {
  color: #93B4F5;
  font-size: 13px;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-top: 6px;
}

.jade-bar {
  height: 4px;
  background: var(--jade);
}

/* =========================================================
   CARD
========================================================= */
.card {
  background: var(--white);
  border-radius: 0 0 var(--radius) var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.card-body {
  padding: 36px 40px 40px;
}

@media (max-width: 520px) {
  .card-body { padding: 24px 20px 32px; }
  .site-header { padding: 20px; }
  .card { padding: 24px 20px; }
}

/* =========================================================
   PROGRESS STEPS
========================================================= */
.steps {
  display: flex;
  align-items: center;
  gap: 0;
  margin-bottom: 36px;
}

.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex: 1;
  position: relative;
}

.step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 16px;
  left: calc(50% + 16px);
  right: calc(-50% + 16px);
  height: 2px;
  background: var(--gray-200);
  z-index: 0;
}

.step.done:not(:last-child)::after,
.step.active:not(:last-child)::after {
  background: var(--blue);
}

.step-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--gray-200);
  color: var(--gray-400);
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
  transition: background 0.2s, color 0.2s;
}

.step.active .step-dot {
  background: var(--blue);
  color: var(--white);
}

.step.done .step-dot {
  background: var(--jade);
  color: var(--white);
}

.step-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--gray-400);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: center;
}

.step.active .step-label { color: var(--blue); }
.step.done .step-label   { color: var(--jade); }

/* =========================================================
   SECTION TITLE
========================================================= */
.section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 6px;
}

.section-sub {
  font-size: 14px;
  color: var(--gray-600);
  margin-bottom: 28px;
  line-height: 1.5;
}

/* =========================================================
   FORM FIELDS
========================================================= */
.field {
  margin-bottom: 20px;
}

.field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-800);
  margin-bottom: 6px;
  letter-spacing: 0.2px;
}

.field label .required {
  color: var(--error);
  margin-left: 2px;
}

.field label .optional {
  color: var(--gray-400);
  font-weight: 400;
  font-size: 12px;
  margin-left: 4px;
}

.field input,
.field select {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--gray-200);
  border-radius: 8px;
  font-size: 15px;
  color: var(--dark);
  background: var(--white);
  transition: border-color 0.15s, box-shadow 0.15s;
  appearance: none;
  -webkit-appearance: none;
}

.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236B7280' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 38px;
  cursor: pointer;
}

.field input:focus,
.field select:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(30,69,168,0.10);
}

.field input.error,
.field select.error {
  border-color: var(--error);
  box-shadow: 0 0 0 3px rgba(220,38,38,0.08);
}

.field input.valid,
.field select.valid {
  border-color: var(--jade);
}

.field-error {
  font-size: 12px;
  color: var(--error);
  margin-top: 5px;
  display: none;
}

#err-attestation {
  margin-top: 6px;
}

.field-warn {
  font-size: 12px;
  color: #92400E;
  background: var(--warn-bg);
  border: 1px solid var(--warn-border);
  border-radius: 6px;
  padding: 8px 10px;
  margin-top: 6px;
  display: none;
}

.field-hint {
  font-size: 12px;
  color: var(--gray-400);
  margin-top: 5px;
}

.select-group {
  font-weight: 700;
  color: var(--dark);
}

/* =========================================================
   ATTESTATION CHECKBOX
========================================================= */
.attestation {
  background: var(--blue-pale);
  border: 1.5px solid var(--gray-200);
  border-radius: 8px;
  padding: 16px 18px;
  margin: 28px 0 8px;
}

.attestation label {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  cursor: pointer;
  font-size: 14px;
  color: var(--gray-800);
  line-height: 1.5;
}

.attestation input[type="checkbox"] {
  width: 18px;
  height: 18px;
  min-width: 18px;
  margin-top: 2px;
  accent-color: var(--blue);
  cursor: pointer;
}

.attestation.error {
  border-color: var(--error);
  background: var(--error-bg);
}

/* =========================================================
   REVIEW SCREEN
========================================================= */
.review-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0 28px;
}

.review-table tr {
  border-bottom: 1px solid var(--gray-200);
}

.review-table tr:last-child {
  border-bottom: none;
}

.review-table td {
  padding: 10px 4px;
  font-size: 14px;
  vertical-align: top;
}

.review-table td:first-child {
  color: var(--gray-600);
  width: 38%;
  font-weight: 500;
}

.review-table td:last-child {
  color: var(--dark);
  font-weight: 600;
  word-break: break-word;
}

.review-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 20px;
}

.review-badge.verified {
  background: var(--jade-light);
  color: #065F46;
}

.review-badge.warning {
  background: var(--warn-bg);
  color: #92400E;
}

.price-box {
  background: var(--dark);
  border-radius: 8px;
  padding: 18px 24px;
  text-align: center;
  margin: 0 0 28px;
}

.price-box .price-label {
  color: #93B4F5;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.price-box .price-amount {
  color: var(--white);
  font-size: 32px;
  font-weight: 700;
  line-height: 1.2;
  margin-top: 4px;
}

.price-box .price-desc {
  color: var(--gray-400);
  font-size: 13px;
  margin-top: 4px;
}

.price-currency {
  font-size: 16px;
  font-weight: 400;
  color: var(--gray-400);
}

/* =========================================================
   CONFIRMATION PAGE
========================================================= */
.confirmation-icon {
  text-align: center;
  margin-bottom: 20px;
}

.confirmation-icon svg {
  width: 64px;
  height: 64px;
}

.confirmation-title {
  text-align: center;
  font-size: 22px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 8px;
}

.confirmation-sub {
  text-align: center;
  font-size: 15px;
  color: var(--gray-600);
  margin-bottom: 28px;
  line-height: 1.6;
}

/* icon-wrap used in confirmation.html */
.icon-wrap {
  text-align: center;
  margin-bottom: 20px;
}

.icon-wrap svg {
  width: 72px;
  height: 72px;
}

/* h2 used in confirmation.html */
h2 {
  text-align: center;
  font-size: 24px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 8px;
}

.sub {
  text-align: center;
  font-size: 15px;
  color: var(--gray-600);
  margin-bottom: 32px;
  line-height: 1.6;
}

/* =========================================================
   INFO BOX
========================================================= */
.info-box {
  background: var(--blue-pale);
  border-left: 4px solid var(--blue);
  border-radius: 0 8px 8px 0;
  padding: 16px 20px;
  margin: 0 0 24px;
}

.info-box p {
  font-size: 14px;
  color: var(--gray-800);
  line-height: 1.6;
}

.info-box strong {
  color: var(--blue);
}

.info-box a {
  color: var(--blue);
  text-decoration: none;
  font-weight: 600;
}

/* =========================================================
   NEXT STEPS LIST
========================================================= */
.next-steps {
  background: var(--jade);
  border-radius: 8px;
  padding: 20px 24px;
  margin: 0 0 28px;
}

.next-steps p,
.next-steps .label {
  color: var(--saffron);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
}

.next-steps ul {
  padding-left: 20px;
  color: #D1D5DB;
  font-size: 14px;
  line-height: 2.0;
}

.next-steps ul strong {
  color: var(--white);
}

/* =========================================================
   BUTTONS
========================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 700;
  padding: 13px 28px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s, transform 0.1s;
  letter-spacing: 0.2px;
}

.btn:active { transform: scale(0.98); }

.btn-primary {
  background: var(--saffron);
  color: var(--dark);
  width: 100%;
}

.btn-primary:hover { background: var(--saffron-dark); }

.btn-primary:disabled {
  background: var(--gray-200);
  color: var(--gray-400);
  cursor: not-allowed;
  transform: none;
}

.btn-secondary {
  background: transparent;
  color: var(--blue);
  border: 1.5px solid var(--blue);
  width: 100%;
  margin-top: 12px;
}

.btn-secondary:hover { background: var(--blue-pale); }

.btn-pay {
  background: var(--blue);
  color: var(--white);
  width: 100%;
}

.btn-pay:hover { background: var(--blue-light); }

.btn-spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: none;
}

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

/* =========================================================
   SCREENS — show/hide
========================================================= */
.screen { display: none; }
.screen.active { display: block; }

/* =========================================================
   VALIDATION STATUS INDICATOR
========================================================= */
.validating-msg {
  text-align: center;
  color: var(--gray-600);
  font-size: 14px;
  padding: 16px 0;
  display: none;
}

.validating-msg .dot-pulse {
  display: inline-block;
  animation: pulse 1.2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.3; }
}

/* =========================================================
   FOOTER
========================================================= */
.page-footer,
.footer-note {
  text-align: center;
  margin-top: 24px;
  color: var(--gray-400);
  font-size: 12px;
  line-height: 1.8;
}

.page-footer a,
.footer-note a {
  color: var(--blue);
  text-decoration: none;
}

.page-footer-links {
  margin-top: 8px;
}

/* =========================================================
   DIVIDER
========================================================= */
.divider {
  height: 1px;
  background: var(--gray-200);
  margin: 28px 0;
}

/* =========================================================
   VALIDATION LOADING SCREEN
========================================================= */
#screen-validating .validating-wrap {
  text-align: center;
  padding: 40px 0 20px;
}

#screen-validating .validating-wrap .spinner-lg {
  width: 48px;
  height: 48px;
  border: 4px solid var(--gray-200);
  border-top-color: var(--blue);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 20px;
}

#screen-validating .validating-wrap p {
  color: var(--gray-600);
  font-size: 15px;
}

/* =========================================================
   APP DOWNLOAD NOTE — confirmation.html
========================================================= */
.app-download-note {
  text-align: center;
  font-size: 14px;
  color: var(--gray-600);
  padding: 16px 20px;
  margin: 0 0 24px;
}

.app-download-note a {
  color: var(--blue);
  font-weight: 600;
  text-decoration: none;
}
