/* ============================
   SchoolOS - Role Selection Page
   Glassmorphism Full Page
   ============================ */

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

body.role-page {
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 30%, #2563eb 60%, #1e40af 100%);
    color: #fff;
    overflow-x: hidden;
}

/* Background animated circles */
body.role-page::before,
body.role-page::after {
    content: '';
    position: fixed;
    border-radius: 50%;
    opacity: 0.07;
    z-index: 0;
}

body.role-page::before {
    width: 600px;
    height: 600px;
    background: #fff;
    top: -150px;
    right: -100px;
    animation: roleFloat 8s ease-in-out infinite;
}

body.role-page::after {
    width: 400px;
    height: 400px;
    background: #fff;
    bottom: -100px;
    left: -80px;
    animation: roleFloat 10s ease-in-out infinite reverse;
}

@keyframes roleFloat {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-30px) scale(1.05); }
}

/* Header */
.role-header {
    text-align: center;
    padding: 40px 20px 10px;
    position: relative;
    z-index: 1;
}

.role-header .logo-icon {
    width: 90px;
    height: 90px;
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 38px;
    color: #fff;
    animation: rolePulse 3s ease-in-out infinite;
}

@keyframes rolePulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255,255,255,0.2); }
    50% { box-shadow: 0 0 0 20px rgba(255,255,255,0); }
}

.role-header h1 {
    font-size: 42px;
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 8px;
}

.role-header p {
    font-size: 16px;
    opacity: 0.8;
    font-weight: 300;
}

/* Main content */
.role-main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px 20px;
    position: relative;
    z-index: 1;
}

.role-content {
    width: 100%;
    max-width: 1100px;
    text-align: center;
}

.role-content h2 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 8px;
    opacity: 0.95;
}

.role-content .subtitle {
    font-size: 14px;
    opacity: 0.6;
    margin-bottom: 35px;
}

/* Role Grid */
.role-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.role-card {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 20px;
    padding: 40px 20px;
    text-decoration: none;
    color: #fff;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.role-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, transparent 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.role-card:hover {
    transform: translateY(-10px) scale(1.03);
    border-color: rgba(255,255,255,0.4);
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
}

.role-card:hover::before {
    opacity: 1;
}

.role-card .card-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    margin-bottom: 20px;
    transition: transform 0.3s ease;
    position: relative;
    z-index: 1;
}

.role-card:hover .card-icon {
    transform: scale(1.15);
}

.role-card .card-name {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 6px;
    position: relative;
    z-index: 1;
}

.role-card .card-desc {
    font-size: 12px;
    opacity: 0.7;
    position: relative;
    z-index: 1;
}

.role-card .card-arrow {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 20px;
    font-size: 14px;
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
}

.role-card:hover .card-arrow {
    background: rgba(255,255,255,0.3);
    transform: translateX(3px);
}

/* Role colors */
.role-org .card-icon { background: linear-gradient(135deg, #8b5cf6, #7c3aed); }
.role-super-admin .card-icon { background: linear-gradient(135deg, #ef4444, #dc2626); }
.role-admin .card-icon { background: linear-gradient(135deg, #3b82f6, #2563eb); }
.role-teacher .card-icon { background: linear-gradient(135deg, #22c55e, #16a34a); }
.role-student .card-icon { background: linear-gradient(135deg, #f59e0b, #d97706); }
.role-staff .card-icon { background: linear-gradient(135deg, #06b6d4, #0891b2); }

.role-org:hover { background: rgba(139, 92, 246, 0.15); }
.role-super-admin:hover { background: rgba(239, 68, 68, 0.15); }
.role-admin:hover { background: rgba(59, 130, 246, 0.15); }
.role-teacher:hover { background: rgba(34, 197, 94, 0.15); }
.role-student:hover { background: rgba(245, 158, 11, 0.15); }
.role-staff:hover { background: rgba(6, 182, 212, 0.15); }

/* Footer */
.role-footer {
    text-align: center;
    padding: 25px 20px 30px;
    position: relative;
    z-index: 1;
}

.role-footer p {
    font-size: 12px;
    opacity: 0.5;
    margin: 0;
}

/* Responsive */
@media (max-width: 992px) {
    .role-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .role-header h1 {
        font-size: 32px;
    }
}

@media (max-width: 768px) {
    .role-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    .role-card {
        padding: 30px 15px;
    }
    .role-card .card-icon {
        width: 65px;
        height: 65px;
        font-size: 26px;
    }
    .role-header {
        padding: 25px 20px 5px;
    }
    .role-header .logo-icon {
        width: 70px;
        height: 70px;
        font-size: 30px;
    }
    .role-header h1 {
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .role-grid {
        grid-template-columns: 1fr;
        max-width: 280px;
        margin: 0 auto;
    }
}
