:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --light-bg: #ecf0f1;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden !important;
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: white;
}

/* Asegurar que los contenedores no excedan el ancho */
.courses-section,
.teachers-section,
.academic-section,
.fathers-section,
.students-section,
.schedule-section,
.enrollments-section,
.sections-section {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    box-sizing: border-box;
    background: transparent;
    padding: 15px;
    margin: 0;
}

/* Contenedor de tabla y tarjetas sin scroll */
.desktop-view,
.mobile-view,
.table-container {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden !important;
    overflow-y: visible !important; /* ✅ QUITA EL SCROLL */
    height: auto !important;        /* ✅ PERMITE CRECER */
    max-height: none !important;    /* ✅ EVITA LÍMITES */
    box-sizing: border-box;
}

/* Tarjetas en móvil sin exceder el ancho */
.course-card,
.teacher-card,
.academic-card,
.father-card,
.student-card,
.schedule-card,
.enrollment-card,
.section-card {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

/* Main container control */
.main-container {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    box-sizing: border-box;
}


/* Responsive en móvil */
@media (max-width: 991px) {
    .courses-section,
    .teachers-section,
    .academic-section,
    .fathers-section,
    .students-section,
    .schedule-section,
    .enrollments-section,
    .sections-section {
        padding: 10px;
        margin: 0;
        width: 100vw;
        position: relative;
        left: 0%;
        right: 0%;
        margin-left: -50vw;
        margin-right: -50vw;
    }
}

/* Navbar Fijo */
.navbar-custom {
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 10px 0;
}

.navbar-custom .container-fluid {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
    color: white !important;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-right: 0;
}

.navbar-brand img {
    height: 40px;
    width: auto;
    object-fit: contain;
}

/* AGREGADO: Espaciador para separar logo de nav */
.navbar-collapse {
    margin-left: auto;
}

.navbar-toggler {
    margin-left: 10px;
}

.nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    transition: all 0.3s ease;
    margin: 0 10px;
    font-weight: 500;
}

.nav-link:hover {
    color: var(--accent-color) !important;
    transform: translateY(-2px);
}

/* Carousel Section */
.carousel-section {
    background: white;
    padding: 0;
    min-height: 500px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    margin-top: 0;
    width: 100%; 
    margin-left: 0; 
    margin-right: 0;
}

.carousel-container {
    position: relative;
    max-width: 100%;
    width: 100%;
    height: 450px;
    flex: 0 0 auto;
}

.carousel-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.carousel-item-content {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    flex-shrink: 0;
    opacity: 1;
}

.carousel-item-content.active {
    opacity: 1;
}

.carousel-item-content img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Esto evita que se deforme */
    object-position: center; /* Esto asegura que el centro de la foto siempre se vea */
}

.carousel-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.8) 100%);
    color: white;
    padding: 40px;
    z-index: 10;
}

.carousel-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.carousel-description {
    font-size: 1rem;
    opacity: 0.95;
}

/* Controles del Carousel */
.carousel-controls {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    z-index: 20;
    pointer-events: none;
    width: 100%;
}

.carousel-btn {
    background: rgba(255, 255, 255, 0.3);
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    padding: 10px 15px;
    border-radius: 8px;
    transition: all 0.3s ease;
    pointer-events: all;
}

.carousel-btn:hover {
    background: rgba(255, 255, 255, 0.6);
    transform: scale(1.1);
}

.carousel-btn-prev:hover,
.carousel-btn-next:hover {
    color: var(--accent-color);
}


/* Indicadores */
.carousel-indicators {
    position: static;
    bottom: auto;
    left: auto;
    transform: none;
    display: flex;
    gap: 10px;
    z-index: 20;
    justify-content: center;
    padding: 20px 0; 
    background: white;
    width: 100%;
    flex: 0 0 50px;
}


.carousel-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(189, 184, 186, 1);
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    padding: 0;
}

.carousel-indicator.active {
    background: var(--accent-color);
    width: 30px;
    border-radius: 6px;
}

