/* ============================================================
   MSC Cruises Plugin — Explora Mundos
   Colores basados en la identidad de exploramundosbl.com
   ============================================================ */

:root {
    --msc-navy:    #0a1f44;
    --msc-blue:    #1a5fa8;
    --msc-gold:    #c8a84b;
    --msc-light:   #f0f6ff;
    --msc-white:   #ffffff;
    --msc-gray:    #6b7280;
    --msc-border:  #dce6f5;
    --msc-radius:  10px;
    --msc-shadow:  0 4px 18px rgba(10, 31, 68, 0.10);
}

/* ── Widget Wrapper ─────────────────────────────────── */
.msc-widget {
    background: var(--msc-white);
    border: 1px solid var(--msc-border);
    border-radius: var(--msc-radius);
    padding: 28px;
    margin: 30px 0;
    box-shadow: var(--msc-shadow);
    font-family: inherit;
}

.msc-widget__title {
    color: var(--msc-navy);
    font-size: 1.5rem;
    margin: 0 0 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--msc-border);
}

/* ── Form ───────────────────────────────────────────── */
.msc-form__row {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 16px;
}

.msc-form__group {
    flex: 1 1 180px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.msc-form__group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--msc-navy);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.msc-input,
.msc-select {
    padding: 10px 14px;
    border: 1.5px solid var(--msc-border);
    border-radius: 6px;
    font-size: 0.95rem;
    color: var(--msc-navy);
    background: var(--msc-white);
    transition: border-color 0.2s;
    width: 100%;
    box-sizing: border-box;
}

.msc-input:focus,
.msc-select:focus {
    outline: none;
    border-color: var(--msc-blue);
    box-shadow: 0 0 0 3px rgba(26, 95, 168, 0.12);
}

.msc-form__group--btn {
    justify-content: flex-end;
}

/* ── Buttons ────────────────────────────────────────── */
.msc-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 11px 24px;
    border-radius: 6px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.2s;
    text-decoration: none;
}

.msc-btn--primary {
    background: var(--msc-blue);
    color: var(--msc-white);
    border-color: var(--msc-blue);
}
.msc-btn--primary:hover {
    background: var(--msc-navy);
    border-color: var(--msc-navy);
}
.msc-btn--primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.msc-btn--secondary {
    background: transparent;
    color: var(--msc-blue);
    border-color: var(--msc-blue);
}
.msc-btn--secondary:hover {
    background: var(--msc-blue);
    color: var(--msc-white);
}

.msc-btn--ghost {
    background: var(--msc-light);
    color: var(--msc-navy);
    border-color: var(--msc-border);
    font-size: 0.88rem;
}
.msc-btn--ghost:hover {
    background: var(--msc-border);
}

/* ── Grid of cards ──────────────────────────────────── */
.msc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.msc-card {
    background: var(--msc-white);
    border: 1px solid var(--msc-border);
    border-radius: var(--msc-radius);
    overflow: hidden;
    box-shadow: var(--msc-shadow);
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}
.msc-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 28px rgba(10, 31, 68, 0.14);
}

.msc-card--cabin {
    border-top: 3px solid var(--msc-gold);
}

.msc-card__body {
    padding: 18px;
    flex: 1;
}

.msc-card__title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--msc-navy);
    margin: 0 0 8px;
}

.msc-card__ship {
    font-size: 0.88rem;
    color: var(--msc-gray);
    margin: 0 0 10px;
}

.msc-card__details {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.msc-card__details span {
    background: var(--msc-light);
    color: var(--msc-navy);
    border-radius: 4px;
    padding: 3px 10px;
    font-size: 0.82rem;
    font-weight: 500;
}

.msc-card__price {
    font-size: 1rem;
    color: var(--msc-blue);
    margin: 0;
}
.msc-card__price strong {
    font-size: 1.2rem;
    color: var(--msc-navy);
}

.msc-card__footer {
    padding: 14px 18px;
    border-top: 1px solid var(--msc-border);
    background: var(--msc-light);
}

/* ── States ─────────────────────────────────────────── */
.msc-loading {
    text-align: center;
    padding: 40px 20px;
    color: var(--msc-gray);
}

.msc-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid var(--msc-border);
    border-top-color: var(--msc-blue);
    border-radius: 50%;
    animation: msc-spin 0.8s linear infinite;
    margin: 0 auto 14px;
}

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

.msc-error {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: var(--msc-radius);
    padding: 16px 20px;
    color: #dc2626;
}

.msc-success {
    background: #f0fdf4;
    border: 1px solid #86efac;
    border-radius: var(--msc-radius);
    padding: 20px;
    color: #15803d;
}

.msc-success pre {
    font-size: 0.8rem;
    overflow-x: auto;
    margin-top: 12px;
    background: #dcfce7;
    padding: 12px;
    border-radius: 6px;
}

.msc-empty {
    text-align: center;
    padding: 40px;
    color: var(--msc-gray);
    background: var(--msc-light);
    border-radius: var(--msc-radius);
}

.msc-info {
    color: var(--msc-gray);
    font-style: italic;
    text-align: center;
    padding: 20px;
}

/* ── Booking fieldset ───────────────────────────────── */
.msc-fieldset {
    border: 1.5px solid var(--msc-border);
    border-radius: var(--msc-radius);
    padding: 20px;
    margin-bottom: 20px;
}

.msc-fieldset legend {
    font-weight: 700;
    color: var(--msc-navy);
    padding: 0 8px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ── Responsive ─────────────────────────────────────── */
@media (max-width: 600px) {
    .msc-widget {
        padding: 18px;
    }
    .msc-form__row {
        flex-direction: column;
    }
    .msc-grid {
        grid-template-columns: 1fr;
    }
}
