/**
 * Front-end Stylesheet: WPC 2026 Extension Booking Form
 */

.wpc-booking-wrapper {
    box-sizing: border-box;
    max-width: 820px;
    margin: 24px auto;
    padding: 0 16px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    color: #1a3344;
}

.wpc-booking-wrapper *,
.wpc-booking-wrapper *::before,
.wpc-booking-wrapper *::after {
    box-sizing: border-box;
}

/* Card Container */
.wpc-booking-card {
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #d8e2e9;
    box-shadow: 0 8px 30px rgba(15, 78, 95, 0.08);
    padding: 40px 48px;
    transition: all 0.25s ease;
}

/* Header */
.wpc-card-header {
    border-bottom: 2px solid #0f4e5f;
    padding-bottom: 24px;
    margin-bottom: 30px;
}

.wpc-badge-header {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #0f4e5f;
    background: #e6f3f6;
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 10px;
}

.wpc-title {
    font-size: 1.85rem;
    font-weight: 700;
    color: #072a34;
    margin: 0 0 8px 0;
    letter-spacing: -0.4px;
    line-height: 1.25;
}

.wpc-subhead {
    font-size: 0.94rem;
    color: #4b6a7c;
    margin: 0 0 14px 0;
    line-height: 1.55;
}

.wpc-mandatory-notice {
    font-size: 0.82rem;
    color: #6a8292;
    background: #f7fafc;
    border-left: 3px solid #c59b27;
    padding: 8px 14px;
    border-radius: 0 6px 6px 0;
}

.wpc-req-asterisk {
    color: #d9534f;
    font-weight: 700;
    margin-left: 2px;
    font-size: 1.05em;
}

/* Grid Layout */
.wpc-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px 28px;
}

.wpc-full-width {
    grid-column: 1 / -1;
}

.wpc-dates-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* Form Controls */
.wpc-field-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    position: relative;
}

.wpc-field-group label {
    font-size: 0.8rem;
    font-weight: 700;
    color: #123d4e;
    letter-spacing: 0.4px;
    text-transform: uppercase;
}

.wpc-input-wrapper,
.wpc-select-wrapper {
    position: relative;
    width: 100%;
}

.wpc-booking-wrapper input[type="text"],
.wpc-booking-wrapper input[type="email"],
.wpc-booking-wrapper input[type="tel"],
.wpc-booking-wrapper input[type="date"],
.wpc-booking-wrapper select {
    width: 100%;
    height: 48px;
    padding: 10px 14px;
    border: 1.5px solid #c8d7e1;
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: inherit;
    background-color: #ffffff;
    color: #0b2e4e;
    outline: none;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
    -webkit-appearance: none;
    appearance: none;
}

.wpc-select-wrapper::after {
    content: '';
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid #4a6878;
    pointer-events: none;
}

.wpc-booking-wrapper input:focus,
.wpc-booking-wrapper select:focus {
    border-color: #0f4e5f;
    box-shadow: 0 0 0 3px rgba(15, 78, 95, 0.14);
    background-color: #ffffff;
}

/* Validated State */
.wpc-field-group.has-success input,
.wpc-field-group.has-success select {
    border-color: #27ae60;
}

/* Inline Error State */
.wpc-field-group.has-error input,
.wpc-field-group.has-error select {
    border-color: #c0392b;
    background-color: #fffbfa;
    box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.08);
}

.wpc-error-message {
    font-size: 0.76rem;
    color: #c0392b;
    font-weight: 600;
    min-height: 16px;
    margin-top: 2px;
    display: block;
    line-height: 1.3;
}

.wpc-field-hint {
    font-size: 0.74rem;
    color: #6a8292;
    margin-top: 2px;
}

/* Amount Breakdown Card */
.wpc-amount-box {
    background: linear-gradient(145deg, #f5f9fb 0%, #edf4f8 100%);
    border: 1.5px solid #cfdeea;
    border-radius: 10px;
    padding: 22px 26px;
    margin-top: 10px;
}

.wpc-amount-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #dce8ef;
    padding-bottom: 12px;
    margin-bottom: 14px;
}

.wpc-amount-tag {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: #4b6a7c;
}

.wpc-rate-pill {
    font-size: 0.82rem;
    font-weight: 600;
    color: #0f4e5f;
    background: #ffffff;
    padding: 4px 12px;
    border-radius: 14px;
    border: 1px solid #c9dae5;
}

.wpc-amount-body {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}

.wpc-amount-label {
    font-size: 1.05rem;
    font-weight: 700;
    color: #0b2e4e;
    letter-spacing: -0.2px;
}