/* Content Wrapper - Flex para que crezca */
.content-wrapper {
    display: flex;
    flex-direction: column;
    padding: 40px 0;
    background: white;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

/* Main Container */
.main-container {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    margin: auto;
    max-width: 1200px;
    padding: 50px;
    width: 95%;
}

/* Footer Fijo */
.footer-custom {
    background: var(--primary-color);
    color: white;
    text-align: center;
    padding: 30px 0;
    margin-top: auto;
}

.footer-custom p {
    margin: 5px 0;
    opacity: 0.9;
}

/* Formularios */
.form-section {
    background: linear-gradient(90deg,rgba(106, 180, 217, 1) 0%, rgba(52, 144, 206, 1) 70%, rgba(46, 89, 122, 1) 100%);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    margin-top: -20px;   /* AGREGADO: Eliminar margen superior para acercarse al header */
}

.form-title {
    color: white;
    font-weight: 700;
    font-size: 2rem;
    margin-bottom: 10px;
    text-align: center;
}

.form-subtitle {
    color: rgba(255, 255, 255, 0.95);
    text-align: center;
    margin-bottom: 30px;
    font-size: 1rem;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    font-weight: 600;
    color: #1e3c72;
    margin-bottom: 8px;
    display: block;
    font-size: 0.95rem;
}

/* AGREGADO: Etiqueta para hijos */
.form-label-hijo {
    font-weight: 600;
    color: #1e3c72;
    margin-bottom: 8px;
    display: block;
    font-size: 0.95rem;
}

.form-control, .form-select {
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 12px 15px;
    font-size: 1rem;
    transition: all 0.3s ease;
    width: 100%;
    background-color: white;
}

.form-control:focus, .form-select:focus {
    border-color: #1e3c72;
    box-shadow: 0 0 0 0.2rem rgba(30, 60, 114, 0.25);
    outline: none;
}

.form-control::placeholder {
    color: #999;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.btn-submit {
    background: linear-gradient(90deg, #c41e3a 0%, #a23b72 100%);
    color: white;
    border: none;
    padding: 14px 40px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1.05rem;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    margin-top: 20px;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-submit:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(196, 30, 58, 0.4);
    color: white;
    text-decoration: none;
}

.btn-submit:active {
    transform: translateY(-1px);
}

.btn-reset {
    background: #ecf0f1;
    color: #2c3e50;
    border: 2px solid #bdc3c7;
    padding: 12px 30px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
    margin-left: 10px;
}

.btn-reset:hover {
    background: #bdc3c7;
    color: white;
}

.alert-info {
    background: #e8f0f8;
    border: 2px solid #1e3c72;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 25px;
    color: #1e3c72;
}

.button-group {
    display: flex;
    gap: 10px;
    margin-top: 30px;
}

.alert-success {
    background: #d4edda;
    border: 2px solid #28a745;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 25px;
    color: #155724;
}

.button-group {
    display: flex;
    gap: 10px;
    margin-top: 30px;
}

.button-group .btn-submit {
    flex: 1;
    margin: 0;
}

.button-group .btn-reset {
    margin: 0;
    flex: 0.3;
}


/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .main-container {
        padding: 30px;
        width: 98%;
    }

    .form-section {
        padding: 30px 20px;
    }

    .carousel-section {
        min-height: 300px;
    }

    .carousel-item-content img {
        object-fit: cover;
    }

    .carousel-container {
        height: 250px;
    }

    .carousel-title {
        font-size: 1.4rem;
    }

    .carousel-description {
        font-size: 0.9rem;
    }

    .carousel-btn {
        font-size: 1.5rem;
        padding: 5px 10px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .button-group {
        flex-direction: column;
    }

    .button-group .btn-reset {
        flex: 1;
        margin: 10px 0 0 0;
    }

    .navbar-brand {
        font-size: 1.2rem;
    }

    .nav-link {
        margin: 0 8px;
    }
}

/* --- Efecto Hover para el Submenú --- */
@media (min-width: 992px) {
    .dropdown-hover:hover > .dropdown-menu {
        display: block;
        margin-top: 0; /* Evita que se cierre al mover el mouse al menú */
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .dropdown-menu-custom {
        display: block;
        opacity: 0;
        visibility: hidden;
        transform: translateY(10px);
        transition: all 0.3s ease-in-out;
        border: none;
        box-shadow: 0px 8px 15px rgba(0, 0, 0, 0.1);
        border-radius: 10px;
        padding: 10px 0;
    }
}

/* --- Estilo Profesional del Submenú --- */
.dropdown-item {
    padding: 10px 20px;
    font-weight: 500;
    color: #4a5568;
    transition: all 0.2s;
    display: flex;
    align-items: center;
}

.dropdown-item i {
    width: 20px;
    margin-right: 10px;
    color: #4c51bf; /* Color Indigo que usamos antes */
}

.dropdown-item:hover {
    background-color: #f7fafc;
    color: #4c51bf;
    padding-left: 25px; /* Pequeño efecto de desplazamiento */
}

.dropdown-divider {
    border-top: 1px solid #edf2f7;
    margin: 5px 0;
}

/* Quitar la flechita del dropdown si prefieres un look más limpio */
.dropdown-toggle::after {
    vertical-align: middle;
    margin-left: 5px;
}


/* ===== FORM VALIDATION ===== */
.is-invalid {
    border-color: #dc3545 !important;
}

.invalid-feedback {
    color: #dc3545;
    font-size: 0.875rem;
    display: block;
    margin-top: 5px;
}


/* Contenedor de cada hijo */
.hijo-container {
    background: white;
    border: 2px solid;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* Título del hijo (Color personalizado) */
.hijo-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    border-bottom: 2px solid #edf2f7;
    padding-bottom: 10px;
}

.hijo-title {
    color: #1e3c72; /* Color Indigo */
    font-weight: 700;
    font-size: 1.1rem;
    text-transform: uppercase;
}

/* Inputs de Archivo al 100% */
.file-input-wrapper {
    position: relative;
    width: 100%; /* Asegura el ancho total de la columna */
}

.form-control-file {
    width: 100%;
    height: calc(2.25rem + 2px);
    padding: 6px 12px;
    background-color: #fff;
    border: 1px solid #cbd5e0;
    border-radius: 6px;
}

/* Badge a la derecha */
.file-badge {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: #c41e3a; /* Verde Esmeralda */
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    pointer-events: none;
}

/* BOTÓN AGREGAR HIJO (Paleta Nueva) */
.btn-add-dynamic {
    width: 100%;
    background-color: #1e3c72;
    color: white;
    border: 2px dashed #1e3c72;
    padding: 12px;
    border-radius: 10px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 20px;
    margin-bottom: 30px;
}

.btn-add-dynamic:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(52, 144, 206, 1);
}

.btn-add-dynamic i {
    margin-right: 5px;
}

/* Errores */
.error-msg {
    color: #e53e3e;
    font-size: 0.8rem;
    margin-top: 4px;
    display: block;
}

/* AGREGADO AL FINAL DE layouts.css */

/* ===== SECCIÓN SEGUNDO APODERADO ===== */
.segundo-apoderado-section {
    /* COMENTARIO: Fondo gris claro para diferenciarlo */
    background: #f8f9fa;
    /* COMENTARIO: Borde rojo en la izquierda */
    border-left: 4px solid #c41e3a;
    border-radius: 8px;
    /* COMENTARIO: Espaciado interno */
    padding: 20px;
    /* COMENTARIO: Margen superior e inferior */
    margin: 20px 0;
}

.segundo-apoderado-section h4 {
    /* COMENTARIO: Color azul marino igual que otros títulos */
    color: #1e3c72;
    font-weight: 700;
    font-size: 1.1rem;
    /* COMENTARIO: Espaciado inferior */
    margin-bottom: 20px;
}

.btn-outline-danger {
    /* COMENTARIO: Botón para cancelar/cerrar segundo apoderado */
    color: #c41e3a;
    border: 2px solid #c41e3a;
    background: white;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-outline-danger:hover {
    background: #c41e3a;
    color: white;
}

/* AGREGADO: Badge con color verde para archivo válido */
.file-badge.success {
    background: #28a745;
}

.file-badge.error {
    background: #c41e3a;
}

/* AGREGADO: Transición suave para archivo cargado */
.file-input-wrapper .file-badge {
    animation: slideIn 0.3s ease-in-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* COMENTARIO: Estilos para la sección de apoderado encontrado */
.apoderado-encontrado-section {
    animation: slideIn 0.3s ease-in-out;
}

/* ========== AGREGAR AL FINAL DE layout.css ========== */

/* COMENTARIO: Padding-top solo cuando hay navbar (no en login) */
body:not(.no-navbar) {
    padding-top: 65px;
}

/* COMENTARIO: Clase para deshabilitar navbar en páginas específicas */
body.no-navbar {
    padding-top: 0;
}

/* COMENTARIO: Asegurar que el contenido principal tenga flex 1 */
#app {
    display: block; /* 🔥 clave */
    min-height: auto;
}

.content-wrapper {
    flex: 1;
}

/* ...existing code... */

/* ========== MODAL DE ÉXITO (PROFESIONAL Y RESPONSIVO) ========== */

/* COMENTARIO: Overlay oscuro que cubre toda la pantalla */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    /* COMENTARIO: Fondo oscuro semi-transparente */
    background: rgba(0, 0, 0, 0.75);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    /* COMENTARIO: Animación de entrada suave */
    animation: fadeIn 0.3s ease-in-out;
    /* COMENTARIO: Prevenir scroll cuando modal está abierto */
    overflow: hidden;
}

/* COMENTARIO: Animación fade in para el overlay */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* COMENTARIO: Contenedor principal del modal */
.modal-container {
    background: white;
    border-radius: 15px;
    /* COMENTARIO: Sombra profesional */
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
    max-width: 500px;
    width: 90%;
    /* COMENTARIO: Animación de entrada */
    animation: slideUp 0.4s ease-in-out;
    overflow: hidden;
    /* COMENTARIO: Asegurar que no sobresalga del padding */
    max-height: 90vh;
    overflow-y: auto;
}

/* COMENTARIO: Animación slide up para el modal */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* COMENTARIO: Header del modal con gradiente verde profesional */
.modal-header {
    /* COMENTARIO: Gradiente verde con dos tonos */
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    padding: 30px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: none;
}

/* COMENTARIO: Título del modal con ícono */
.modal-title {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
    letter-spacing: 0.5px;
}

.modal-title i {
    font-size: 1.8rem;
    /* COMENTARIO: Animación de pulsación del ícono */
    animation: pulse 2s infinite;
}

/* COMENTARIO: Animación de pulsación para el ícono del modal */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* COMENTARIO: Botón para cerrar el modal (X) */
.modal-close-btn {
    background: rgba(255, 255, 255, 0.25);
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 6px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close-btn:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: scale(1.15) rotate(90deg);
}

.modal-close-btn:active {
    transform: scale(0.95) rotate(90deg);
}

/* COMENTARIO: Cuerpo del modal con mensajes de confirmación */
.modal-body {
    padding: 45px 30px;
    text-align: center;
}

/* COMENTARIO: Ícono grande de éxito */
.modal-success-icon {
    font-size: 4rem;
    color: #28a745;
    margin-bottom: 20px;
    /* COMENTARIO: Animación de bounce */
    animation: bounce 0.8s ease-in-out;
}

/* COMENTARIO: Animación de bounce para el ícono de éxito */
@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

/* COMENTARIO: Mensaje principal del modal */
.modal-message {
    font-size: 1.3rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 15px;
    line-height: 1.5;
    letter-spacing: 0.3px;
}

/* COMENTARIO: Mensaje secundario/subtítulo */
.modal-submessage {
    font-size: 1rem;
    color: #7f8c8d;
    margin: 0;
    line-height: 1.6;
    opacity: 0.9;
}

/* COMENTARIO: Footer del modal con botón de cierre */
.modal-footer {
    background: #f8f9fa;
    padding: 20px 30px;
    display: flex;
    justify-content: center;
    border-top: 1px solid #e9ecef;
}

/* COMENTARIO: Botón de cerrar en el footer */
.btn-modal-close {
    /* COMENTARIO: Gradiente verde profesional */
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    border: none;
    padding: 12px 45px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.2);
}

.btn-modal-close:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.4);
}

