/* Glass Neon Theme - Bright Pink Edition */
.glass-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.glass-input {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: white;
}

.glass-input:focus {
    border-color: rgba(255, 20, 147, 0.8);
    box-shadow: 0 0 0 3px rgba(255, 20, 147, 0.4), 0 0 20px rgba(255, 20, 147, 0.6);
}

/* Dropdown/Select styling */
.glass-input select,
select.glass-input {
    background: rgba(31, 41, 55, 0.9) !important;
    color: white !important;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 8px 12px;
}

.glass-input select option,
select.glass-input option {
    background: rgba(31, 41, 55, 0.95) !important;
    color: white !important;
    padding: 8px 12px;
}

.glass-input select option:hover,
select.glass-input option:hover {
    background: rgba(59, 130, 246, 0.7) !important;
    color: white !important;
}

.glass-input select option:checked,
select.glass-input option:checked,
.glass-input select option:selected,
select.glass-input option:selected {
    background: rgba(59, 130, 246, 0.8) !important;
    color: white !important;
}

.glass-input select option:focus,
select.glass-input option:focus {
    background: rgba(59, 130, 246, 0.7) !important;
    color: white !important;
}

.glass-input select:focus,
select.glass-input:focus {
    border-color: rgba(255, 20, 147, 0.8) !important;
    box-shadow: 0 0 0 3px rgba(255, 20, 147, 0.4), 0 0 20px rgba(255, 20, 147, 0.6) !important;
    outline: none;
}

/* Firefox specific dropdown fixes */
@-moz-document url-prefix() {
    select.glass-input option {
        background-color: #1f2937 !important;
        color: white !important;
    }
    
    select.glass-input option:checked {
        background-color: #3b82f6 !important;
        color: white !important;
    }
}

/* Webkit browsers scrollbar for dropdowns */
select.glass-input::-webkit-scrollbar {
    width: 8px;
}

select.glass-input::-webkit-scrollbar-track {
    background: rgba(31, 41, 55, 0.5);
}

select.glass-input::-webkit-scrollbar-thumb {
    background: rgba(59, 130, 246, 0.7);
    border-radius: 4px;
}

.glass-button {
    background: linear-gradient(135deg, rgba(255, 20, 147, 0.3), rgba(255, 105, 180, 0.3));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: white;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.glass-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 20, 147, 0.4), transparent);
    transition: left 0.5s;
}

.glass-button:hover::before {
    left: 100%;
}

.glass-button:hover {
    background: linear-gradient(135deg, rgba(255, 20, 147, 0.5), rgba(255, 105, 180, 0.5));
    border-color: rgba(255, 20, 147, 0.6);
    box-shadow: 0 0 30px rgba(255, 20, 147, 0.8), 0 0 60px rgba(255, 20, 147, 0.4);
    transform: translateY(-2px);
}

