/* Estilos base del libro de reclamaciones alineados con la web principal */

.libro-page {
    background: linear-gradient(180deg, var(--cream) 0%, #f8f6f2 100%);
    color: var(--text);
}

.libro-header {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: min(calc(100% - 36px), var(--container));
    z-index: 100;
}

.libro-main {
    padding: 140px 0 80px;
}

.libro-intro {
    padding: 10px 0 34px;
}

.libro-intro h1 {
    margin: 6px 0 14px;
    color: var(--navy);
    font-family: "Playfair Display", serif;
    font-size: clamp(34px, 5vw, 56px);
    font-weight: 500;
    line-height: 1.08;
}

.libro-intro p {
    max-width: 760px;
    margin: 0;
    color: var(--muted);
    font-size: 18px;
}

.libro-form {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: 20px;
    padding: clamp(18px, 4vw, 36px);
    box-shadow: 0 22px 60px rgba(13, 27, 45, 0.08);
}

.empresa-card {
    background: linear-gradient(145deg, var(--blue-soft-2) 0%, #f9fbff 100%);
    border: 1px solid rgba(93, 132, 182, 0.35);
    border-radius: 16px;
    padding: 18px;
    margin-bottom: 22px;
}

.empresa-card h2 {
    margin: 0 0 12px;
    color: var(--navy);
    font-family: "Playfair Display", serif;
    font-size: 30px;
    font-weight: 500;
}

.empresa-card p {
    margin: 6px 0;
    color: var(--text);
}

.form-block {
    margin-bottom: 22px;
}

.form-block h3 {
    margin: 0 0 14px;
    color: var(--blue-deep);
    font-size: 20px;
    font-weight: 600;
}

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

.hp-field {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.form-grid-2,
.form-grid-3 {
    display: grid;
    gap: 16px;
    margin-bottom: 14px;
}

.form-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.libro-form label {
    color: var(--navy-light);
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.01em;
}

.libro-form input,
.libro-form select,
.libro-form textarea {
    width: 100%;
    border: 1px solid rgba(26, 62, 103, 0.28);
    border-radius: 10px;
    background: #fbfdff;
    color: var(--text);
    font-family: "DM Sans", sans-serif;
    font-size: 16px;
    line-height: 1.45;
    padding: 12px 14px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.libro-form textarea {
    resize: vertical;
    min-height: 130px;
}

.libro-form input:focus,
.libro-form select:focus,
.libro-form textarea:focus {
    outline: none;
    border-color: var(--blue-mid);
    box-shadow: 0 0 0 3px rgba(93, 132, 182, 0.22);
    background: var(--white);
}

.libro-form .is-invalid {
    border-color: #b42318;
    box-shadow: 0 0 0 3px rgba(180, 35, 24, 0.14);
}

.type-help {
    border-left: 3px solid var(--blue-mid);
    padding: 10px 0 10px 14px;
    color: var(--muted);
    font-size: 15px;
}

.type-help p {
    margin: 0 0 6px;
}

.type-help p:last-child {
    margin-bottom: 0;
}

.align-start {
    align-items: start;
}

.consent-box {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 6px 0 4px;
    padding: 12px 14px;
    border: 1px solid rgba(26, 62, 103, 0.22);
    border-radius: 10px;
    background: #f9fbff;
}

.consent-box input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    flex: 0 0 auto;
}

.consent-box label {
    margin: 0;
    color: var(--text);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.5;
}

.policy-link {
    display: inline;
    border: 0;
    background: transparent;
    padding: 0;
    margin: 0;
    color: var(--blue-deep);
    font: inherit;
    font-weight: 700;
    text-decoration: underline;
    cursor: pointer;
}

.policy-link:hover {
    color: var(--navy);
}

.consent-box.has-error {
    border-color: #b42318;
    box-shadow: 0 0 0 3px rgba(180, 35, 24, 0.14);
}

.form-human-check {
    margin-top: 12px;
}

.modal-open {
    overflow: hidden;
}

.policy-modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: none;
}

.policy-modal.is-open {
    display: block;
}

.policy-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(13, 27, 45, 0.62);
}

.policy-modal-card {
    position: relative;
    z-index: 1;
    width: min(760px, calc(100% - 32px));
    max-height: calc(100vh - 48px);
    overflow: auto;
    margin: 24px auto;
    padding: 24px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: #fff;
    box-shadow: 0 28px 60px rgba(13, 27, 45, 0.24);
}

.policy-modal-card h2 {
    margin: 0 28px 14px 0;
    color: var(--navy);
    font-family: "Playfair Display", serif;
    font-size: clamp(28px, 3.2vw, 38px);
    line-height: 1.12;
}

.policy-modal-card p {
    margin: 0 0 10px;
    color: var(--text);
    font-size: 15px;
    line-height: 1.65;
}

.policy-modal-note {
    margin-top: 14px;
    padding-top: 10px;
    border-top: 1px solid rgba(23, 40, 61, 0.14);
    color: var(--muted);
}

.policy-modal-close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 50%;
    background: #f0f4fa;
    color: var(--navy);
    font-size: 23px;
    line-height: 1;
    cursor: pointer;
}

.policy-modal-close:hover {
    background: #e6edf6;
}

.libro-submit {
    display: inline-flex;
    margin-top: 20px;
    justify-content: center;
    align-items: center;
    border: 0;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--navy) 0%, var(--blue-deep) 100%);
    color: var(--white);
    font-family: "DM Sans", sans-serif;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.01em;
    padding: 13px 28px;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.libro-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgba(26, 62, 103, 0.28);
}

.libro-submit:disabled {
    opacity: 0.7;
    cursor: wait;
    transform: none;
    box-shadow: none;
}

.libro-feedback {
    margin: 14px 0 0;
    font-weight: 500;
}

.libro-feedback.is-error {
    color: #b42318;
}

.libro-feedback.is-success {
    color: #067647;
}

.libro-legal {
    margin-top: 20px;
    padding: 16px;
    border-radius: 12px;
    border: 1px solid rgba(23, 40, 61, 0.16);
    background: #fafbfd;
    color: var(--muted);
    font-size: 15px;
}

.libro-legal p {
    margin: 0 0 8px;
}

.libro-legal p:last-child {
    margin-bottom: 0;
}
