/* ============================================
   e-Ponpes Imam Bukhari v2
   Design: Simple, Islami, Blue Soft Elegant
   ============================================ */

:root {
    --primary: #4A90D9;
    --primary-dark: #2C6FAD;
    --primary-light: #A8D0F5;
    --primary-lighter: #EDF6FD;
    --secondary: #5BAE8F;
    --accent: #C9A84C;
    --bg-main: #F7FAFD;
    --bg-card: #FFFFFF;
    --text-dark: #1E3A5F;
    --text-body: #3D5A80;
    --text-muted: #8DA4BF;
    --text-light: #FFFFFF;
    --border: #E4EEF6;
    --border-light: #F0F6FB;
    --shadow-xs: 0 1px 3px rgba(74, 144, 217, 0.04);
    --shadow: 0 4px 16px rgba(74, 144, 217, 0.07);
    --shadow-lg: 0 8px 32px rgba(74, 144, 217, 0.10);
    --shadow-xl: 0 16px 48px rgba(74, 144, 217, 0.12);
    --radius: 14px;
    --radius-lg: 20px;
    --radius-sm: 10px;
    --radius-xs: 6px;
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --font-family: 'Inter', 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-arabic: 'Amiri', 'Traditional Arabic', serif;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    background: var(--bg-main);
    color: var(--text-body);
    line-height: 1.65;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-dark);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    color: var(--text-dark);
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

.text-bismillah {
    font-family: var(--font-arabic);
    font-size: 1.5rem;
    color: var(--primary-dark);
    text-align: center;
    margin-bottom: 0.5rem;
}

/* Islamic Geometric Pattern (CSS only) */
.pattern-header {
    position: relative;
    overflow: hidden;
}

.pattern-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 25% 25%, rgba(255,255,255,0.1) 2px, transparent 2px),
        radial-gradient(circle at 75% 75%, rgba(255,255,255,0.08) 2px, transparent 2px),
        radial-gradient(circle at 50% 50%, rgba(255,255,255,0.05) 1px, transparent 1px);
    background-size: 40px 40px, 40px 40px, 20px 20px;
    pointer-events: none;
}

/* Container */
.container {
    max-width: 480px;
    margin: 0 auto;
    padding: 0 1rem;
}

.container-wide {
    max-width: 1024px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Card */
.card {
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-light);
    overflow: hidden;
    transition: var(--transition);
}

.card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-1px);
}

.card-body {
    padding: 1.25rem;
}

.card-header {
    padding: 0.875rem 1.25rem;
    background: linear-gradient(135deg, var(--primary-lighter) 0%, #F8FBFE 100%);
    border-bottom: 1px solid var(--border);
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--primary-dark);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    line-height: 1.2;
    letter-spacing: 0.01em;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--text-light);
    box-shadow: 0 4px 12px rgba(74, 144, 217, 0.25);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, #1E5A8E 100%);
    color: var(--text-light);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(74, 144, 217, 0.35);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 1.5px solid var(--primary-light);
}

.btn-outline:hover {
    background: var(--primary-lighter);
    border-color: var(--primary);
    color: var(--primary-dark);
}

.btn-success {
    background: linear-gradient(135deg, var(--secondary) 0%, #3D9B74 100%);
    color: var(--text-light);
}

.btn-warning {
    background: var(--accent);
    color: var(--text-dark);
}

.btn-block {
    width: 100%;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
    border-radius: var(--radius-xs);
}

.btn-lg {
    padding: 0.9375rem 2rem;
    font-size: 0.9375rem;
    border-radius: var(--radius-sm);
}

/* Form Elements */
.form-group {
    margin-bottom: 1.25rem;
}

.form-label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
    letter-spacing: 0.01em;
}

.form-control {
    width: 100%;
    padding: 0.8125rem 1rem;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 0.9375rem;
    font-family: var(--font-family);
    color: var(--text-dark);
    background: var(--bg-card);
    transition: var(--transition);
    outline: none;
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(74, 144, 217, 0.1);
    background: #FAFCFF;
}

