/* ============================================================ */
/* StaffExpress – Main Design System (Mobile-First)             */
/* ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    /* Color Palette */
    --primary: #00C27C;
    /* Vibrant Green */
    --primary-dark: #00A669;
    --background: #0F172A;
    /* Deep Navy Dark Mode */
    --surface: #1E293B;
    /* Card Surface */
    --surface-light: #334155;
    --text: #F8FAFC;
    --text-muted: #94A3B8;
    --border: #334155;
    --error: #EF4444;
    --success: #10B981;
    --white: #FFFFFF;

    /* Spacing */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;

    /* Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-full: 9999px;

    /* Shadows */
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--background);
    color: var(--text);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    padding-bottom: 70px;
    /* Space for bottom nav */
}

a {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
}

button,
input,
select,
textarea {
    font-family: inherit;
}

/* Typography */
h1 {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.2;
}

h2 {
    font-size: 1.5rem;
    font-weight: 600;
}

h3 {
    font-size: 1.25rem;
    font-weight: 600;
}

p {
    color: var(--text-muted);
}

.container {
    width: 100%;
    margin: 0 auto;
    padding: 0 var(--space-md);
}

@media (min-width: 640px) {
    .container {
        max-width: 640px;
    }
}

@media (min-width: 768px) {
    .container {
        max-width: 768px;
    }
}

@media (min-width: 1024px) {
    .container {
        max-width: 1024px;
    }
}

@media (min-width: 1280px) {
    .container {
        max-width: 1200px;
    }
}

/* Layout Utilities */
.flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

.items-center {
    align-items: center;
}

.justify-between {
    justify-content: space-between;
}

.justify-center {
    justify-content: center;
}

@media (max-width: 767.98px) {
    .flex-col-mobile {
        flex-direction: column !important;
    }
}

.gap-sm {
    gap: var(--space-sm);
}

.gap-md {
    gap: var(--space-md);
}

.gap-lg {
    gap: var(--space-lg);
}

.gap-xl {
    gap: var(--space-xl);
}

.mt-sm {
    margin-top: var(--space-sm);
}

.mt-md {
    margin-top: var(--space-md);
}

.mt-lg {
    margin-top: var(--space-lg);
}

.mb-sm {
    margin-bottom: var(--space-sm);
}

.mb-md {
    margin-bottom: var(--space-md);
}

.mb-lg {
    margin-bottom: var(--space-lg);
}

.mb-xl {
    margin-bottom: var(--space-xl);
}

.text-center {
    text-align: center;
}

.block {
    display: block;
}

.hidden {
    display: none;
}

.w-full {
    width: 100%;
}

.max-w-md {
    max-width: 448px;
    width: 100%;
}

.mx-auto {
    margin-left: auto;
    margin-right: auto;
}

.relative {
    position: relative;
}

.absolute {
    position: absolute;
}


/* Grid System */
.grid {
    display: grid;
    gap: var(--space-md);
}

.grid-cols-1 {
    grid-template-columns: repeat(1, minmax(0, 1fr));
}

@media (min-width: 768px) {
    .grid-cols-2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 1024px) {
    .grid-cols-3 {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}


@media (min-width: 768px) {
    .grid-cols-2-md {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 1024px) {
    .grid-cols-3-lg {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (min-width: 1024px) {
    .grid-cols-4-lg {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

/* Components */
.card {
    background-color: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: var(--space-md);
    box-shadow: var(--shadow);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    font-size: 1rem;
    width: 100%;
}

.btn-primary {
    background-color: var(--primary);
    color: var(--white);
}

.btn-primary:active {
    transform: scale(0.98);
    background-color: var(--primary-dark);
}

.btn-outline {
    background-color: transparent;
    border: 1px solid var(--border);
    color: var(--text);
}

.input-group {
    margin-bottom: var(--space-md);
}

.input-group label {
    display: block;
    margin-bottom: var(--space-xs);
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.input-control {
    width: 100%;
    padding: 12px 16px;
    background-color: var(--surface-light);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-size: 1rem;
    transition: border-color 0.2s;
}

.input-control:focus {
    outline: none;
    border-color: var(--primary);
}

/* Badges */
.badge {
    padding: 4px 8px;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-success {
    background-color: rgba(16, 185, 129, 0.2);
    color: var(--success);
}

/* Nav */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: var(--surface);
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-around;
    padding: 10px 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

@media (min-width: 768px) {
    .bottom-nav {
        top: 0;
        bottom: auto;
        padding: 15px 0;
        border-top: none;
        border-bottom: 1px solid var(--border);
    }

    body {
        padding-bottom: 0;
        padding-top: 80px;
    }

    .nav-item {
        flex-direction: row;
        font-size: 0.9rem;
    }
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 0.7rem;
    color: var(--text-muted);
    gap: 4px;
}

.nav-item.active {
    color: var(--primary);
}

.nav-icon {
    font-size: 1.2rem;
}

/* Language Switcher */
.lang-switcher {
    display: inline-block;
    position: relative;
}

.header-meta .lang-switcher {
    position: absolute;
    top: var(--space-md);
    right: var(--space-md);
}

.lang-toggle {
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    cursor: pointer;
    display: flex;
    align-items: center;
}

.lang-dropdown-menu {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    right: 0;
    top: 100%;
    margin-top: 5px;
    background-color: var(--surface);
    min-width: 140px;
    box-shadow: var(--shadow-lg);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    z-index: 9999;
    overflow: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

/* Invisible bridge so mouse doesn't lose hover */
.lang-dropdown-menu::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 0;
    right: 0;
    height: 10px;
}

.lang-switcher.open .lang-dropdown-menu {
    visibility: visible;
    opacity: 1;
}

.lang-btn {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 10px 15px;
    background: none;
    border: none;
    color: var(--text);
    text-align: left;
    cursor: pointer;
    font-size: 0.85rem;
    transition: background-color 0.2s;
}

.lang-btn:hover {
    background-color: var(--surface-light);
}

.lang-btn:disabled,
.lang-btn.active {
    opacity: 0.6;
    cursor: default;
}

/* Avatar */
.avatar {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-full);
    object-fit: cover;
    background-color: var(--surface-light);
}

.avatar-lg {
    width: 80px;
    height: 80px;
}

/* Status Indicators */
.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 6px;
}

.dot-success {
    background-color: var(--success);
    box-shadow: 0 0 8px var(--success);
}

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

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

.animate-fade {
    animation: fadeIn 0.4s ease forwards;
}