/* ============================================================
   Al Uhud Travels – Booking Form Widget Styles
   ============================================================ */

/* ── Wrapper ── */
.autbf-wrap {
    max-width: 860px;
    margin: 0 auto;
    border: 1.5px solid #e8e8e8;
    border-radius: 14px;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    box-shadow: 0 4px 32px rgba(0,0,0,.08);
    background: #fff;
}

/* ── Utility ── */
.autbf-hidden { display: none !important; }

/* ── Header ── */
.autbf-header {
    background: #1B5E3B;
    padding: 32px 36px 28px;
    text-align: center;
}
.autbf-title {
    color: #C9A84C;
    font-size: clamp(22px, 3vw, 30px);
    font-weight: 800;
    margin: 0 0 8px;
    line-height: 1.2;
}
.autbf-subtitle {
    color: #d4e8d8;
    font-size: 14px;
    margin: 0;
    line-height: 1.55;
}

/* ── Step Indicator ── */
.autbf-stepper {
    display: flex;
    align-items: center;
    padding: 22px 24px 0;
    overflow-x: auto;
    scrollbar-width: none;
}
.autbf-stepper::-webkit-scrollbar { display: none; }

.autbf-step-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}
.autbf-step-dot {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #e0e0e0;
    border: 2.5px solid #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
    color: #999;
    transition: background .3s, border-color .3s, color .3s;
    position: relative;
}
.autbf-step-dot .autbf-dot-check { display: none; }
.autbf-step-dot .autbf-dot-num   { display: block; }
.autbf-step-dot.active {
    background: #1B5E3B;
    border-color: #1B5E3B;
    color: #fff;
}
.autbf-step-dot.done {
    background: #1B5E3B;
    border-color: #1B5E3B;
    color: #fff;
}
.autbf-step-dot.done .autbf-dot-check { display: block; }
.autbf-step-dot.done .autbf-dot-num   { display: none; }