.btn-modal-close:active {
    transform: translateY(-1px);
}

/* COMENTARIO: Media query para responsivo en pantallas pequeñas */
@media (max-width: 600px) {
    /* COMENTARIO: Modal más compacto en móviles */
    .modal-container {
        width: 95%;
        margin: 20px;
    }

    /* COMENTARIO: Reducir padding del header en móviles */
    .modal-header {
        padding: 25px 20px;
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }

    /* COMENTARIO: Reducir tamaño de título en móviles */
    .modal-title {
        font-size: 1.3rem;
    }

    /* COMENTARIO: Reducir padding del body en móviles */
    .modal-body {
        padding: 30px 20px;
    }

    /* COMENTARIO: Reducir tamaño del ícono de éxito */
    .modal-success-icon {
        font-size: 3rem;
        margin-bottom: 15px;
    }

    /* COMENTARIO: Ajustar tamaño de mensaje en móviles */
    .modal-message {
        font-size: 1.1rem;
    }

    .modal-submessage {
        font-size: 0.95rem;
    }

    /* COMENTARIO: Reducir padding del footer en móviles */
    .modal-footer {
        padding: 15px 20px;
    }

    /* COMENTARIO: Botón más ancho en móviles */
    .btn-modal-close {
        width: 100%;
        padding: 12px 30px;
        font-size: 0.95rem;
    }

    /* COMENTARIO: Botón para cerrar más accesible en móviles */
    .modal-close-btn {
        font-size: 1.3rem;
        padding: 6px 10px;
    }
}

/* COMENTARIO: Media query para pantallas muy pequeñas */
@media (max-width: 400px) {
    .modal-container {
        width: 98%;
    }

    .modal-header {
        padding: 20px 15px;
    }

    .modal-title {
        font-size: 1.1rem;
        gap: 8px;
    }

    .modal-title i {
        font-size: 1.5rem;
    }

    .modal-body {
        padding: 25px 15px;
    }

    .modal-success-icon {
        font-size: 2.5rem;
    }

    .modal-message {
        font-size: 1rem;
    }

    .modal-submessage {
        font-size: 0.9rem;
    }
}



/* ...existing code... */