/* ===================================
   Basma Main System - Complete CSS
   Version: 2.1 - Fixed
   =================================== */

/* ===================================
   Root Variables
   =================================== */
:root {
    --basma-primary: #0d9488;
    --basma-primary-light: #14b8a6;
    --basma-success: #10b981;
    --basma-danger: #ef4444;
    --basma-info: #3b82f6;
    --basma-warning: #f59e0b;
}

/* ===================================
   MAIN LAYOUT STYLES
   =================================== */

/* Logo Enhancement */
.logo-enhanced {
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    transition: all 0.3s ease;
}

    .logo-enhanced:hover {
        transform: scale(1.05);
        box-shadow: 0 3px 12px rgba(0,0,0,0.2);
    }

/* Branch Info - Clean with 3D Text - REDUCED SPACING */
.branch-info-clean {
    display: flex;
    text-align: start;
    padding: 2px 0;
    margin-bottom: 1px;
    margin-top: 1px;
    position: fixed;
}

/* Footer Info - Clean with 3D Text - VISIBLE VERSION */
.footer-info-clean {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 16px;
    position: fixed;
    bottom: 50px;
    left: 0;
    right: 0;
    z-index: 99;
}

/* 3D Engraved Text Effect - MORE VISIBLE */
.text-3d-engraved {
    font-size: 12px;
    font-weight: 700;
    color: #475569;
    text-shadow: 1px 1px 0px rgba(255,255,255,0.9), -1px -1px 0px rgba(0,0,0,0.15);
    letter-spacing: 0.3px;
}

.footer-version,
.footer-user {
    display: flex;
    align-items: center;
    gap: 5px;
}

.footer-version {
    font-size: 13px;
    font-weight: 700;
    color: #64748b;
}

.footer-user {
    font-size: 12px;
}

/* Bottom Toolbar Enhanced */
.bottom-toolbar-enhanced {
    padding: 4px 8px !important;
}

.nav-icon-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    border-radius: 8px;
    transition: all 0.3s ease;
    cursor: pointer;
}

    .nav-icon-btn i {
        font-size: 22px;
        color: rgba(255,255,255,0.85);
        transition: all 0.3s ease;
    }

    .nav-icon-btn:hover {
        background: rgba(255,255,255,0.15);
    }

        .nav-icon-btn:hover i {
            color: white;
            transform: scale(1.1);
        }

    .nav-icon-btn:active {
        transform: scale(0.95);
    }

/* ===================================
   HOME PAGE STYLES
   =================================== */

/* Home Page Container */
.basma-home-page {
    padding: 4px 4px 8px 4px;
}

/* Page Header */
.basma-page-header {
    text-align: center;
    margin-bottom: 12px;
}

.basma-page-title {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 8px 0;
}

.basma-title-line {
    width: 50px;
    height: 3px;
    background: linear-gradient(90deg, #14b8a6, #0d9488);
    margin: 0 auto;
    border-radius: 2px;
}

/* Grid Compact */
.basma-grid-compact {
    margin-top: 0 !important;
}

.basma-grid-item {
    padding: 4px !important;
}

/* ===================================
   Card Styles - SMALLER & COMPACT
   =================================== */
.basma-card {
    background: white;
    border-radius: 12px;
    padding: 12px 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    border: 1px solid transparent;
    min-height: 90px;
}

    .basma-card:hover {
        transform: translateY(-3px);
        box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    }

    .basma-card:active {
        transform: translateY(-1px);
    }

/* ===================================
   Icon Wrapper - SMALLER
   =================================== */
.basma-card-icon-wrapper {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.basma-card:hover .basma-card-icon-wrapper {
    transform: scale(1.08);
}

/* ===================================
   Icons - CLEAR & VISIBLE
   =================================== */
.basma-card-icon-wrapper i {
    font-size: 24px;
    transition: all 0.3s ease;
}

/* ===================================
   Green Cards (Login)
   =================================== */
.basma-card-green .basma-card-icon-wrapper {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(16, 185, 129, 0.25));
}

.basma-icon-green {
    color: #10b981;
}

/* ===================================
   Red Cards (Logout)
   =================================== */
.basma-card-red .basma-card-icon-wrapper {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(239, 68, 68, 0.25));
}

.basma-icon-red {
    color: #ef4444;
}

/* ===================================
   Blue Cards (Info/Settings)
   =================================== */
.basma-card-blue .basma-card-icon-wrapper {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(59, 130, 246, 0.25));
}

.basma-icon-blue {
    color: #3b82f6;
}

/* ===================================
   Card Text
   =================================== */
.basma-card-text {
    font-size: 13px;
    font-weight: bold;
    color: #374151;
    text-align: center;
    line-height: 1.3;
}

/* ===================================
   Border Glow on Hover
   =================================== */
.basma-card-green:hover {
    border-color: rgba(16, 185, 129, 0.3);
}

.basma-card-red:hover {
    border-color: rgba(239, 68, 68, 0.3);
}

.basma-card-blue:hover {
    border-color: rgba(59, 130, 246, 0.3);
}

/* ===================================
   Animations
   =================================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.basma-home-page {
    animation: fadeIn 0.4s ease;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ===================================
   RESPONSIVE DESIGN
   =================================== */

