/* ================================================================
   Oldbidder Cost Calculator — v1.1
   Full-width section · All dropdowns via Select2 · Dark navy theme
================================================================ */

@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;1,9..40,300&family=DM+Mono:wght@400;500&display=swap');

/* ── Reset & Variables ────────────────────────────────────── */
.ewob-block {
  --gold:       #b8922a;
  --gold-light: #d4a843;
  --gold-pale:  rgba(184,146,42,0.12);
  --gold-rim:   rgba(184,146,42,0.30);
  --navy:       #1b2a4a;
  --navy-dark:  #131e33;
  --navy-mid:   #1f3254;
  --white:      #ffffff;
  --white-70:   rgba(255,255,255,0.70);
  --white-45:   rgba(255,255,255,0.45);
  --white-20:   rgba(255,255,255,0.20);
  --white-10:   rgba(255,255,255,0.10);
  --white-06:   rgba(255,255,255,0.06);
  --white-03:   rgba(255,255,255,0.03);
  --divider:    rgba(255,255,255,0.07);
  --red:        rgba(192,57,43,0.85);
  font-family: 'DM Sans', system-ui, sans-serif;
  box-sizing: border-box;
}

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

/* ── Outer: full-width section ────────────────────────────── */
.ewob-block {
  width: 100%;
}

.ewob-calculator {
  width: 100%;
  background: var(--navy);
  position: relative;
}

/* watermark removed to prevent overflow clipping */

/* ── Header ───────────────────────────────────────────────── */
.ewob-calc-header {
  padding: 64px 80px 44px;
  border-bottom: 1px solid var(--divider);
}

.ewob-label {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.ewob-label-line {
  width: 32px;
  height: 2px;
  background: var(--gold);
  flex-shrink: 0;
}
.ewob-label span {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gold-light);
}

.ewob-calc-heading {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(42px, 5vw, 68px);
  letter-spacing: 2px;
  line-height: 1.0;
  color: var(--white);
}

/* ── Form wrapper ─────────────────────────────────────────── */
.ewob-form-wrap {
  padding: 40px 80px 48px;
  display: flex;
  flex-direction: column;
  gap: 28px;
  border-bottom: 1px solid var(--divider);
  background: rgba(0,0,0,0.12);
}

/* Grid rows */
.ewob-form-row   { display: grid; gap: 24px; align-items: end; }
.ewob-row-3      { grid-template-columns: 1fr 1.8fr 1fr; }
.ewob-row-2      { grid-template-columns: 1fr 1fr; }

/* Field */
.ewob-field      { display: flex; flex-direction: column; gap: 9px; }

.ewob-field label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--white-45);
  user-select: none;
}

/* ── Hide native selects — Select2 renders everything ─────── */
.ewob-calculator select {
  display: none !important;
}

/* ================================================================
   SELECT2 — full dark theme override
================================================================ */

/* Container */
.ewob-block .select2-container {
  width: 100% !important;
}

/* ── Closed state ─────────────────────────────────────────── */
.ewob-block .select2-container--default .select2-selection--single {
  height: 48px;
  background: var(--navy-mid);
  border: 1px solid var(--white-20);
  border-radius: 0;
  display: flex;
  align-items: center;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
  cursor: pointer;
}

/* Text inside closed */
.ewob-block .select2-container--default .select2-selection--single .select2-selection__rendered {
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  color: var(--white);
  line-height: 46px;
  padding-left: 16px;
  padding-right: 40px;
}

/* Placeholder colour */
.ewob-block .select2-container--default .select2-selection--single .select2-selection__placeholder {
  color: var(--white-45);
}

/* Arrow */
.ewob-block .select2-container--default .select2-selection--single .select2-selection__arrow {
  height: 46px;
  width: 36px;
  right: 4px;
  top: 0;
}
.ewob-block .select2-container--default .select2-selection--single .select2-selection__arrow b {
  border-color: var(--white-45) transparent transparent transparent;
  border-width: 5px 4px 0 4px;
  margin-top: -2px;
}

/* Clear button */
.ewob-block .select2-container--default .select2-selection--single .select2-selection__clear {
  color: var(--white-45);
  font-size: 16px;
  font-weight: 300;
  margin-right: 24px;
  float: right;
  line-height: 46px;
}
.ewob-block .select2-container--default .select2-selection--single .select2-selection__clear:hover {
  color: var(--white);
}

/* ── Focus / open state ───────────────────────────────────── */
.ewob-block .select2-container--default.select2-container--focus .select2-selection--single,
.ewob-block .select2-container--default.select2-container--open  .select2-selection--single {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-pale);
  outline: none;
}

.ewob-block .select2-container--default.select2-container--open .select2-selection--single .select2-selection__arrow b {
  border-color: transparent transparent var(--gold-light) transparent;
  border-width: 0 4px 5px 4px;
}

