/* students.css */
@keyframes addStudentCardEnter {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

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

#studentPage .card.add-student-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 107, 53, 0.18);
    border-radius: var(--radius-lg);
    background:
        linear-gradient(180deg, rgba(255, 245, 236, 0.95) 0%, #ffffff 48%),
        radial-gradient(circle at 85% 0%, rgba(78, 205, 196, 0.18), transparent 50%),
        radial-gradient(circle at 15% 85%, rgba(255, 230, 109, 0.2), transparent 55%);
    box-shadow: 0 16px 40px rgba(255, 107, 53, 0.12);
    padding: var(--space-xl);
    animation: addStudentCardEnter 0.5s ease both;
}

#studentPage .add-student-card::before {
    content: '';
    position: absolute;
    top: -70px;
    right: -70px;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255, 107, 53, 0.18) 0%, transparent 70%);
    opacity: 0.7;
    pointer-events: none;
}

#studentPage .add-student-card::after {
    content: '';
    position: absolute;
    bottom: -80px;
    left: -80px;
    width: 220px;
    height: 220px;
    background: radial-gradient(circle, rgba(78, 205, 196, 0.18) 0%, transparent 70%);
    opacity: 0.6;
    pointer-events: none;
}

#studentPage .add-student-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-lg);
    flex-wrap: wrap;
    padding-bottom: var(--space-lg);
    margin-bottom: var(--space-lg);
    border-bottom: 1px dashed rgba(255, 107, 53, 0.2);
    position: relative;
    z-index: 1;
}

#studentPage .add-student-title {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

#studentPage .add-student-icon {
    width: 52px;
    height: 52px;
    border-radius: 18px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    box-shadow: 0 12px 24px rgba(255, 107, 53, 0.25);
    flex: 0 0 auto;
}

#studentPage .add-student-title h3 {
    margin: 0;
    padding: 0;
    border: none;
    display: block;
    font-size: 1.6rem;
    font-weight: 800;
}

#studentPage .add-student-subtitle {
    margin-top: 6px;
    color: var(--text-muted);
    font-size: 0.95rem;
}

#studentPage .add-student-badges {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    flex-wrap: wrap;
}

#studentPage .add-student-badge {
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--primary);
    background: rgba(255, 107, 53, 0.12);
    border: 1px solid rgba(255, 107, 53, 0.25);
}

#studentPage .add-student-badge--secondary {
    color: var(--secondary);
    background: rgba(78, 205, 196, 0.12);
    border-color: rgba(78, 205, 196, 0.25);
}

#studentPage .add-student-body {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1.2fr);
    gap: var(--space-lg);
    position: relative;
    z-index: 1;
}

#studentPage .add-student-section {
    --section-accent: var(--primary);
    --section-glow: rgba(255, 107, 53, 0.15);
    background: #ffffff;
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    border: 1px solid rgba(255, 107, 53, 0.14);
    box-shadow: 0 12px 24px rgba(255, 107, 53, 0.08);
    position: relative;
    overflow: hidden;
}

#studentPage .add-student-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: linear-gradient(90deg, var(--section-accent), transparent);
    opacity: 0.7;
}

#studentPage .add-student-section--account {
    --section-accent: var(--secondary);
    --section-glow: rgba(78, 205, 196, 0.18);
    background: #f5fffd;
    border-color: rgba(78, 205, 196, 0.2);
    box-shadow: 0 12px 24px rgba(78, 205, 196, 0.1);
}

#studentPage .add-student-section-head {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-weight: 700;
    color: var(--section-accent);
    margin-bottom: var(--space-md);
    position: relative;
    z-index: 1;
}

#studentPage .add-student-section-icon {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--section-accent), rgba(255, 255, 255, 0.2));
    color: white;
    font-size: 0.95rem;
    box-shadow: 0 8px 16px rgba(15, 23, 42, 0.12);
}

#studentPage .add-student-section-title {
    font-size: 1rem;
    letter-spacing: 0.02em;
}

#studentPage .add-student-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--space-md);
    position: relative;
    z-index: 1;
}

#studentPage .add-student-grid--account {
    grid-template-columns: 1fr;
}

#studentPage .add-student-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    animation: addStudentFieldRise 0.45s ease both;
}

#studentPage .add-student-label {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    font-weight: 700;
}

#studentPage .add-student-label i {
    color: var(--section-accent);
}

#studentPage .add-student-field input {
    font-family: var(--font-body);
    font-size: 1rem;
    padding: 12px 14px;
    border-radius: var(--radius-md);
    border: 2px solid rgba(15, 23, 42, 0.08);
    background: linear-gradient(180deg, #ffffff 0%, #fffaf6 100%);
    color: var(--text-primary);
    width: 100%;
    box-shadow: 0 8px 16px rgba(15, 23, 42, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    transition: border 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

#studentPage .add-student-field input:focus {
    border-color: var(--section-accent);
    box-shadow: 0 0 0 4px var(--section-glow), 0 10px 20px rgba(15, 23, 42, 0.1);
    transform: translateY(-1px);
}

#studentPage .add-student-grid .add-student-field:nth-child(1) { animation-delay: 0.05s; }
#studentPage .add-student-grid .add-student-field:nth-child(2) { animation-delay: 0.1s; }
#studentPage .add-student-grid .add-student-field:nth-child(3) { animation-delay: 0.15s; }
#studentPage .add-student-grid .add-student-field:nth-child(4) { animation-delay: 0.2s; }
#studentPage .add-student-grid--account .add-student-field:nth-child(1) { animation-delay: 0.12s; }
#studentPage .add-student-grid--account .add-student-field:nth-child(2) { animation-delay: 0.2s; }

#studentPage .add-student-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-md);
    margin-top: var(--space-lg);
    padding-top: var(--space-lg);
    border-top: 1px dashed rgba(255, 107, 53, 0.2);
    position: relative;
    z-index: 1;
    flex-wrap: wrap;
}

#studentPage .add-student-btn {
    padding: 14px 32px;
    font-size: 1.05rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 14px 24px rgba(255, 107, 53, 0.25);
}

#studentPage .add-student-hint {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 600;
}

#studentPage .add-student-hint i {
    color: var(--secondary);
}

@media (max-width: 960px) {
    #studentPage .add-student-body {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    #studentPage .add-student-grid {
        grid-template-columns: 1fr;
    }

    #studentPage .add-student-actions {
        flex-direction: column;
        align-items: stretch;
    }

    #studentPage .add-student-btn {
        width: 100%;
        justify-content: center;
    }

    #studentPage .add-student-hint {
        justify-content: center;
        text-align: center;
    }
}