.form-control::placeholder {
    color: var(--text-muted);
    font-weight: 400;
}

.input-icon-wrapper {
    position: relative;
}

.input-icon-wrapper .form-control {
    padding-left: 2.75rem;
}

.input-icon-wrapper .input-icon {
    position: absolute;
    left: 0.875rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 1.125rem;
}

/* Checkbox & Toggle */
.form-check {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-check input[type="checkbox"] {
    width: 1.125rem;
    height: 1.125rem;
    accent-color: var(--primary);
}

/* Login Page */
.login-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    background: 
        radial-gradient(ellipse at top left, rgba(74, 144, 217, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at bottom right, rgba(91, 174, 143, 0.05) 0%, transparent 50%),
        linear-gradient(180deg, #F7FAFD 0%, #FFFFFF 100%);
}

.login-card {
    width: 100%;
    max-width: 420px;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    padding: 2.5rem 2rem;
    border: 1px solid var(--border-light);
}

.login-logo {
    text-align: center;
    margin-bottom: 1.5rem;
}

.login-logo img {
    width: 80px;
    height: 80px;
    object-fit: contain;
}

.login-logo h1 {
    font-size: 1.1875rem;
    color: var(--primary-dark);
    margin-top: 0.75rem;
    letter-spacing: -0.02em;
}

.login-logo .subtitle {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
    font-weight: 400;
}

.login-divider {
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary-light), transparent);
    margin: 1.5rem 0;
    border-radius: 1px;
}

/* Alert Messages */
.alert {
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.8125rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: flex-start;
    gap: 0.625rem;
    line-height: 1.5;
}

.alert i {
    flex-shrink: 0;
    margin-top: 1px;
}

.alert-error {
    background: #FEF2F2;
    color: #B91C1C;
    border: 1px solid #FECACA;
}

.alert-success {
    background: #F0FDF4;
    color: #15803D;
    border: 1px solid #BBF7D0;
}

.alert-info {
    background: var(--primary-lighter);
    color: var(--primary-dark);
    border: 1px solid var(--primary-light);
}

.alert-warning {
    background: #FFFBEB;
    color: #B45309;
    border: 1px solid #FDE68A;
}

/* App Shell - Header */
.app-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: var(--primary);
    color: var(--text-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.125rem;
    z-index: 1000;
    box-shadow: 0 2px 12px rgba(44, 111, 173, 0.2);
}

.app-header.pattern-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
}

.app-header .title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-light);
    letter-spacing: -0.01em;
}

.app-header .header-btn {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--text-light);
    background: rgba(255,255,255,0.12);
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.app-header .header-btn:hover {
    background: rgba(255,255,255,0.22);
    transform: scale(1.05);
}

.app-header .badge {
    position: absolute;
    top: -3px;
    right: -3px;
    background: #EF4444;
    color: white;
    font-size: 0.5625rem;
    padding: 2px 5px;
    border-radius: 10px;
    min-width: 16px;
    text-align: center;
    font-weight: 700;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
}

/* App Content */
.app-content {
    padding-top: 60px;
    padding-bottom: 76px;
    min-height: 100vh;
}

/* Bottom Navigation */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 68px;
    background: var(--bg-card);
    border-top: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: space-around;
    z-index: 1000;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.04);
    backdrop-filter: blur(10px);
}

.bottom-nav .nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    color: var(--text-muted);
    font-size: 0.625rem;
    font-weight: 500;
    text-decoration: none;
    padding: 0.5rem 0.75rem;
    transition: var(--transition);
    position: relative;
    border-radius: var(--radius-xs);
}

.bottom-nav .nav-item.active,
.bottom-nav .nav-item:hover {
    color: var(--primary);
}

.bottom-nav .nav-item .nav-icon {
    font-size: 1.375rem;
    transition: var(--transition);
}

.bottom-nav .nav-item.active .nav-icon {
    transform: scale(1.1);
}

.bottom-nav .nav-item.active::after {
    content: '';
    position: absolute;
    top: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 28px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--primary-dark));
    border-radius: 0 0 4px 4px;
}

/* Menu Grid */
.menu-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
    padding: 1rem 0;
}