/* ── Disabled state ───────────────────────────────────────── */
.ewob-block .select2-container--default.select2-container--disabled .select2-selection--single {
  background: rgba(255,255,255,0.03);
  border-color: rgba(255,255,255,0.08);
  cursor: not-allowed;
}
.ewob-block .select2-container--default.select2-container--disabled .select2-selection__rendered {
  color: var(--white-20) !important;
}
.ewob-block .select2-container--default.select2-container--disabled .select2-selection__arrow b {
  border-top-color: var(--white-20);
}

/* ── Dropdown panel ───────────────────────────────────────── */
.ewob-block + .select2-container--default .select2-dropdown,
.select2-container--default .select2-dropdown {
  background: #1a2d50;
  border: 1px solid var(--gold);
  border-radius: 0;
  box-shadow: 0 16px 40px rgba(0,0,0,0.6);
  z-index: 99999;
}

/* Search box inside dropdown */
.select2-container--default .select2-search--dropdown {
  padding: 8px 8px 6px;
  background: var(--navy-dark);
  border-bottom: 1px solid var(--divider);
}
.select2-container--default .select2-search--dropdown .select2-search__field {
  background: var(--navy-mid);
  border: 1px solid var(--white-20);
  border-radius: 0;
  color: var(--white);
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  padding: 8px 12px;
  width: 100%;
  outline: none;
}
.select2-container--default .select2-search--dropdown .select2-search__field:focus {
  border-color: var(--gold);
}
.select2-container--default .select2-search--dropdown .select2-search__field::placeholder {
  color: var(--white-45);
}

/* Results list */
.select2-container--default .select2-results {
  background: #1a2d50;
}
.select2-container--default .select2-results__options {
  max-height: 280px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--gold-rim) transparent;
}
.select2-container--default .select2-results__options::-webkit-scrollbar {
  width: 4px;
}
.select2-container--default .select2-results__options::-webkit-scrollbar-thumb {
  background: var(--gold-rim);
  border-radius: 2px;
}

/* Result option */
.select2-container--default .select2-results__option {
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  color: var(--white-70);
  padding: 10px 16px;
  cursor: pointer;
  transition: background 0.1s, color 0.1s;
}
.select2-container--default .select2-results__option--highlighted[aria-selected],
.select2-container--default .select2-results__option--highlighted[data-selected] {
  background: var(--gold) !important;
  color: #fff !important;
}
.select2-container--default .select2-results__option[aria-selected=true] {
  background: var(--gold-pale);
  color: var(--gold-light);
}
.select2-container--default .select2-results__option--disabled {
  color: var(--white-20);
  cursor: default;
}

/* ── Spinner ──────────────────────────────────────────────── */
.ewob-spinner {
  display: flex;
  justify-content: center;
  padding: 36px 80px;
}
.ewob-spinner__track {
  width: 40px;
  height: 40px;
  border: 2px solid var(--white-10);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: ewob-spin 0.7s linear infinite;
}
@keyframes ewob-spin { to { transform: rotate(360deg); } }

/* ── Result panel ─────────────────────────────────────────── */
.ewob-result {
  animation: ewob-fadein 0.3s ease;
  border-top: 1px solid var(--divider);
}
@keyframes ewob-fadein {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.ewob-result__header {
  padding: 32px 80px 20px;
}
.ewob-label--gold .ewob-label-line { background: var(--gold); }
.ewob-label--gold span             { color: var(--gold-light); }

/* Tags */
.ewob-result__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.ewob-tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--white-45);
  background: var(--white-06);
  border: 1px solid var(--white-10);
}
.ewob-tag--dest  { background: var(--gold-pale);  border-color: var(--gold-rim);  color: var(--gold-light); }
.ewob-tag--cargo { background: rgba(44,95,168,0.15); border-color: rgba(44,95,168,0.35); color: #7aacf0; }

/* Cost rows */
.ewob-cost-list {
  padding: 0 80px;
}
.ewob-cost-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
  border-bottom: 1px solid var(--divider);
}
.ewob-cost-row:last-child { border-bottom: none; }

.ewob-cost-label { font-size: 14px; color: var(--white-45); font-weight: 300; }
.ewob-cost-val   { font-family: 'DM Mono', monospace; font-size: 15px; color: var(--white-70); letter-spacing: 0.5px; }

/* Subtotal */
.ewob-cost-row--sub .ewob-cost-label { color: var(--white-70); font-weight: 500; }
.ewob-cost-row--sub .ewob-cost-val   { color: var(--white); }

/* Fee row */
.ewob-cost-row--fee .ewob-cost-label { color: rgba(212,168,67,0.65); }
.ewob-cost-val--fee                  { color: var(--gold-light); }

/* Grand total */
.ewob-grand-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 80px;
  background: var(--gold-pale);
  border-top: 1px solid var(--gold-rim);
  border-bottom: 1px solid var(--gold-rim);
}
.ewob-grand-label {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 22px;
  letter-spacing: 2px;
  color: var(--white-70);
}
.ewob-grand-val {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 44px;
  letter-spacing: 2px;
  line-height: 1;
  color: var(--gold-light);
}

