/* Estilos específicos para la página Hacerse Hermano */

/* Banner */
.hermandad-banner {
    width: 100%;
    height: 420px;
    position: relative;
    overflow: hidden;
}

.hermandad-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 60% 40%;
}

.white-box {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 120px;
    background: rgba(255,255,255,0.6);
    border-radius: 12px;
    z-index: 1;
}

.text-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    text-align: center;
    width: 560px;
    padding: 10px 20px;
}

.text-container h1 {
    color: #0F4C81;
    font-family: 'Great Vibes', cursive;
    font-size: 4.5rem;
    font-weight: 400;
    margin: 0;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
    letter-spacing: 1px;
    line-height: 1.2;
}

/* Main content */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* Variables CSS para el formulario */
:root {
    --primary: #0F4C81;
    --primary-light: #4a7cb1;
    --secondary: #800020;
    --tertiary: #D4AF37;
    --white: #FFFFFF;
    --gray-light: #f5f5f5;
    --gray-medium: #e0e0e0;
    --gray-dark: #757575;
    --error: #d32f2f;
}

/* Estilos del formulario */
main .container {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.card {
    background-color: var(--white);
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1), 0 4px 8px rgba(0,0,0,0.1);
    overflow: hidden;
    margin-bottom: 24px;
}

.card-header {
    background-color: var(--primary);
    color: var(--white);
    padding: 24px 32px;
}

.card-header h1 {
    font-weight: 500;
    font-size: 2rem;
    margin-bottom: 12px;
    text-align: center;
}

.card-header .subtitle {
    font-size: 1.2rem;
    font-weight: 400;
    margin-bottom: 16px;
    opacity: 0.9;
    text-align: center;
}

.card-header .description {
    font-size: 0.95rem;
    line-height: 1.6;
    margin-top: 16px;
    padding: 16px;
    background-color: rgba(255,255,255,0.1);
    border-radius: 4px;
    text-align: left;
}

.card-header .description p {
    margin-bottom: 12px;
}

.card-header .description p:last-child {
    margin-bottom: 0;
}

.card-body {
    padding: 32px;
}

.section {
    margin-bottom: 32px;
}

.section-title {
    color: var(--secondary);
    font-size: 1.3rem;
    font-weight: 500;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--tertiary);
}

.section-title .material-icons {
    margin-right: 8px;
    font-size: 1.5rem;
}

.form-row {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin-bottom: 16px;
}

.form-group {
    flex: 1;
    min-width: 250px;
    position: relative;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    color: var(--primary);
    font-weight: 500;
    font-size: 0.9rem;
}

.input-container {
    position: relative;
}

.input-field {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--gray-medium);
    border-radius: 4px;
    font-size: 1rem;
    background-color: var(--white);
    transition: all 0.3s;
}

.input-field:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(15, 76, 129, 0.2);
}

.input-field.error {
    border-color: var(--error);
}

.input-helper {
    font-size: 0.75rem;
    color: var(--gray-dark);
    margin-top: 4px;
    display: block;
}

.input-helper.error {
    color: var(--error);
}

.checkbox-container {
    display: flex;
    align-items: flex-start;
    margin-bottom: 24px;
}

.checkbox-container input {
    margin-right: 12px;
    margin-top: 4px;
}

.checkbox-label {
    font-size: 0.9rem;
    color: #424242;
}

.checkbox-label a {
    color: var(--primary);
    text-decoration: none;
}

.checkbox-label a:hover {
    text-decoration: underline;
}

.radio-group {
    display: flex;
    gap: 24px;
    margin-bottom: 16px;
}

.radio-option {
    display: flex;
    align-items: center;
}

.radio-option input {
    margin-right: 8px;
}

.tutor-fields {
    display: none;
    margin-top: 16px;
    padding: 16px;
    background-color: var(--gray-light);
    border-radius: 4px;
    border-left: 4px solid var(--tertiary);
}