.menu-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 1rem 0.375rem;
    border-radius: var(--radius);
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    transition: var(--transition);
    text-decoration: none;
    color: var(--text-body);
    position: relative;
    overflow: hidden;
}

.menu-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-light), var(--primary));
    opacity: 0;
    transition: var(--transition);
}

.menu-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
    border-color: var(--primary-light);
    color: var(--primary-dark);
}

.menu-item:hover::before {
    opacity: 1;
}

.menu-item .menu-icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: var(--primary-lighter);
    color: var(--primary);
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    transition: var(--transition);
}

.menu-item:hover .menu-icon {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--text-light);
    transform: scale(1.05);
}

.menu-item .menu-label {
    font-size: 0.6875rem;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: 0.01em;
}

/* Student Card */
.student-card {
    display: flex;
    gap: 1rem;
    padding: 1rem 1.125rem;
    border-radius: var(--radius);
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    transition: var(--transition);
    align-items: center;
}

.student-card:hover {
    box-shadow: var(--shadow);
    border-color: var(--primary-light);
    transform: translateX(4px);
}

.student-card .student-photo {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary-lighter);
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(74, 144, 217, 0.1);
}

.student-card .student-info {
    flex: 1;
    min-width: 0;
}

.student-card .student-name {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.student-card .student-detail {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 0.125rem;
    line-height: 1.5;
}

/* Section */
.section-title {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    letter-spacing: 0.01em;
}

.section-title .title-icon {
    color: var(--primary);
    font-size: 1.0625rem;
}

/* Sidebar / Offcanvas */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(30, 58, 95, 0.5);
    backdrop-filter: blur(3px);
    z-index: 1100;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
}

.sidebar {
    position: fixed;
    top: 0;
    left: -300px;
    width: 300px;
    height: 100%;
    background: var(--bg-card);
    z-index: 1200;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
}

.sidebar.active {
    transform: translateX(300px);
}

.sidebar-header {
    padding: 1.75rem 1.5rem 1.25rem;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--text-light);
    position: relative;
}

.sidebar-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--accent), var(--primary-light));
}

.sidebar-header .user-name {
    font-size: 1rem;
    font-weight: 700;
    margin-top: 0.75rem;
}

.sidebar-header .user-info {
    font-size: 0.8125rem;
    opacity: 0.8;
    font-weight: 400;
}

.sidebar-menu {
    padding: 0.75rem 0 2rem;
}

.sidebar-menu .menu-section-title {
    padding: 0.75rem 1.5rem 0.375rem;
    font-size: 0.625rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
}

.sidebar-menu .menu-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.6875rem 1.5rem;
    color: var(--text-body);
    text-decoration: none;
    transition: var(--transition);
    font-size: 0.8125rem;
    font-weight: 500;
    border-left: 3px solid transparent;
}

.sidebar-menu .menu-link:hover {
    background: var(--primary-lighter);
    color: var(--primary-dark);
    border-left-color: var(--primary);
}

.sidebar-menu .menu-link .link-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: var(--primary-lighter);
    color: var(--primary);
    font-size: 0.9375rem;
    transition: var(--transition);
}

.sidebar-menu .menu-link:hover .link-icon {
    background: var(--primary);
    color: white;
}

/* Loading Spinner */
.loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(247, 250, 253, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: var(--transition);
    backdrop-filter: blur(4px);
}

.loader-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.spinner {
    width: 36px;
    height: 36px;
    border: 3px solid var(--primary-lighter);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Utilities */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-muted { color: var(--text-muted); }
.text-primary { color: var(--primary); }
.text-success { color: var(--secondary); }
.text-danger { color: #DC2626; }
.text-sm { font-size: 0.8125rem; }
.text-xs { font-size: 0.6875rem; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }

.d-flex { display: flex; }
.flex-col { flex-direction: column; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }

.w-full { width: 100%; }
.rounded { border-radius: var(--radius); }
.hidden { display: none; }

/* Islamic ornament divider */
.divider-ornament {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 1.5rem 0;
}

.divider-ornament::before,
.divider-ornament::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border), var(--primary-light), var(--border), transparent);
}