/* Disclaimer */
.ewob-disclaimer {
  padding: 14px 80px;
  font-size: 11px;
  color: var(--white-20);
  font-weight: 300;
  letter-spacing: 0.3px;
  transition: none;
}
.ewob-disclaimer[style*="display: none"],
.ewob-disclaimer[style*="display:none"] {
  padding: 0 !important;
  margin: 0 !important;
  height: 0 !important;
  overflow: hidden !important;
}

/* ── Error ────────────────────────────────────────────────── */
.ewob-error {
  margin: 0 80px 28px;
  padding: 14px 20px;
  background: rgba(192,57,43,0.1);
  border-left: 3px solid var(--red);
  color: #e88880;
  font-size: 14px;
  font-weight: 300;
}

/* ── Notice (no data) ─────────────────────────────────────── */
.ewob-notice {
  padding: 16px 20px;
  background: var(--gold-pale);
  border-left: 3px solid var(--gold);
  color: var(--gold-light);
  font-size: 14px;
}

/* ── Tablet ───────────────────────────────────────────────── */
@media (max-width: 900px) {
  .ewob-calc-header,
  .ewob-form-wrap        { padding-left: 40px; padding-right: 40px; }
  .ewob-row-3            { grid-template-columns: 1fr 1fr; }
  .ewob-field--city      { grid-column: 1 / -1; }
  .ewob-result__header,
  .ewob-cost-list,
  .ewob-grand-total,
  .ewob-disclaimer,
  .ewob-spinner,
  .ewob-error            { padding-left: 40px; padding-right: 40px; }
}

/* ── Mobile ───────────────────────────────────────────────── */
@media (max-width: 600px) {
  .ewob-calc-header      { padding: 40px 24px 32px; }
  .ewob-form-wrap        { padding: 28px 24px 36px; gap: 20px; }
  .ewob-row-3,
  .ewob-row-2            { grid-template-columns: 1fr; }
  .ewob-field--city      { grid-column: auto; }
  .ewob-result__header,
  .ewob-cost-list,
  .ewob-grand-total,
  .ewob-disclaimer,
  .ewob-spinner,
  .ewob-error            { padding-left: 24px; padding-right: 24px; }
  .ewob-grand-val        { font-size: 34px; }
}


/* ── Guest notice (CTA hero) ─────────────────────────────── */
.ewob-guest-notice {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    margin: 0;
    padding: 44px 60px 48px;
    background: linear-gradient(160deg, rgba(201,168,76,0.22) 0%, rgba(201,168,76,0.06) 60%, rgba(26,26,46,0.4) 100%);
    border-top: 2px solid rgba(201,168,76,0.5);
    text-align: center;
    position: relative;
    overflow: hidden;
}
.ewob-guest-notice::before {
    content: '';
    position: absolute;
    top: -60px;
    right: -60px;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(201,168,76,0.12) 0%, transparent 70%);
    pointer-events: none;
}
.ewob-guest-notice::after {
    content: '';
    position: absolute;
    bottom: -40px;
    left: -40px;
    width: 160px;
    height: 160px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(201,168,76,0.08) 0%, transparent 70%);
    pointer-events: none;
}
.ewob-guest-notice-badge {
    display: inline-block;
    padding: 4px 14px;
    background: rgba(201,168,76,0.15);
    border: 1px solid rgba(201,168,76,0.45);
    border-radius: 2px;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 11px;
    letter-spacing: 3px;
    color: var(--gold-light);
    text-transform: uppercase;
}
.ewob-guest-notice-headline {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 28px;
    letter-spacing: 1.5px;
    color: #fff;
    line-height: 1.2;
    max-width: 420px;
}
.ewob-guest-notice-sub {
    font-size: 13px;
    color: rgba(255,255,255,0.55);
    font-weight: 300;
    letter-spacing: 0.3px;
    margin-top: -4px;
}
.ewob-guest-notice-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 8px;
    padding: 16px 44px;
    background: linear-gradient(135deg, #c9a84c 0%, #e8c96e 50%, #c9a84c 100%);
    background-size: 200% auto;
    color: #0e0e1c !important;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 20px;
    letter-spacing: 3px;
    text-decoration: none !important;
    border: none;
    border-radius: 3px;
    transition: background-position 0.4s ease, transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 6px 28px rgba(201,168,76,0.45), 0 2px 8px rgba(0,0,0,0.3);
    text-transform: uppercase;
    position: relative;
    z-index: 1;
}
.ewob-guest-notice-arrow {
    font-size: 18px;
    line-height: 1;
    transition: transform 0.2s ease;
}
.ewob-guest-notice-link:hover {
    background-position: right center;
    transform: translateY(-2px);
    box-shadow: 0 10px 36px rgba(201,168,76,0.6), 0 4px 12px rgba(0,0,0,0.3);
    color: #0e0e1c !important;
}
.ewob-guest-notice-link:hover .ewob-guest-notice-arrow {
    transform: translateX(4px);
}
@media (max-width: 600px) {
    .ewob-guest-notice {
        padding: 36px 24px 40px;
    }
    .ewob-guest-notice-headline {
        font-size: 22px;
    }
    .ewob-guest-notice-link {
        font-size: 17px;
        padding: 14px 32px;
        width: 100%;
        justify-content: center;
    }
}
