/* =============================================
   Nach Deutschland Pathways — Booking Form
   Elegant Gold & Navy Theme
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@500;700&family=DM+Sans:wght@300;400;500&display=swap');

:root {
    --navy:    #1a1a2e;
    --navy-2:  #16213e;
    --gold:    #d4a843;
    --gold-lt: #e8c06a;
    --cream:   #f9f6f1;
    --gray:    #6b7280;
    --light:   #f3ede4;
    --white:   #ffffff;
    --error:   #e53e3e;
    --success: #2d7d46;
    --radius:  10px;
    --shadow:  0 8px 40px rgba(26, 26, 46, 0.14);
}

/* ---- Wrapper ---- */
#tpb-wrapper {
    font-family: 'DM Sans', sans-serif;
    max-width: 680px;
    margin: 0 auto;
    padding: 20px 16px 40px;
}

/* ---- Alerts ---- */
.tpb-alert {
    padding: 14px 20px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    font-size: 15px;
    font-weight: 500;
}
.tpb-alert-success {
    background: #eaf7ee;
    color: var(--success);
    border: 1px solid #a8dbb7;
}
.tpb-alert-error {
    background: #fff5f5;
    color: var(--error);
    border: 1px solid #feb2b2;
}

/* ---- Card ---- */
.tpb-card {
    background: var(--white);
    border-radius: 16px;
    box-shadow: var(--shadow);
    overflow: hidden;
    border: 1px solid #ede7db;
}

/* ---- Header ---- */
.tpb-header {
    background: var(--navy);
    padding: 40px 40px 32px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.tpb-header::before {
    content: '';
    position: absolute;
    top: -60px; right: -60px;
    width: 200px; height: 200px;
    border-radius: 50%;
    background: rgba(212, 168, 67, 0.08);
}
.tpb-header::after {
    content: '';
    position: absolute;
    bottom: -40px; left: -40px;
    width: 140px; height: 140px;
    border-radius: 50%;
    background: rgba(212, 168, 67, 0.06);
}

.tpb-logo-mark {
    display: inline-block;
    background: var(--gold);
    color: var(--navy);
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 18px;
    letter-spacing: 3px;
    padding: 8px 18px;
    border-radius: 6px;
    margin-bottom: 16px;
}

.tpb-header h2 {
    font-family: 'Playfair Display', serif;
    color: var(--white);
    font-size: 28px;
    font-weight: 700;
    margin: 0 0 8px;
    letter-spacing: 0.5px;
}

.tpb-header p {
    color: rgba(255,255,255,0.55);
    font-size: 14px;
    margin: 0;
    letter-spacing: 0.5px;
}

/* ---- Info Strip ---- */
.tpb-info-strip {
    display: flex;
    justify-content: center;
    gap: 0;
    background: var(--navy-2);
    border-bottom: 2px solid var(--gold);
}

.tpb-info-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    color: rgba(255,255,255,0.75);
    font-size: 13px;
    font-weight: 400;
    border-right: 1px solid rgba(255,255,255,0.08);
    flex: 1;
    justify-content: center;
}
.tpb-info-item:last-child {
    border-right: none;
}
.tpb-icon {
    font-size: 16px;
}

/* ---- Form Body ---- */
#tpb-form {
    padding: 36px 40px 28px;
}

/* ---- Field Group ---- */
.tpb-field-group {
    margin-bottom: 20px;
}

.tpb-field-group label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--navy);
    margin-bottom: 8px;
}

/* ---- Input Wrap ---- */
.tpb-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.tpb-input-icon {
    position: absolute;
    left: 14px;
    font-size: 16px;
    pointer-events: none;
    z-index: 1;
    line-height: 1;
}

.tpb-input-wrap input,
.tpb-input-wrap select {
    width: 100%;
    padding: 13px 16px 13px 44px;
    font-family: 'DM Sans', sans-serif;
    font-size: 15px;
    color: var(--navy);
    background: var(--cream);
    border: 1.5px solid #e5ddd0;
    border-radius: var(--radius);
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
    box-sizing: border-box;
    -webkit-appearance: none;
    appearance: none;
}

.tpb-input-wrap input::placeholder {
    color: #bbb;
    font-weight: 300;
}

.tpb-input-wrap input:focus,
.tpb-input-wrap select:focus {
    border-color: var(--gold);
    background: var(--white);
    box-shadow: 0 0 0 3px rgba(212, 168, 67, 0.12);
}

/* ---- Select arrow ---- */
.tpb-select-wrap .tpb-select-arrow {
    position: absolute;
    right: 16px;
    color: var(--gold);
    font-size: 18px;
    pointer-events: none;
}

/* ---- Two-column row ---- */
.tpb-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* ---- Hint ---- */
.tpb-hint {
    display: block;
    margin-top: 6px;
    font-size: 11.5px;
    color: var(--gray);
}

