.ccch-preinscripcion-publica,
.ccch-preinscripciones-admin {
    margin: 1.5rem 0;
}

.ccch-preinscripcion-form {
    margin-top: 1rem;
}

.ccch-preinscripcion-form .field {
    margin-bottom: 8px;
}

.ccch-preinscripcion-form label {
    margin-bottom: 2px;
    font-size: 0.9rem;
}

.ccch-preinscripcion-form input,
.ccch-preinscripcion-form select,
.ccch-preinscripcion-form textarea {
    padding: 8px 10px;
}

.ccch-preinscripcion-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 10px;
}

.ccch-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.ccch-col-12 { grid-column: span 12; }
.ccch-col-8  { grid-column: span 8; }
.ccch-col-4  { grid-column: span 4; }
.ccch-col-3  { grid-column: span 3; }

.ccch-field label {
    font-weight: 600;
}

.ccch-field input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.2;
}

.ccch-pre-photo-preview {
    display: none;
    width: 100%;
    max-height: 220px;
    object-fit: contain;
    margin-top: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fff;
}

.ccch-signature-box {
    border: 1px solid #d1d5db;
    border-radius: 10px;
    padding: 12px;
    background: #fafafa;
}

#ccch_pre_signature_canvas {
    width: 100%;
    height: 220px;
    border: 1px dashed #9ca3af;
    border-radius: 8px;
    background: #fff;
    touch-action: none;
}

.ccch-signature-actions {
    margin-top: 10px;
}

.ccch-signature-actions button,
.ccch-preinscripcion-submit button {
    padding: 10px 16px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}

.ccch-help-text {
    color: #666;
    font-size: 13px;
}

.ccch-preinscripcion-legal {
    margin-top: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ccch-check {
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

.ccch-check input {
    width: auto;
    margin-top: 3px;
}

.ccch-preinscripcion-submit {
    margin-top: 1.25rem;
}

.ccch-preinscripcion-success,
.ccch-preinscripcion-errors {
    margin: 1rem 0;
    padding: 12px 14px;
    border-radius: 8px;
}

.ccch-preinscripcion-success {
    background: #e8f5e9;
    border: 1px solid #b7d8bb;
}

.ccch-preinscripcion-errors {
    background: #fdecea;
    border: 1px solid #e5b9b4;
}

.ccch-preinscripcion-errors ul {
    margin: 8px 0 0 18px;
}

.ccch-preinscripciones-tabla-wrap {
    overflow-x: auto;
}

.ccch-preinscripciones-tabla {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
}

.ccch-preinscripciones-tabla th,
.ccch-preinscripciones-tabla td {
    border: 1px solid #ddd;
    padding: 6px 8px;
    text-align: left;
    vertical-align: top;
    white-space: nowrap;
}

.ccch-preinscripciones-tabla th {
    background: #f4f4f4;
    font-weight: 600;
}

@media (max-width: 800px) {
    .ccch-col-12,
    .ccch-col-8,
    .ccch-col-4,
    .ccch-col-3 {
        grid-column: span 12;
    }
}

.ccch-preinscripcion-success-link {
    margin-top: 8px;
}

.ccch-preinscripcion-success-link a {
    text-decoration: underline;
}

.ccch-preinscripcion-admin-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin: 1rem 0;
}

.ccch-pre-card {
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 14px;
    background: #fff;
}

.ccch-pre-card h3 {
    margin-top: 0;
    margin-bottom: 12px;
}

.ccch-pre-detail-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
}

.ccch-pre-detail-table th,
.ccch-pre-detail-table td {
    padding: 6px 8px;
    border: 1px solid #e3e3e3;
    text-align: left;
    vertical-align: top;
}

.ccch-pre-detail-table th {
    width: 36%;
    background: #f8f8f8;
    font-weight: 600;
}

.ccch-pre-doc-image {
    max-width: 100%;
    height: auto;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fff;
}

.ccch-pre-doc-signature {
    max-height: 160px;
    object-fit: contain;
}

.ccch-pre-review-form select,
.ccch-pre-review-form textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.2;
}

.ccch-pre-review-fields {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 14px;
}

@media (max-width: 980px) {
    .ccch-preinscripcion-admin-grid {
        grid-template-columns: 1fr;
    }
}

.ccch-pre-list-filter {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    margin: 0 0 12px 0;
}

.ccch-pre-list-filter select,
.ccch-pre-list-filter button {
    padding: 6px 10px;
    border-radius: 8px;
}

.ccch-preinscripciones-tabla th,
.ccch-preinscripciones-tabla td {
    padding: 4px 6px;
    font-size: 0.88rem;
    line-height: 1.15;
}

.ccch-pre-estado {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 0.84rem;
    font-weight: 600;
    white-space: nowrap;
}

.ccch-pre-estado-pendiente {
    background: #eef4ff;
}

.ccch-pre-estado-en_revision {
    background: #fff4d6;
}

.ccch-pre-estado-aprobada {
    background: #e8f5e9;
}

.ccch-pre-estado-rechazada {
    background: #fdecea;
}

.ccch-pre-estado-definitiva {
    background: #e6f4f1;
}

.ccch-pre-review-form select {
    min-width: 220px;
    width: auto;
    max-width: 100%;
}

.ccch-pre-list-filter input[type="text"] {
    min-width: 280px;
    padding: 6px 10px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
}

.ccch-preinscripciones-tabla td:nth-last-child(3),
.ccch-preinscripciones-tabla td:nth-last-child(2),
.ccch-preinscripciones-tabla td:last-child,
.ccch-preinscripciones-tabla th:nth-last-child(3),
.ccch-preinscripciones-tabla th:nth-last-child(2),
.ccch-preinscripciones-tabla th:last-child {
    white-space: nowrap;
    width: 1%;
}

.ccch-pre-review-form input[type="text"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.2;
}

.ccch-preinscripcion-admin-grid > * {
    min-width: 0;
}

.ccch-pre-card {
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.ccch-pre-card p,
.ccch-pre-card a,
.ccch-pre-card code,
.ccch-pre-card span {
    overflow-wrap: anywhere;
    word-break: break-word;
}

.ccch-pre-doc-image {
    display: block;
    max-width: 100%;
    height: auto;
}

.ccch-pre-doc-signature {
    max-width: 100%;
    max-height: 160px;
    object-fit: contain;
}

.ccch-pre-ruta-externa {
    display: block;
    margin-top: 4px;
    font-size: 0.88rem;
    line-height: 1.2;
    color: #444;
}

.ccch-pre-card a[target="_blank"] {
    word-break: break-word;
}
.ccch-pre-legal-box {
    border: 1px solid #d1d5db;
    border-radius: 10px;
    background: #fafafa;
    padding: 14px;
    font-size: 0.92rem;
    line-height: 1.4;
}

.ccch-pre-legal-box p {
    margin: 0 0 8px 0;
}

.ccch-pre-legal-box p:last-child {
    margin-bottom: 0;
}

.ccch-preinscripcion-captcha {
    margin-top: 12px;
}