.autbf-step-label {
    font-size: 10px;
    color: #aaa;
    text-align: center;
    white-space: nowrap;
    font-weight: 500;
    max-width: 68px;
    overflow: hidden;
    text-overflow: ellipsis;
}
.autbf-step-label.active { color: #1B5E3B; font-weight: 700; }

.autbf-step-line {
    flex: 1;
    height: 2px;
    background: #e0e0e0;
    margin: 0 4px;
    margin-bottom: 22px; /* offset from label */
    transition: background .3s;
}
.autbf-step-line.done { background: #1B5E3B; }

/* Progress bar */
.autbf-progress-bar {
    height: 3px;
    background: #e8e8e8;
    margin: 14px 24px 0;
    border-radius: 2px;
    overflow: hidden;
}
.autbf-progress-bar-inner {
    height: 100%;
    background: #1B5E3B;
    border-radius: 2px;
    transition: width .4s ease;
}

/* ── Form Body ── */
.autbf-form {
    padding: 28px 36px 24px;
}
.autbf-step-heading {
    font-size: 18px;
    font-weight: 700;
    color: #1B5E3B;
    margin: 0 0 6px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f7f3;
}
.autbf-step-note {
    font-size: 13px;
    color: #777;
    margin: 0 0 20px;
}

/* ── Fields ── */
.autbf-field-group {
    margin-bottom: 18px;
}
.autbf-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
.autbf-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
}
.autbf-req { color: #e74c3c; margin-left: 2px; }

.autbf-input,
.autbf-select,
.autbf-textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 14px;
    border: 1.5px solid #d8d8d8;
    border-radius: 7px;
    font-size: 14px;
    color: #333;
    background: #fff;
    transition: border-color .2s, box-shadow .2s;
    outline: none;
    appearance: none;
}
.autbf-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='7' viewBox='0 0 12 7'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23888' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}
.autbf-input:focus,
.autbf-select:focus,
.autbf-textarea:focus {
    border-color: #1B5E3B;
    box-shadow: 0 0 0 3px rgba(27,94,59,.12);
}
.autbf-input.autbf-invalid,
.autbf-select.autbf-invalid,
.autbf-textarea.autbf-invalid {
    border-color: #e74c3c;
    box-shadow: 0 0 0 3px rgba(231,76,60,.1);
}
.autbf-textarea { resize: vertical; min-height: 90px; }
.autbf-field-hint {
    font-size: 11px;
    color: #999;
    margin: 4px 0 0;
}

/* ── Radio / Checkbox ── */
.autbf-radio-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}
.autbf-radio-label,
.autbf-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    padding: 10px 16px;
    border: 1.5px solid #e0e0e0;
    border-radius: 7px;
    transition: border-color .2s, background .2s;
}
.autbf-radio-label:hover,
.autbf-checkbox-label:hover { border-color: #1B5E3B; background: #f0f7f3; }
.autbf-radio-label input[type="radio"]:checked ~ *,
.autbf-checkbox-label input[type="checkbox"]:checked ~ * { color: #1B5E3B; }
.autbf-checkbox { accent-color: #1B5E3B; width: 16px; height: 16px; }

/* ── Package Cards ── */
.autbf-pkg-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 14px;
    margin-top: 8px;
}
.autbf-pkg-card {
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 16px;
    cursor: pointer;
    position: relative;
    transition: border-color .25s, background .25s, transform .2s;
    background: #fff;
}
.autbf-pkg-card:hover {
    border-color: #1B5E3B;
    background: #f9fdf9;
    transform: translateY(-2px);
}
.autbf-pkg-card.selected {
    border-color: #1B5E3B;
    background: #f0f7f3;
}
.autbf-pkg-badge {
    position: absolute;
    top: -1px; right: 10px;
    background: #e67e22;
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.5px;
    padding: 3px 8px;
    border-radius: 0 0 6px 6px;
    text-transform: uppercase;
}
.autbf-pkg-card-name {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 8px 0 6px;
}
.autbf-pkg-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}
.autbf-pkg-nights {
    font-size: 12px;
    color: #777;
}
.autbf-pkg-price {
    font-size: 14px;
    font-weight: 800;
    color: #1B5E3B;
}
.autbf-pkg-highlights {
    list-style: none;
    padding: 0;
    margin: 0 0 10px;
}
.autbf-pkg-highlights li {
    font-size: 11px;
    color: #555;
    padding: 1px 0;
}
.autbf-pkg-select-indicator {
    font-size: 11px;
    font-weight: 700;
    color: #1B5E3B;
    text-align: center;
    padding: 4px;
    border-radius: 4px;
    background: #d4edd8;
    display: none;
}
.autbf-pkg-card.selected .autbf-pkg-select-indicator { display: block; }

/* ── Traveller Counters ── */
.autbf-counter-row {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}
.autbf-counter-item {
    flex: 1 1 140px;
    border: 1.5px solid #e0e0e0;
    border-radius: 8px;
    padding: 14px 12px;
    text-align: center;
}
.autbf-counter-label {
    font-size: 13px;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
    line-height: 1.3;
}
.autbf-counter-label small { font-weight: 400; color: #888; }
.autbf-counter-ctrl {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
}
.autbf-cnt-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1.5px solid #1B5E3B;
    background: #fff;
    color: #1B5E3B;
    font-size: 18px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition: background .2s, color .2s;
    display: flex;
    align-items: center;
    justify-content: center;
}
.autbf-cnt-btn:hover { background: #1B5E3B; color: #fff; }
.autbf-cnt-val {
    font-size: 20px;
    font-weight: 800;
    color: #1a1a1a;
    min-width: 24px;
    text-align: center;
}

/* ── Info Box ── */
.autbf-info-box {
    background: #f0f7f3;
    border-left: 4px solid #1B5E3B;
    border-radius: 6px;
    padding: 12px 16px;
    font-size: 13px;
    color: #2c6b3e;
    margin-bottom: 18px;
    line-height: 1.5;
}

/* ── Summary Card ── */
.autbf-summary-card {
    background: #f8f8f5;
    border: 1.5px solid #e8e8e8;
    border-radius: 10px;
    padding: 18px 20px;
    margin: 20px 0;
}
.autbf-summary-title {
    font-size: 15px;
    font-weight: 700;
    color: #1B5E3B;
    margin: 0 0 14px;
}
.autbf-summary-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.autbf-sum-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.autbf-sum-k {
    font-size: 11px;
    font-weight: 600;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.autbf-sum-v {
    font-size: 14px;
    color: #1a1a1a;
    font-weight: 500;
}

/* ── Navigation ── */
.autbf-nav-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid #f0f0f0;
    gap: 12px;
}
.autbf-nav-right { display: flex; gap: 12px; margin-left: auto; }

.autbf-btn {
    padding: 12px 28px;
    border-radius: 7px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: opacity .2s, transform .15s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.autbf-btn:hover { opacity: .88; transform: translateY(-1px); }
.autbf-btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }

.autbf-btn-primary  { background: #1B5E3B; color: #fff; }
.autbf-btn-secondary { background: #f0f0f0; color: #555; }
.autbf-btn-submit {
    background: #C9A84C;
    color: #1a1a1a;
    font-size: 16px;
    padding: 14px 32px;
}

/* ── Messages ── */
.autbf-error-msg {
    background: #fdf0f0;
    border: 1px solid #f5c6c6;
    border-radius: 7px;
    color: #c0392b;
    font-size: 13px;
    padding: 10px 16px;
    margin-top: 16px;
}
.autbf-terms-note {
    font-size: 12px;
    color: #aaa;
    margin: 12px 0 0;
    line-height: 1.5;
}
.autbf-terms-note a { color: #1B5E3B; }

/* ── Loading ── */
.autbf-loading {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #555;
    font-size: 14px;
    padding: 14px 0;
}
.autbf-spinner {
    width: 22px;
    height: 22px;
    border: 3px solid #e0e0e0;
    border-top-color: #1B5E3B;
    border-radius: 50%;
    animation: autbf-spin .7s linear infinite;
    flex-shrink: 0;
}
@keyframes autbf-spin { to { transform: rotate(360deg); } }

/* ── Success Screen ── */
.autbf-success {
    padding: 60px 36px;
    text-align: center;
}
.autbf-success-icon {
    font-size: 56px;
    margin-bottom: 16px;
}
.autbf-success-heading {
    font-size: 28px;
    font-weight: 800;
    color: #1B5E3B;
    margin: 0 0 12px;
}
.autbf-success-msg {
    font-size: 16px;
    color: #555;
    line-height: 1.65;
    max-width: 520px;
    margin: 0 auto 14px;
}
.autbf-success-ref {
    font-size: 14px;
    color: #888;
}
.autbf-success-ref strong {
    color: #1B5E3B;
    font-size: 18px;
}

/* ── Mahram / Visa transitions ── */
.autbf-mahram-section,
.autbf-visa-type-section {
    animation: autbf-fadein .3s ease;
}
@keyframes autbf-fadein {
    from { opacity:0; transform:translateY(-6px); }
    to   { opacity:1; transform:translateY(0); }
}

/* ── Admin ── */
.autbf-status { padding: 3px 10px; border-radius: 20px; font-size: 12px; font-weight: 600; }
.autbf-status-new       { background:#d4edda; color:#155724; }
.autbf-status-contacted { background:#fff3cd; color:#856404; }
.autbf-status-confirmed { background:#cce5ff; color:#004085; }

/* ── Responsive ── */
@media (max-width: 640px) {
    .autbf-form          { padding: 20px 18px 18px; }
    .autbf-header        { padding: 24px 18px 20px; }
    .autbf-field-row     { grid-template-columns: 1fr; }
    .autbf-pkg-grid      { grid-template-columns: 1fr; }
    .autbf-counter-row   { gap: 10px; }
    .autbf-summary-grid  { grid-template-columns: 1fr; }
    .autbf-stepper       { padding: 16px 12px 0; }
    .autbf-step-label    { display: none; }
    .autbf-nav-row       { flex-wrap: wrap; }
    .autbf-btn-submit    { width: 100%; justify-content: center; }
}