.glass-button-primary {
    background: linear-gradient(135deg, #ff1493, #ff69b4);
    border: none;
    border-radius: 8px;
    color: white;
    transition: all 0.3s ease;
    box-shadow: 0 0 20px rgba(255, 20, 147, 0.6);
}

.glass-button-primary:hover {
    background: linear-gradient(135deg, #ff1493, #ff69b4);
    box-shadow: 0 0 40px rgba(255, 20, 147, 1), 0 0 80px rgba(255, 20, 147, 0.6);
    transform: translateY(-3px);
}

.nav-link {
    padding: 8px 16px;
    border-radius: 8px;
    color: #9ca3af;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: #f3f4f6;
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 0 15px rgba(255, 20, 147, 0.3);
}

.nav-link.active {
    color: #ff1493;
    background: rgba(255, 20, 147, 0.1);
    border: 1px solid rgba(255, 20, 147, 0.4);
    box-shadow: 0 0 20px rgba(255, 20, 147, 0.5);
}

.nav-link.active::before {
    content: '';
    position: absolute;
    top: -1px;
    left: -1px;
    right: -1px;
    bottom: -1px;
    background: linear-gradient(135deg, #ff1493, #ff69b4);
    border-radius: 8px;
    z-index: -1;
    opacity: 0.2;
}

/* Bright Neon glow effects */
.neon-glow {
    box-shadow: 0 0 30px rgba(255, 20, 147, 1), 0 0 60px rgba(255, 20, 147, 0.6), 0 0 90px rgba(255, 20, 147, 0.3);
}

.neon-text {
    text-shadow: 0 0 10px rgba(255, 20, 147, 1), 0 0 20px rgba(255, 20, 147, 0.8), 0 0 30px rgba(255, 20, 147, 0.6);
    color: #ff1493;
}

/* Table styling */
.glass-table {
    background: rgba(255, 255, 255, 0.02);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    overflow: hidden;
}

.glass-table th {
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.glass-table td {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* Form styling */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    color: #e5e7eb;
    font-weight: 500;
}

/* Stats cards with bright pink neon */
.stats-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.stats-card:hover {
    border-color: rgba(255, 215, 0, 0.5);
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.6), 0 0 30px rgba(255, 215, 0, 0.4), 0 0 45px rgba(255, 215, 0, 0.2);
    transform: translateY(-1px);
    background: rgba(255, 255, 255, 0.08);
}

/* Glass cards with softer yellow neon hover effect */
.glass-card:hover {
    border-color: rgba(255, 215, 0, 0.4);
    box-shadow: 0 0 12px rgba(255, 215, 0, 0.5), 0 0 25px rgba(255, 215, 0, 0.3), 0 0 40px rgba(255, 215, 0, 0.15);
    transform: translateY(-1px);
    background: rgba(255, 255, 255, 0.08);
}

/* Loading animation with pink */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #ff1493;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive design */
@media (max-width: 768px) {
    .nav-link {
        padding: 6px 12px;
        font-size: 0.875rem;
    }

    .glass-card {
        margin: 0 0.5rem;
        padding: 1rem;
        max-width: 100%;
        box-sizing: border-box;
    }

    /* Prevent horizontal overflow */
    .container, .main-content, main {
        max-width: 100vw;
        overflow-x: hidden;
        box-sizing: border-box;
    }

    /* Adjust bottom navigation padding and icon size for mobile */
    .bottom-nav {
        padding-left: 2px;
        padding-right: 2px;
    }

    .bottom-nav-link i {
        font-size: 16px; /* smaller icon size */
    }

    .bottom-nav-link span {
        font-size: 10px; /* smaller text size */
    }

    /* Improve text readability on mobile */
    h1 {
        font-size: 1.5rem !important;
        line-height: 1.3;
    }

    h2 {
        font-size: 1.25rem !important;
    }

    h3 {
        font-size: 1.125rem !important;
    }

    /* Better button sizing for touch */
    .glass-button, .glass-button-primary {
        min-height: 44px;
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }

    /* Improve form elements */
    .glass-input {
        font-size: 16px; /* Prevent zoom on iOS */
        padding: 0.75rem;
    }

    /* Better spacing for mobile */
    .p-4 {
        padding: 1rem !important;
    }

    .p-6 {
        padding: 1.5rem !important;
    }

    .mb-8 {
        margin-bottom: 2rem !important;
    }

    .mb-6 {
        margin-bottom: 1.5rem !important;
    }

    /* Fix grid layouts */
    .grid-cols-1.md\\:grid-cols-2.lg\\:grid-cols-3 {
        grid-template-columns: 1fr;
    }

    .grid-cols-1.md\\:grid-cols-2.lg\\:grid-cols-4 {
        grid-template-columns: 1fr;
    }

    .grid-cols-1.lg\\:grid-cols-2 {
        grid-template-columns: 1fr;
    }

    /* Better modal sizing */
    .max-w-md {
        max-width: calc(100vw - 2rem) !important;
    }

    .max-w-lg {
        max-width: calc(100vw - 2rem) !important;
    }

    .max-w-2xl {
        max-width: calc(100vw - 2rem) !important;
    }

    /* Fix table overflow */
    .overflow-x-auto {
        -webkit-overflow-scrolling: touch;
    }

    /* Improve FAB positioning */
    .fab-expand {
        bottom: 90px !important; /* Above bottom nav */
    }
}

/* Extra small screens */
@media (max-width: 480px) {
    .glass-card {
        margin: 0 0.25rem;
        padding: 0.75rem;
    }

    h1 {
        font-size: 1.25rem !important;
    }

    .text-3xl {
        font-size: 1.5rem !important;
    }

    .text-2xl {
        font-size: 1.25rem !important;
    }

    /* Stack flex items vertically on very small screens */
    .flex-col.md\\:flex-row {
        flex-direction: column;
    }

    .items-start.md\\:items-center {
        align-items: flex-start;
    }

    /* Better spacing for very small screens */
    .space-x-3 > * + * {
        margin-left: 0.5rem;
    }

    .space-y-3 > * + * {
        margin-top: 0.75rem;
    }
}

/* Mobile Floating Action Buttons */
@media (max-width: 768px) {
    /* Hide desktop buttons on mobile */
    .mobile-hide {
        display: none !important;
    }

    /* Floating Action Button */
    .fab {
        position: fixed;
        bottom: 80px; /* Above bottom nav */
        right: 20px;
        width: 56px;
        height: 56px;
        border-radius: 50%;
        background: linear-gradient(135deg, #ff1493, #ff69b4);
        border: none;
        box-shadow: 0 4px 20px rgba(255, 20, 147, 0.4);
        color: white;
        font-size: 24px;
        cursor: pointer;
        z-index: 1000;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .fab:hover {
        transform: scale(1.1);
        box-shadow: 0 6px 25px rgba(255, 20, 147, 0.6);
    }

    .fab:active {
        transform: scale(0.95);
    }

    /* Expandable FAB for contacts page */
    .fab-expand {
        position: fixed;
        bottom: 80px;
        right: 20px;
        z-index: 1000;
    }

    .fab-main {
        width: 56px;
        height: 56px;
        border-radius: 50%;
        background: linear-gradient(135deg, #ff1493, #ff69b4);
        border: none;
        box-shadow: 0 4px 20px rgba(255, 20, 147, 0.4);
        color: white;
        font-size: 24px;
        cursor: pointer;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .fab-main:hover {
        transform: scale(1.1);
        box-shadow: 0 6px 25px rgba(255, 20, 147, 0.6);
    }

    .fab-main.active {
        transform: rotate(45deg);
    }

    .fab-options {
        position: absolute;
        bottom: 70px;
        right: 0;
        display: flex;
        flex-direction: column;
        gap: 10px;
        opacity: 0;
        transform: translateY(20px);
        transition: all 0.3s ease;
        pointer-events: none;
    }

    .fab-options.active {
        opacity: 1;
        transform: translateY(0);
        pointer-events: auto;
    }

    .fab-option {
        width: 48px;
        height: 48px;
        border-radius: 50%;
        border: none;
        color: white;
        font-size: 20px;
        cursor: pointer;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
    }

    .fab-option:hover {
        transform: scale(1.1);
    }

    .fab-option:nth-child(1) {
        background: linear-gradient(135deg, #10b981, #34d399);
        box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
    }

    .fab-option:nth-child(2) {
        background: linear-gradient(135deg, #3b82f6, #60a5fa);
        box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4);
    }

    .fab-option:nth-child(3) {
        background: linear-gradient(135deg, #ff1493, #ff69b4);
        box-shadow: 0 4px 15px rgba(255, 20, 147, 0.4);
    }

    .fab-tooltip {
        position: absolute;
        right: 60px;
        top: 50%;
        transform: translateY(-50%);
        background: rgba(0, 0, 0, 0.8);
        color: white;
        padding: 6px 12px;
        border-radius: 6px;
        font-size: 12px;
        white-space: nowrap;
        opacity: 0;
        transition: opacity 0.3s ease;
        pointer-events: none;
    }

    .fab-option:hover .fab-tooltip {
        opacity: 1;
    }
}
