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

body {
    font-family: 'Inter', 'Segoe UI', sans-serif;
    color: #1f2933;
    background-color: #f8fafc;
    line-height: 1.6;
}

/* UTILIDADES */
.container {
    max-width: 1100px;
    margin: auto;
    padding: 0 1.2rem;
}

h1, h2, h3 {
    font-weight: 600;
}

a {
    text-decoration: none;
    color: inherit;
}

/* HEADER */
.header {
    background: #0f172a;
    color: #fff;
}

.header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.logo {
    font-size: 1.4rem;
    font-weight: 700;
}

.logo span {
    color: #38bdf8;
}

.nav {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav a {
    font-size: 0.95rem;
    transition: color 0.2s;
}

.nav a:hover {
    color: #38bdf8;
}

.nav-form {
    display: inline;
    margin-left: 0;
}

.btn-outline {
    padding: 0.4rem 0.9rem;
    border: 1px solid #38bdf8;
    border-radius: 6px;
    background: transparent;
    color: #38bdf8;
    cursor: pointer;
    font-size: 0.95rem;
    transition: background 0.2s, color 0.2s;
}

.btn-outline:hover {
    background: rgba(56, 189, 248, 0.1);
}

/* Menú hamburguesa */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 30px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
}

.menu-toggle span {
    width: 100%;
    height: 3px;
    background: #fff;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.menu-toggle-active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.menu-toggle-active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle-active span:nth-child(3) {
    transform: rotate(-45deg) translate(8px, -8px);
}

