/* Contratación online (/contratar). Misma paleta que la página pública de reservas (reservar.css). */
:root {
    --sg-ink: #0a2540;
    --sg-muted: #697386;
    --sg-line: #e3e8ee;
    --sg-field-line: #c9d2dc;
    --sg-field-bg: #f8fafc;
    --sg-accent: #635bff;
    --sg-accent-deep: #4f46e5;
    --sg-accent-soft: #eeedfe;
    --sg-surface: #ffffff;
    --sg-page: linear-gradient(180deg, #f7f6ff 0%, #f4f7fb 100%);
    --sg-danger: #df1b41;
    --sg-success: #0e7c4a;
    --sg-shadow: 0 24px 60px rgba(50, 50, 93, 0.10), 0 8px 18px rgba(0, 0, 0, 0.04);
}

@media (prefers-color-scheme: dark) {
    :root {
        --sg-ink: #e6e9f0;
        --sg-muted: #9aa4b5;
        --sg-line: #2a3242;
        --sg-field-line: #3a4457;
        --sg-field-bg: #151b27;
        --sg-accent: #7c75ff;
        --sg-accent-deep: #948eff;
        --sg-accent-soft: #23224a;
        --sg-surface: #1b2230;
        --sg-page: linear-gradient(180deg, #11151f 0%, #0d1119 100%);
        --sg-danger: #ff6b86;
        --sg-success: #4cc38a;
        --sg-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
    }
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html, body { margin: 0; min-height: 100%; }

body {
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--sg-ink);
    background: var(--sg-page);
}

.sg-ribbon {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #f5c451 0%, #f472b6 34%, #84cc16 67%, #38bdf8 100%);
    z-index: 2;
}

.sg-shell {
    width: min(980px, calc(100% - 32px));
    margin: 0 auto;
    padding: 32px 0 56px;
}

.sg-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
}

.sg-brand {
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.sg-progress {
    color: var(--sg-muted);
    font-size: 14px;
    font-weight: 600;
}

.sg-card {
    background: var(--sg-surface);
    border: 1px solid var(--sg-line);
    border-radius: 12px;
    box-shadow: var(--sg-shadow);
    padding: 32px;
}

.sg-card--narrow {
    max-width: 520px;
    margin: 0 auto;
}

.sg-split {
    display: grid;
    grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

.sg-title {
    margin: 0 0 10px;
    font-size: 26px;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.sg-text {
    margin: 0 0 24px;
    color: var(--sg-muted);
    line-height: 1.55;
}

.sg-text strong { color: var(--sg-ink); }

.sg-kicker {
    margin: 0 0 14px;
    color: var(--sg-accent);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.sg-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.sg-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 0;
}

.sg-label {
    font-size: 0.82rem;
    font-weight: 600;
}

.sg-input {
    width: 100%;
    min-height: 46px;
    padding: 0 14px;
    border: 1px solid var(--sg-field-line);
    border-radius: 10px;
    background: var(--sg-field-bg);
    color: var(--sg-ink);
    font: inherit;
    font-size: 16px;
}

.sg-input:focus {
    outline: none;
    border-color: var(--sg-accent);
    box-shadow: 0 0 0 4px rgba(99, 91, 255, 0.16);
}

.sg-input:disabled { opacity: 0.7; }

.sg-input.is-invalid { border-color: var(--sg-danger); }

.sg-input--code {
    font-size: 24px;
    letter-spacing: 0.4em;
    text-align: center;
}

.sg-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.sg-grid__full { grid-column: 1 / -1; }

.sg-hint {
    margin: -6px 0 0;
    color: var(--sg-muted);
    font-size: 13px;
}

.sg-error, .sg-ok {
    margin: 0;
    font-size: 14px;
}

.sg-error { color: var(--sg-danger); }

.sg-ok { color: var(--sg-success); }

.sg-notice {
    margin: 0;
    color: var(--sg-muted);
    font-size: 13px;
    line-height: 1.5;
}

.sg-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 18px;
    border-radius: 10px;
    border: 1px solid transparent;
    font: inherit;
    font-size: 0.95rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.sg-btn--primary {
    background: var(--sg-accent);
    color: #fff;
}

.sg-btn--primary:hover:not(:disabled) { background: var(--sg-accent-deep); }

.sg-btn--ghost {
    background: transparent;
    color: var(--sg-accent);
    border-color: var(--sg-accent);
}

.sg-btn--ghost:hover:not(:disabled) { background: var(--sg-accent-soft); }

.sg-btn:disabled {
    opacity: 0.45;
    cursor: default;
}

.sg-links {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.sg-link {
    padding: 0;
    border: 0;
    background: none;
    color: var(--sg-accent);
    font: inherit;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.sg-link:disabled { opacity: 0.45; cursor: default; }

.sg-products {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.sg-product {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 14px 16px;
    border: 1px solid var(--sg-field-line);
    border-radius: 10px;
    cursor: pointer;
}

.sg-product.is-checked {
    border-color: var(--sg-accent);
    background: var(--sg-accent-soft);
}

.sg-product.is-disabled {
    opacity: 0.55;
    cursor: default;
}

.sg-product input,
.sg-check input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    flex: 0 0 18px;
    accent-color: var(--sg-accent);
}

.sg-product__body {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.sg-product__name { font-weight: 700; }

.sg-product__price,
.sg-product__note {
    color: var(--sg-muted);
    font-size: 14px;
}

.sg-product__note { font-style: italic; }

.sg-consents {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.sg-check {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    font-size: 14px;
    line-height: 1.45;
}

.sg-summary__list {
    margin: 0 0 20px;
}

.sg-summary__list dt {
    color: var(--sg-muted);
    font-size: 13px;
    font-weight: 600;
}

.sg-summary__list dd {
    margin: 2px 0 14px;
    font-weight: 600;
    line-height: 1.4;
}

.sg-spinner {
    width: 36px;
    height: 36px;
    margin: 0 0 20px;
    border: 3px solid var(--sg-accent-soft);
    border-top-color: var(--sg-accent);
    border-radius: 50%;
    animation: sg-spin 0.9s linear infinite;
}

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

@media (prefers-reduced-motion: reduce) {
    .sg-spinner { animation-duration: 3s; }
}

.sg-hp {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

@media (max-width: 760px) {
    .sg-shell { width: calc(100% - 32px); padding-top: 24px; }
    .sg-card { padding: 24px 20px; }
    .sg-split { grid-template-columns: 1fr; }
    .sg-grid { grid-template-columns: 1fr; }
}

@supports (-webkit-touch-callout: none) {
    .sg-input, select.sg-input {
        font-size: 16px;
        min-height: 44px;
        -webkit-appearance: none;
        appearance: none;
    }
}