details {
    margin-bottom: 24px;
}

details summary {
    color: var(--secondary);
    font-weight: 500;
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    padding: 8px 0;
}

details summary::-webkit-details-marker {
    display: none;
}

details summary:after {
    content: "expand_more";
    font-family: 'Material Icons';
    font-size: 1.5rem;
    margin-left: 8px;
    transition: transform 0.2s;
}

details[open] summary:after {
    transform: rotate(180deg);
}

.legal-text {
    background-color: var(--gray-light);
    border: 1px solid var(--tertiary);
    padding: 16px;
    border-radius: 4px;
    font-size: 0.85rem;
    color: #424242;
    max-height: 200px;
    overflow-y: auto;
    line-height: 1.5;
}

.actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 32px;
}

.btn {
    padding: 12px 32px;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary {
    background-color: var(--primary);
    color: var(--white);
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.btn-primary:hover {
    background-color: var(--primary-light);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.btn-primary .material-icons {
    margin-left: 8px;
}

.required:after {
    content: " *";
    color: var(--error);
}

/* Responsive */
@media (max-width: 900px) {
    .hermandad-banner {
        height: 300px;
    }
    
    .white-box,
    .text-container {
        width: 90% !important;
        max-width: 600px;
    }
    
    .white-box {
        height: 100px !important;
    }
    
    .text-container {
        width: calc(90% - 40px) !important;
    }
    
    .hermandad-banner h1 {
        font-size: 2.8rem !important;
    }
}

@media (max-width: 768px) {
    main .container {
        padding: 0;
    }
    
    .card-header {
        padding: 20px;
    }
    
    .card-body {
        padding: 20px;
    }
    
    .form-group {
        min-width: 100%;
    }
    
    .radio-group {
        flex-direction: column;
        gap: 12px;
    }
    
    .btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .white-box {
        height: 150px !important;
    }
    
    .text-container {
        width: calc(90% - 30px) !important;
        padding: 5px 15px !important;
    }
    
    .hermandad-banner h1 {
        font-size: 2.2rem !important;
        line-height: 1.1 !important;
    }
    
    main {
        padding: 1rem;
    }
}

/* Estilos para mensajes de éxito y error */
.success-message, .error-message {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.message-content {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    text-align: center;
    max-width: 500px;
    margin: 20px;
    animation: slideIn 0.3s ease;
}

.success-message .message-content {
    border-left: 5px solid #4CAF50;
}

.error-message .message-content {
    border-left: 5px solid #f44336;
}

.message-content i {
    font-size: 48px;
    margin-bottom: 15px;
}

.success-message .message-content i {
    color: #4CAF50;
}

.error-message .message-content i {
    color: #f44336;
}

.message-content h3 {
    margin: 0 0 15px 0;
    font-size: 24px;
    color: #333;
}

.message-content p {
    margin: 0 0 15px 0;
    color: #666;
    line-height: 1.5;
}

.message-content button {
    margin-top: 15px;
}

/* Animaciones */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { 
        opacity: 0;
        transform: translateY(-30px);
    }
    to { 
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive para mensajes */
@media (max-width: 768px) {
    .message-content {
        padding: 20px;
        margin: 10px;
    }
    
    .message-content i {
        font-size: 36px;
    }
    
    .message-content h3 {
        font-size: 20px;
    }
}

/* Estilos para el campo de firma */
.signature-canvas {
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background-color: #fff;
    cursor: crosshair;
    margin-top: 10px;
    display: block;
    height: 100px;
    width: 300px;
}

.signature-controls {
    margin-top: 10px;
}

.btn-signature {
    padding: 8px 16px;
    background-color: #f5f5f5;
    color: #0F4C81;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background-color 0.3s;
}

.btn-signature:hover {
    background-color: #e0e0e0;
}

@media (max-width: 768px) {
    .signature-canvas {
        width: 100% !important;
        height: 80px !important;
    }
}