.divider-ornament .ornament-icon {
    color: var(--accent);
    font-size: 0.875rem;
    opacity: 0.8;
}

/* Responsive */
@media (max-width: 360px) {
    .menu-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .login-card {
        padding: 2rem 1.5rem;
    }
}

/* Profile Table */
.profile-table {
    width: 100%;
    font-size: 0.8125rem;
    border-collapse: collapse;
}

.profile-table tr {
    border-bottom: 1px solid var(--border-light);
}

.profile-table tr:last-child {
    border-bottom: none;
}

.profile-table tr:hover {
    background: var(--bg-main);
}

.profile-table .profile-label {
    padding: 0.75rem 1.25rem;
    color: var(--text-muted);
    width: 36%;
    vertical-align: top;
    font-size: 0.75rem;
    font-weight: 500;
}

.profile-table .profile-value {
    padding: 0.75rem 1.25rem;
    font-weight: 600;
    color: var(--text-dark);
    font-size: 0.8125rem;
}

@media (min-width: 768px) {
    .container {
        max-width: 480px;
    }
    
    .menu-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1rem;
    }
}

/* Password toggle */
.password-toggle {
    position: absolute;
    right: 0.875rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.25rem;
    font-size: 1.125rem;
}

.password-toggle:hover {
    color: var(--primary);
}

/* Notification badge */
.notif-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    background: linear-gradient(135deg, #EF4444, #DC2626);
    color: white;
    font-size: 0.625rem;
    font-weight: 700;
    border-radius: 10px;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.3);
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-muted);
}

.empty-state .empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--primary-light);
    opacity: 0.6;
}

.empty-state p {
    font-size: 0.875rem;
}

/* Menu Categories (Accordion) */
.menu-categories {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.menu-category {
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border-light);
    overflow: hidden;
    transition: var(--transition);
    box-shadow: var(--shadow-xs);
}

.menu-category:hover {
    border-color: var(--primary-light);
    box-shadow: var(--shadow);
}

.menu-category.open {
    box-shadow: var(--shadow);
    border-color: var(--primary-light);
}

.menu-category-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 1rem 1.125rem;
    background: none;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.menu-category-header:hover {
    background: var(--primary-lighter);
}

.category-left {
    display: flex;
    align-items: center;
    gap: 0.875rem;
}

.category-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    font-size: 1.125rem;
    flex-shrink: 0;
    transition: var(--transition);
}

.menu-category.open .category-icon {
    transform: scale(1.05);
}

.category-title {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--text-dark);
    letter-spacing: -0.01em;
}

.category-arrow {
    font-size: 0.875rem;
    color: var(--text-muted);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.menu-category.open .category-arrow {
    transform: rotate(180deg);
    color: var(--primary);
}

.menu-category-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0 1rem;
}

.menu-category.open .menu-category-body {
    max-height: 500px;
    padding: 0 1rem 1rem;
}

.menu-grid.sub-menu {
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
    padding: 0.5rem 0 0;
}

.menu-grid.sub-menu .menu-item {
    padding: 0.75rem 0.25rem;
    border: none;
    background: var(--bg-main);
    border-radius: var(--radius-sm);
}

.menu-grid.sub-menu .menu-item::before {
    display: none;
}

.menu-grid.sub-menu .menu-item:hover {
    background: var(--primary-lighter);
    border: none;
    transform: translateY(-2px);
}

.menu-grid.sub-menu .menu-icon {
    width: 36px;
    height: 36px;
    font-size: 1rem;
    background: var(--bg-card);
    border-radius: 10px;
    box-shadow: var(--shadow-xs);
}

.menu-grid.sub-menu .menu-item:hover .menu-icon {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--text-light);
    transform: scale(1.05);
}

.menu-grid.sub-menu .menu-label {
    font-size: 0.625rem;
    margin-top: 0.125rem;
}

@media (max-width: 360px) {
    .menu-grid.sub-menu {
        grid-template-columns: repeat(3, 1fr);
    }
}