.wpc-amount-value {
    font-size: 2.1rem;
    font-weight: 800;
    color: #0f4e5f;
    letter-spacing: -0.6px;
    line-height: 1;
}

.wpc-currency-code {
    font-size: 0.92rem;
    font-weight: 600;
    color: #557588;
    margin-left: 6px;
}

.wpc-amount-footer {
    font-size: 0.78rem;
    color: #688596;
    margin-top: 10px;
}

/* Submit Action Button */
.wpc-action-area {
    margin-top: 10px;
}

.wpc-btn-pay {
    width: 100%;
    min-height: 52px;
    background: linear-gradient(135deg, #0f4e5f 0%, #0a3a47 100%);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 1.02rem;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    box-shadow: 0 4px 14px rgba(15, 78, 95, 0.28);
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.wpc-btn-pay:hover {
    background: linear-gradient(135deg, #135d72 0%, #0f4e5f 100%);
    box-shadow: 0 6px 18px rgba(15, 78, 95, 0.35);
    transform: translateY(-1px);
}

.wpc-btn-pay:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(15, 78, 95, 0.2);
}

.wpc-btn-pay:disabled {
    opacity: 0.65;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.wpc-btn-pay.is-loading .wpc-btn-icon {
    animation: wpc-spin 1s linear infinite;
}

@keyframes wpc-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Gateway Trust */
.wpc-gateway-trust {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 14px;
    font-size: 0.78rem;
    color: #557282;
    text-align: center;
}

/* Success Card */
.wpc-success-card {
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #cce5d7;
    box-shadow: 0 8px 32px rgba(14, 128, 79, 0.1);
    padding: 44px 48px;
    text-align: center;
    animation: wpcFadeIn 0.35s ease;
}

@keyframes wpcFadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

.wpc-success-icon-wrap {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: #eafaf1;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 18px;
    border: 2px solid #b7ebd3;
}

.wpc-success-badge {
    display: inline-block;
    background: #e6f7ef;
    color: #0e804f;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 4px 14px;
    border-radius: 16px;
    margin-bottom: 8px;
}

.wpc-success-title {
    font-size: 1.9rem;
    color: #0c432a;
    margin: 0 0 10px 0;
    font-weight: 700;
}

.wpc-success-lead {
    font-size: 1rem;
    color: #4a5d6e;
    margin: 0 auto 28px;
    max-width: 580px;
    line-height: 1.55;
}

/* Receipt Details */
.wpc-receipt-summary {
    background: #f8fafc;
    border: 1px solid #dce5eb;
    border-radius: 8px;
    padding: 22px 28px;
    text-align: left;
    margin-bottom: 26px;
}

.wpc-receipt-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #edf2f6;
    font-size: 0.92rem;
}

.wpc-receipt-row:last-child {
    border-bottom: none;
    padding-top: 14px;
}

.wpc-receipt-label {
    color: #6a8292;
}

.wpc-receipt-value {
    color: #0b2e4e;
    font-weight: 600;
}

.wpc-receipt-total {
    font-size: 1.15rem;
    font-weight: 800;
    color: #0f4e5f;
}

.wpc-success-instructions {
    background: #fffdf5;
    border: 1px solid #faecc1;
    border-radius: 6px;
    padding: 16px 20px;
    text-align: left;
    font-size: 0.88rem;
    color: #6b5314;
    line-height: 1.5;
    margin-bottom: 28px;
}

.wpc-success-instructions p {
    margin: 4px 0;
}

.wpc-success-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
}

.wpc-btn-secondary {
    background: #eef3f6;
    color: #0f4e5f;
    border: 1px solid #c8d8e2;
    padding: 12px 22px;
    border-radius: 6px;
    font-size: 0.92rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.wpc-btn-secondary:hover {
    background: #e1ecf2;
}

.wpc-btn-print {
    background: #0f4e5f;
    color: #ffffff;
    border: none;
    padding: 12px 22px;
    border-radius: 6px;
    font-size: 0.92rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.wpc-btn-print:hover {
    background: #0b3b48;
}

/* Responsive adjustments */
@media (max-width: 640px) {
    .wpc-booking-card,
    .wpc-success-card {
        padding: 24px 18px;
    }

    .wpc-form-grid,
    .wpc-dates-row {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .wpc-title {
        font-size: 1.45rem;
    }

    .wpc-amount-body {
        flex-direction: column;
        gap: 6px;
    }

    .wpc-amount-value {
        font-size: 1.7rem;
    }

    .wpc-success-actions {
        flex-direction: column;
    }
}