/* Small Mobile Devices (600px and below) */
@media (max-width: 600px) {
    .basma-card {
        min-height: 85px;
        padding: 10px 6px;
    }

    .basma-card-icon-wrapper {
        width: 44px;
        height: 44px;
    }

        .basma-card-icon-wrapper i {
            font-size: 22px;
        }

    .basma-card-text {
        font-size: 11px;
    }

    .nav-icon-btn i {
        font-size: 20px;
    }

    .basma-page-title {
        font-size: 16px;
    }

    .text-3d-engraved {
        font-size: 11px;
    }

    .footer-version {
        font-size: 12px;
    }

    .footer-info-clean {
        padding: 6px 12px;
    }
}

/* Very Small Devices (360px and below) */
@media (max-width: 360px) {
    .basma-card {
        min-height: 80px;
        padding: 8px 5px;
    }

    .basma-card-icon-wrapper {
        width: 40px;
        height: 40px;
    }

        .basma-card-icon-wrapper i {
            font-size: 20px;
        }

    .basma-card-text {
        font-size: 10px;
    }

    .footer-info-clean {
        padding: 5px 10px;
    }

    .nav-icon-btn {
        padding: 6px 10px;
    }

        .nav-icon-btn i {
            font-size: 18px;
        }

    .text-3d-engraved {
        font-size: 10px;
    }

    .footer-version {
        font-size: 11px;
    }
}

/* Tablets and Larger (768px and above) */
@media (min-width: 768px) {
    .basma-card {
        min-height: 95px;
        padding: 14px 10px;
    }

    .basma-card-icon-wrapper {
        width: 52px;
        height: 52px;
    }

        .basma-card-icon-wrapper i {
            font-size: 26px;
        }

    .basma-card-text {
        font-size: 13px;
    }

    .basma-page-title {
        font-size: 20px;
    }
}

/* Desktop (1024px and above) */
@media (min-width: 1024px) {
    .basma-home-page {
        max-width: 800px;
        margin: 0 auto;
    }
}

/* ===================================
   Landscape Orientation
   =================================== */
@media (max-height: 600px) and (orientation: landscape) {
    .basma-card {
        padding: 10px 6px;
        min-height: 80px;
    }

    .basma-card-icon-wrapper {
        width: 40px;
        height: 40px;
    }

        .basma-card-icon-wrapper i {
            font-size: 20px;
        }

    .basma-page-header {
        margin-bottom: 8px;
    }

    .basma-page-title {
        font-size: 16px;
    }

    .branch-info-clean {
        padding: 2px 0;
        margin-bottom: 4px;
    }
}

/* ===================================
   RTL Support
   =================================== */
[dir="rtl"] .footer-info-clean {
    direction: rtl;
}

[dir="rtl"] .footer-version,
[dir="rtl"] .footer-user {
    flex-direction: row-reverse;
}

/* ===================================
   Accessibility
   =================================== */

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .basma-card,
    .basma-card-icon-wrapper,
    .nav-icon-btn,
    .logo-enhanced {
        transition: none !important;
        animation: none !important;
    }
}

/* Focus Styles for Keyboard Navigation */
.nav-icon-btn:focus,
.basma-card:focus {
    outline: 2px solid var(--basma-primary);
    outline-offset: 2px;
}

.nav-icon-btn:focus-visible,
.basma-card:focus-visible {
    box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.3);
}

/* ===================================
   Dark Mode Support
   =================================== */
@media (prefers-color-scheme: dark) {
    .basma-card {
        background: rgba(30, 41, 59, 0.95);
        border-color: rgba(255, 255, 255, 0.1);
    }

    .basma-card-text {
        color: #e2e8f0;
    }

    .basma-page-title {
        color: #f1f5f9;
    }

    .text-3d-engraved {
        color: #94a3b8;
        text-shadow: 1px 1px 0px rgba(0,0,0,0.5), -1px -1px 0px rgba(255,255,255,0.1);
    }

    .footer-info-clean {
        background: rgba(30, 41, 59, 0.95);
        border-top-color: rgba(255, 255, 255, 0.1);
    }

    .basma-card-green .basma-card-icon-wrapper {
        background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(16, 185, 129, 0.35));
    }

    .basma-card-red .basma-card-icon-wrapper {
        background: linear-gradient(135deg, rgba(239, 68, 68, 0.25), rgba(239, 68, 68, 0.35));
    }

    .basma-card-blue .basma-card-icon-wrapper {
        background: linear-gradient(135deg, rgba(59, 130, 246, 0.25), rgba(59, 130, 246, 0.35));
    }
    .basma-card-no .basma-card-icon-wrapper {
        
    }
}

/* ===================================
   Print Styles
   =================================== */
@media print {
    .footer-info-clean,
    .nav-icon-btn,
    .logo-enhanced,
    .w3-top,
    .w3-bottom {
        display: none !important;
    }

    .basma-card {
        box-shadow: none;
        border: 1px solid #ddd;
    }

    .basma-home-page {
        padding: 0;
    }
}

/* ===================================
   Utility Classes
   =================================== */
.basma-text-center {
    text-align: center;
}

.basma-mt-1 {
    margin-top: 8px;
}

.basma-mt-2 {
    margin-top: 16px;
}

.basma-mb-1 {
    margin-bottom: 8px;
}

.basma-mb-2 {
    margin-bottom: 16px;
}

.basma-p-1 {
    padding: 8px;
}

.basma-p-2 {
    padding: 16px;
}

/* Loading Spinner */
.basma-loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s linear infinite;
}

/* ===================================
   Performance Optimizations
   =================================== */

/* Hardware Acceleration for Smooth Animations */
.basma-card,
.basma-card-icon-wrapper,
.nav-icon-btn {
    will-change: transform;
}

/* Contain Layout Changes */
.basma-card {
    contain: layout style paint;
}

/* ===================================
   End of Basma Main CSS
   =================================== */