/* ---- Availability bar ---- */
.tpb-availability {
    background: var(--cream);
    border: 1.5px solid #e5ddd0;
    border-radius: var(--radius);
    padding: 14px 18px;
    margin-bottom: 20px;
    font-size: 14px;
    color: var(--navy);
}
.tpb-avail-bar-wrap {
    background: #e5ddd0;
    border-radius: 20px;
    height: 6px;
    margin-top: 8px;
    overflow: hidden;
}
.tpb-avail-bar {
    height: 100%;
    border-radius: 20px;
    background: linear-gradient(90deg, var(--gold), var(--gold-lt));
    transition: width 0.5s ease;
}
.tpb-avail-error {
    color: var(--error);
    font-weight: 500;
}

/* ---- Submit Button ---- */
#tpb-submit-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px 24px;
    background: var(--navy);
    color: var(--white);
    border: none;
    border-radius: var(--radius);
    font-family: 'DM Sans', sans-serif;
    font-size: 16px;
    font-weight: 500;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
    position: relative;
    overflow: hidden;
    margin-top: 4px;
}

#tpb-submit-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent 60%, rgba(212,168,67,0.15));
    pointer-events: none;
}

#tpb-submit-btn:hover {
    background: #0f0f20;
    box-shadow: 0 6px 24px rgba(26,26,46,0.22);
    transform: translateY(-1px);
}

#tpb-submit-btn:active {
    transform: translateY(0);
}

.tpb-btn-arrow {
    font-size: 20px;
    transition: transform 0.2s;
}
#tpb-submit-btn:hover .tpb-btn-arrow {
    transform: translateX(4px);
}

#tpb-submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* ---- Secure note ---- */
.tpb-secure-note {
    text-align: center;
    font-size: 12px;
    color: var(--gray);
    padding: 0 40px 28px;
    margin: 0;
}

/* ---- Response message ---- */
#tpb-response {
    margin-top: 16px;
    font-size: 14px;
    text-align: center;
    color: var(--error);
    font-weight: 500;
    min-height: 20px;
}

/* ---- Responsive ---- */
@media (max-width: 600px) {
    .tpb-header {
        padding: 32px 24px 24px;
    }
    #tpb-form {
        padding: 28px 24px 20px;
    }
    .tpb-row {
        grid-template-columns: 1fr;
    }
    .tpb-info-strip {
        flex-direction: column;
    }
    .tpb-info-item {
        border-right: none;
        border-bottom: 1px solid rgba(255,255,255,0.08);
        justify-content: flex-start;
        padding: 12px 24px;
    }
    .tpb-secure-note {
        padding: 0 24px 20px;
    }
    .tpb-header h2 {
        font-size: 22px;
    }
}

/* =============================================
   Availability Panel — Slot Display
   ============================================= */

.tpb-availability {
    background: var(--cream);
    border: 1.5px solid #e5ddd0;
    border-radius: var(--radius);
    padding: 16px 18px;
    margin-bottom: 20px;
    font-size: 14px;
    color: var(--navy);
}

.tpb-avail-loading {
    margin: 0;
    color: var(--gray);
    font-style: italic;
}

.tpb-avail-error {
    margin: 0;
    color: var(--error);
    font-weight: 500;
}

.tpb-avail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.tpb-avail-title {
    font-weight: 500;
    color: var(--navy);
    font-size: 13px;
}

.tpb-avail-mins {
    font-size: 12px;
    color: var(--gray);
    background: #ede7db;
    padding: 3px 10px;
    border-radius: 20px;
}

.tpb-avail-bar-wrap {
    background: #e5ddd0;
    border-radius: 20px;
    height: 6px;
    margin-bottom: 14px;
    overflow: hidden;
}

.tpb-avail-bar {
    height: 100%;
    border-radius: 20px;
    background: linear-gradient(90deg, var(--gold), var(--gold-lt));
    transition: width 0.5s ease;
}

/* ---- Slot chips ---- */
.tpb-slots-taken,
.tpb-next-slot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.tpb-slots-label {
    font-size: 11.5px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--gray);
    white-space: nowrap;
}

.tpb-slot-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
}

.tpb-slot-taken {
    background: #fff0f0;
    color: #c53030;
    border: 1px solid #feb2b2;
}

.tpb-slot-open {
    background: #f0fff4;
    color: #276749;
    border: 1px solid #9ae6b4;
}

.tpb-fit-ok {
    font-size: 12px;
    color: #276749;
    font-weight: 500;
}

.tpb-fit-no {
    font-size: 12px;
    color: var(--error);
    font-weight: 500;
}

.tpb-full-msg {
    font-size: 13px;
    color: var(--error);
    font-weight: 500;
    margin-top: 4px;
}