/* HERO */
.hero {
    background: linear-gradient(135deg, #0f172a, #020617);
    color: #fff;
    padding: 4rem 0;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.hero-text h1 {
    font-size: 2.4rem;
    margin-bottom: 1rem;
}

.hero-text p {
    color: #cbd5e1;
    margin-bottom: 1.5rem;
}

.colegio-nombre {
    font-size: 1.3rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.02em;
    margin-top: 0.5rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.btn-primary {
    background: #38bdf8;
    color: #020617;
    padding: 0.7rem 1.4rem;
    border-radius: 8px;
    font-weight: 500;
    display: inline-block;
    transition: background 0.2s, transform 0.1s;
}

.btn-primary:hover {
    background: #0ea5e9;
    transform: translateY(-1px);
}

.btn-secondary {
    background: transparent;
    color: #ffffff;
    padding: 0.7rem 1.4rem;
    border-radius: 8px;
    font-weight: 500;
    border: 2px solid #ffffff;
    display: inline-block;
    transition: background 0.2s, border-color 0.2s, transform 0.1s;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #38bdf8;
    transform: translateY(-1px);
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1.5rem;
}

/* MOCKUP */
.hero-visual {
    display: flex;
    justify-content: center;
}

.mockup {
    background: #020617;
    border: 2px solid #38bdf8;
    padding: 2rem;
    border-radius: 12px;
    font-family: monospace;
    color: #38bdf8;
}

/* FEATURES */
.features {
    padding: 4rem 0;
}

.features h2 {
    text-align: center;
    margin-bottom: 2.5rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.feature-card {
    background: #fff;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.04);
}

/* HOW */
.how {
    background: #f1f5f9;
    padding: 4rem 0;
}

.how h2 {
    text-align: center;
    margin-bottom: 2rem;
}

.steps {
    max-width: 600px;
    margin: auto;
}

.steps li {
    display: flex;
    align-items: center;
    margin-bottom: 1.2rem;
}

.steps span {
    background: #0f172a;
    color: #fff;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
}

/* CTA */
.cta {
    background: #020617;
    color: #fff;
    text-align: center;
    padding: 4rem 0;
}

.cta p {
    margin: 1rem 0 1.5rem;
    color: #cbd5e1;
}

/* FOOTER */
.footer {
    background: #020617;
    color: #64748b;
    text-align: center;
    padding: 1rem 0;
    font-size: 0.85rem;
}

/* RESPONSIVE */
@media (max-width: 900px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .features-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    /* Menú hamburguesa */
    .menu-toggle {
        display: flex;
    }

    .nav {
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        background: #0f172a;
        flex-direction: column;
        align-items: flex-start;
        padding: 1.5rem;
        gap: 1rem;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        z-index: 1000;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }

    .nav-active {
        transform: translateX(0);
    }

    .nav a {
        margin-left: 0;
        padding: 0.75rem 0;
        width: 100%;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .nav a:last-child {
        border-bottom: none;
    }

    .nav-form {
        width: 100%;
        margin-top: 0.5rem;
    }

    .nav-form .btn-outline {
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 600px) {
    .features-grid {
        grid-template-columns: 1fr;
    }

    /* Hero responsive */
    .hero {
        padding: 2rem 0;
    }

    .hero-text h1 {
        font-size: 1.8rem;
        margin-bottom: 0.8rem;
    }

    .colegio-nombre {
        font-size: 1.1rem;
        margin-top: 0.3rem;
    }

    /* Hero buttons responsive */
    .hero-buttons {
        flex-direction: column;
        gap: 0.8rem;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
        text-align: center;
        padding: 0.85rem 1.4rem;
    }

    /* Container responsive */
    .container {
        padding: 0 1rem;
    }

    /* Form section responsive */
    .form-section {
        padding: 2rem 0;
    }

    /* Form card responsive */
    .form-card {
        padding: 1.5rem;
        margin: 0 0.5rem;
        border-radius: 12px;
    }

    /* Form inputs responsive */
    .input {
        padding: 0.75rem;
        font-size: 1rem;
    }

    /* Button responsive */
    .form-registro .btn-primary {
        padding: 0.85rem 1.4rem;
        font-size: 1rem;
        margin-top: 0.3rem;
    }
}
/* ===========================
   FORMULARIOS ESCOLAR CONECTA
=========================== */

.form-card {
    max-width: 520px;
    margin: 0 auto;
    background: #ffffff;
    padding: 2rem;
    border-radius: 14px;
    box-shadow: 0 20px 35px rgba(0,0,0,0.08);
}

.form-title {
    font-size: 1.4rem;
    margin-bottom: 0.3rem;
    color: #020617;
}

.form-subtitle {
    font-size: 0.9rem;
    color: #64748b;
    margin-bottom: 1.5rem;
}

.form {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.form-group label {
    font-size: 0.85rem;
    font-weight: 500;
    color: #334155;
}

.form-input {
    padding: 0.65rem 0.75rem;
    border-radius: 8px;
    border: 1px solid #cbd5e1;
    font-size: 0.95rem;
    transition: border 0.2s, box-shadow 0.2s;
}

.form-input:focus {
    outline: none;
    border-color: #38bdf8;
    box-shadow: 0 0 0 2px rgba(56,189,248,0.25);
}

.uppercase {
    text-transform: uppercase;
}

.form-divider {
    border: none;
    border-top: 1px solid #e5e7eb;
    margin: 1rem 0;
}

.form-btn {
    margin-top: 0.5rem;
    width: 100%;
}

.form-error {
    font-size: 0.85rem;
    color: #dc2626;
    margin-top: 0.25rem;
    display: block;
    line-height: 1.4;
}

.input-error {
    border-color: #dc2626 !important;
    box-shadow: 0 0 0 2px rgba(220, 38, 38, 0.15) !important;
}

.input-error:focus {
    border-color: #dc2626 !important;
    box-shadow: 0 0 0 2px rgba(220, 38, 38, 0.25) !important;
}

.form-success {
    background: #d1fae5;
    color: #065f46;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    border-left: 4px solid #10b981;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-section {
    padding: 3rem 0;
    background: #f8fafc;
}

.input {
    padding: 0.65rem 0.75rem;
    border-radius: 8px;
    border: 1px solid #cbd5e1;
    font-size: 0.95rem;
    transition: border 0.2s, box-shadow 0.2s;
    width: 100%;
}

.input:focus {
    outline: none;
    border-color: #38bdf8;
    box-shadow: 0 0 0 2px rgba(56,189,248,0.25);
}

textarea.input {
    resize: vertical;
    min-height: 80px;
    font-family: inherit;
}

.form-registro {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
    margin-top: 0;
}

.form-registro .btn-primary {
    margin-top: 0.5rem;
    width: 100%;
    cursor: pointer;
    background: #0F4B6B;
    color: #ffffff;
    border: none;
    transition: background 0.2s;
}

.form-registro .btn-primary:hover {
    background: #0d3d57;
}

/* ===========================
   ESTILOS PARA ESTUDIANTES
=========================== */

.estudiantes-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.btn-agregar-estudiante {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
    background: #0F4B6B;
    color: #ffffff;
    border: none;
    transition: background 0.2s;
}

.btn-agregar-estudiante:hover {
    background: #0d3d57;
}

.estudiantes-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.estudiante-card {
    background: #fff;
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.estudiante-info {
    flex: 1;
}

.estudiante-nombre {
    color: #0f172a;
    font-weight: 600;
    margin: 0 0 0.25rem 0;
}

.estudiante-documento {
    color: #64748b;
    font-size: 0.9rem;
    margin: 0;
}

.estudiante-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.btn-editar-estudiante {
    padding: 0.4rem 0.8rem;
    font-size: 0.85rem;
    background: #0F4B6B;
    color: #ffffff;
    border: none;
    transition: background 0.2s;
}

.btn-editar-estudiante:hover {
    background: #0d3d57;
}

.btn-eliminar-estudiante {
    padding: 0.4rem 0.8rem;
    font-size: 0.85rem;
    background: #dc2626;
    color: #ffffff;
    border: 1px solid #dc2626;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
}

.btn-eliminar-estudiante:hover {
    background: #b91c1c;
    border-color: #b91c1c;
}

.estudiante-form-container {
    background: #f8fafc;
    padding: 1.5rem;
    border-radius: 10px;
    margin-top: 1.5rem;
    border: 1px solid #e5e7eb;
}

.estudiante-form-title {
    color: #0f172a;
    margin-bottom: 1rem;
}

.estudiante-form {
    gap: 1rem;
}

.estudiante-form-buttons {
    display: flex;
    gap: 0.5rem;
}

.estudiante-form-buttons button {
    flex: 1;
}

.btn-cancelar {
    background: #f1f5f9;
    color: #0f172a;
    border: 1px solid #cbd5e1;
}

/* Mejoras móviles para panel de estudiantes */
@media (max-width: 600px) {
    /* Hero más compacto */
    .hero {
        padding: 1.5rem 0;
    }

    .hero-text h1 {
        font-size: 1.6rem;
        margin-bottom: 0.6rem;
    }

    .colegio-nombre {
        font-size: 1rem;
        margin-top: 0.3rem;
    }

    /* Container más ajustado */
    .container {
        padding: 0 0.75rem;
    }

    /* Form section más compacto */
    .form-section {
        padding: 1.5rem 0;
    }

    /* Form card optimizado para móvil */
    .form-card {
        padding: 1.25rem;
        margin: 0;
        border-radius: 12px;
        max-width: 100%;
    }

    .form-card h2 {
        font-size: 1.3rem;
        margin-bottom: 1rem;
    }

    /* Header de estudiantes en móvil */
    .estudiantes-header {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }

    .estudiantes-header h3 {
        text-align: center;
        margin-bottom: 0;
        font-size: 1.1rem;
    }

    .btn-agregar-estudiante {
        width: 100%;
        padding: 0.75rem !important;
    }

    /* Cards de estudiantes en móvil */
    .estudiante-card {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
        padding: 1rem;
    }

    .estudiante-info {
        width: 100%;
    }

    .estudiante-actions {
        width: 100%;
        flex-direction: column;
        gap: 0.5rem;
    }

    .btn-editar-estudiante,
    .btn-eliminar-estudiante {
        width: 100%;
        padding: 0.75rem !important;
    }

    /* Formulario de estudiantes en móvil */
    .estudiante-form-container {
        padding: 1.25rem !important;
        margin-top: 1.25rem !important;
    }

    .estudiante-form-title {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
    }

    .estudiante-form-buttons {
        flex-direction: column;
    }

    .estudiante-form-buttons button {
        width: 100%;
    }

    /* Inputs más grandes para móvil (evita zoom en iOS) */
    .input {
        padding: 0.75rem;
        font-size: 16px;
    }
}


