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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(160deg, #1a1b2e 0%, #16213e 40%, #0f3460 100%);
    min-height: 100vh;
    color: rgba(255,255,255,0.9);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Login Overlay - Dark single-column landing */
.login-overlay {
    position: fixed;
    inset: 0;
    background: linear-gradient(160deg, #1a1b2e 0%, #16213e 40%, #0f3460 100%);
    z-index: 10000;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.login-overlay::before {
    content: '';
    position: fixed;
    top: -30%;
    right: -20%;
    width: 120%;
    height: 120%;
    background: radial-gradient(ellipse, rgba(255,255,255,0.04) 0%, transparent 55%);
    pointer-events: none;
}

/* Landing header */
.landing-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 24px;
    max-width: 1500px;
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 1;
}

.landing-logo {
    display: flex;
    align-items: center;
    gap: 8px;
}

.landing-logo .logo-icon {
    font-size: 1.4rem;
    animation: wave-swell-small 2.5s ease-in-out infinite;
}

@keyframes wave-swell-small {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-2px); }
}

.landing-logo .logo-text {
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.02em;
}

.landing-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.landing-btn {
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: background 0.2s, color 0.2s;
}

.landing-btn-ghost {
    background: transparent;
    color: rgba(255,255,255,0.85);
}

.landing-btn-ghost:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
}

.landing-btn-primary {
    background: #4CAF50;
    color: #fff;
}

.landing-btn-primary:hover {
    background: #43a047;
}

/* Landing main - single column, wide for less scrolling */
.landing-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 24px 24px 48px;
    max-width: 1500px;
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 1;
}

.landing-hero {
    text-align: center;
    margin-bottom: 36px;
    width: 100%;
}

.landing-hero-inner {
    max-width: 720px;
    margin: 0 auto;
}

.landing-logo-large {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

/* Logo mark: wave icon + flowing wave line as one unit */
.landing-logo-large .logo-mark {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    color: rgba(255,255,255,0.95);
}

.landing-logo-large .logo-icon {
    font-size: 2.4em;
    line-height: 1;
    animation: wave-swell 2.5s ease-in-out infinite;
}

@keyframes wave-swell {
    0%, 100% { transform: translateY(0) scale(1); }
    25%      { transform: translateY(-3px) scale(1.05); }
    50%      { transform: translateY(0) scale(1); }
    75%      { transform: translateY(2px) scale(0.98); }
}

/* Flowing wave line under the icon */
.landing-logo-large .logo-wave-svg {
    width: 48px;
    height: 18px;
    overflow: visible;
}

.landing-logo-large .wave-path {
    animation: wave-flow 2.2s ease-in-out infinite;
    color: rgba(255,255,255,0.7);
}

.landing-logo-large .wave-path-2 {
    animation: wave-flow 2.2s ease-in-out 0.55s infinite;
    color: rgba(255,255,255,0.45);
}

@keyframes wave-flow {
    0%, 100% { transform: translate(0, 0) scaleX(1); }
    33%      { transform: translate(3px, -1px) scaleX(1.01); }
    66%      { transform: translate(6px, 1px) scaleX(1.02); }
}

.landing-logo-large .logo-text {
    font-size: 2.2em;
    font-weight: 700;
    color: #fff;
    margin: 0;
    letter-spacing: -0.02em;
}

.landing-hero-headline {
    font-size: 1.95em;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 14px;
    color: #fff;
}

.landing-hero-tagline {
    font-size: 1.05em;
    line-height: 1.55;
    color: rgba(255,255,255,0.9);
    margin-bottom: 24px;
    font-weight: 400;
}

.landing-cta {
    padding: 12px 28px;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}

.landing-cta-primary {
    color: #fff;
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    box-shadow: 0 4px 20px rgba(34, 197, 94, 0.45);
}

.landing-cta-primary:hover {
    background: linear-gradient(135deg, #2dd96b 0%, #22c55e 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 28px rgba(34, 197, 94, 0.55);
}

.landing-hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.landing-cta-ghost {
    background: transparent;
    color: #22c55e;
    border: 2px solid #22c55e;
    box-shadow: none;
}

.landing-cta-ghost:hover {
    background: rgba(34, 197, 94, 0.15);
    border-color: #2dd96b;
    color: #4ade80;
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(34, 197, 94, 0.3);
}

/* Benefit rows - 3-column grid on wide screens to use width */
.landing-benefits {
    width: 100%;
    margin-bottom: 32px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.benefit-row {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 20px 18px;
    background: rgba(255,255,255,0.06);
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.12);
    transition: background 0.2s, border-color 0.2s, transform 0.2s;
}

.benefit-row:hover {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,255,255,0.2);
    transform: translateY(-2px);
}

.benefit-row .benefit-icon {
    font-size: 1.6em;
    flex-shrink: 0;
}

.benefit-row .benefit-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.benefit-text strong {
    font-size: 1em;
    font-weight: 600;
    color: #fff;
}

.benefit-text span {
    font-size: 0.88em;
    color: rgba(255,255,255,0.85);
    line-height: 1.4;
}

/* Feature pills - spread across width */
.landing-features {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin-bottom: 32px;
    padding: 20px 0;
}

.landing-pill {
    background: rgba(255,255,255,0.08);
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: 500;
    color: rgba(255,255,255,0.95);
    border: 1px solid rgba(255,255,255,0.15);
    transition: background 0.2s, border-color 0.2s, transform 0.2s;
}

.landing-pill:hover {
    background: rgba(255,255,255,0.14);
    border-color: rgba(255,255,255,0.25);
    transform: translateY(-1px);
}

/* Feature details - card grid uses full width */
.landing-feature-details {
    width: 100%;
    margin-bottom: 32px;
    padding: 28px 0;
    border-top: 1px solid rgba(255,255,255,0.08);
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.feature-details-title {
    font-size: 1.15em;
    font-weight: 600;
    color: rgba(255,255,255,0.95);
    text-align: center;
    margin-bottom: 22px;
    letter-spacing: 0.02em;
}

.feature-detail-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.feature-detail-card {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 14px;
    padding: 20px 22px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    transition: background 0.2s, border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.feature-detail-card:hover {
    background: rgba(255,255,255,0.09);
    border-color: rgba(255,255,255,0.2);
    box-shadow: 0 8px 24px rgba(0,0,0,0.25);
    transform: translateY(-3px);
}

.feature-detail-card .feature-detail-icon {
    font-size: 1.6em;
    display: block;
    margin-bottom: 10px;
}

.feature-detail-card h4 {
    font-size: 1.02em;
    font-weight: 600;
    color: #fff;
    margin-bottom: 8px;
}

.feature-detail-card p {
    font-size: 0.9em;
    line-height: 1.5;
    color: rgba(255,255,255,0.85);
    margin: 0;
}

/* Social proof - full-width strip */
.landing-proof {
    display: flex;
    justify-content: center;
    align-items: stretch;
    gap: 0;
    width: 100%;
    padding: 28px 40px;
    margin-top: 0;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 14px;
}

.landing-proof-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex: 1;
    padding: 0 24px;
    min-width: 120px;
    max-width: 280px;
}

.landing-proof-item:not(:last-child) {
    border-right: 1px solid rgba(255,255,255,0.18);
}

.landing-proof-num {
    font-size: 2em;
    font-weight: 800;
    color: #4CAF50;
    text-shadow: 0 0 14px rgba(76, 175, 80, 0.4);
}

.landing-proof-label {
    font-size: 0.8em;
    font-weight: 600;
    color: rgba(255,255,255,0.9);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* Compact auth panel (overlay) */
.auth-panel {
    position: fixed;
    inset: 0;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.auth-panel.open {
    pointer-events: auto;
    opacity: 1;
    visibility: visible;
}

.auth-panel-backdrop {
    position: absolute;
    inset: 0;
    z-index: 0;
    background: rgba(0,0,0,0.5);
    cursor: pointer;
}

.auth-panel-card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 400px;
    background: #fff;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.35);
    animation: authPanelIn 0.3s ease;
    pointer-events: auto;
}

@keyframes authPanelIn {
    from {
        opacity: 0;
        transform: scale(0.96) translateY(-10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.auth-panel-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border: none;
    background: #f0f0f0;
    border-radius: 50%;
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
    color: #666;
    transition: background 0.2s, color 0.2s;
}

.auth-panel-close:hover {
    background: #e0e0e0;
    color: #333;
}

.auth-panel-title {
    font-size: 1.5rem;
    color: #667eea;
    margin-bottom: 20px;
    text-align: center;
}

.auth-panel-heading {
    font-size: 1.25rem;
    margin-bottom: 8px;
    color: #333;
}

/* Auth panel: inputs and labels must be readable on white card */
.auth-panel-card .input {
    background: #f5f5f5;
    border: 1px solid #ddd;
    color: #222;
}

.auth-panel-card .input::placeholder {
    color: #888;
}

.auth-panel-card .input:focus {
    border-color: #4CAF50;
    background: #fff;
}

.auth-panel-card label {
    color: #333;
}

.auth-panel-card .login-subtitle,
.auth-panel-card .signup-note {
    color: #666;
}

.auth-panel-card .error-message {
    color: #c62828;
}

.auth-panel-card .success-message {
    color: #2e7d32;
}

/* Legacy login card (used inside auth panel) */
.login-card {
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.login-title {
    font-size: 2.2em;
    margin-bottom: 8px;
    color: #667eea;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.login-subtitle {
    font-size: 0.9em;
    color: #666;
    margin-bottom: 20px;
    font-weight: 400;
}

.signup-note {
    font-size: 0.8em;
    color: #999;
    margin-top: 15px;
    line-height: 1.4;
}

/* Homepage Section */
.homepage-section {
    width: 100%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

.homepage-container {
    max-width: 1600px;
    width: 100%;
    animation: fadeIn 0.6s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hero Section */
.hero-section {
    text-align: center;
    padding: 60px 20px;
    margin-bottom: 80px;
}

.hero-content {
    max-width: 1100px;
    margin: 0 auto;
}

.hero-title {
    font-size: 4em;
    font-weight: 700;
    color: white;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.hero-icon {
    font-size: 1.2em;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.hero-subtitle {
    font-size: 1.8em;
    color: rgba(255,255,255,0.95);
    margin-bottom: 20px;
    font-weight: 300;
}

.hero-description {
    font-size: 1.2em;
    color: rgba(255,255,255,0.9);
    line-height: 1.6;
    margin-bottom: 40px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.cta-button {
    background: white;
    color: #667eea;
    border: none;
    padding: 16px 40px;
    font-size: 1.1em;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

.cta-button:active {
    transform: translateY(0);
}

.cta-arrow {
    transition: transform 0.3s ease;
}

.cta-button:hover .cta-arrow {
    transform: translateX(5px);
}

/* Features Section */
.features-section {
    background: white;
    border-radius: 20px;
    padding: 60px 40px;
    margin-bottom: 60px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

.features-title {
    text-align: center;
    font-size: 2.5em;
    color: #333;
    margin-bottom: 50px;
    font-weight: 700;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature-card {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    border-color: #667eea;
}

.feature-icon {
    font-size: 3em;
    margin-bottom: 20px;
    display: block;
}

.feature-name {
    font-size: 1.4em;
    color: #333;
    margin-bottom: 15px;
    font-weight: 600;
}

.feature-description {
    color: #666;
    line-height: 1.6;
    font-size: 0.95em;
}

/* Benefits Section */
.benefits-section {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 50px 40px;
    margin-bottom: 60px;
}

.benefits-title {
    text-align: center;
    font-size: 2.5em;
    color: white;
    margin-bottom: 40px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.benefits-list {
    max-width: 960px;
    margin: 0 auto;
}

.benefit-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 0;
    font-size: 1.1em;
    color: white;
}

.benefit-check {
    background: #4CAF50;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2em;
    flex-shrink: 0;
}

/* CTA Section */
.cta-section {
    text-align: center;
    padding: 60px 20px;
}

.cta-title {
    font-size: 2.5em;
    color: white;
    margin-bottom: 20px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.cta-text {
    font-size: 1.2em;
    color: rgba(255,255,255,0.9);
    margin-bottom: 30px;
}

.cta-button-large {
    background: white;
    color: #667eea;
    border: none;
    padding: 18px 50px;
    font-size: 1.2em;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.cta-button-large:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

.cta-button-large:hover .cta-arrow {
    transform: translateX(5px);
}

/* Login Section */
.login-section {
    width: 100%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

.login-container {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    width: 100%;
    max-width: 400px;
    text-align: center;
    position: relative;
    animation: slideIn 0.4s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.back-button {
    position: absolute;
    top: 20px;
    left: 20px;
    background: transparent;
    border: 2px solid #667eea;
    color: #667eea;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.9em;
    transition: all 0.3s ease;
}

.back-button:hover {
    background: #667eea;
    color: white;
}

.login-container h1 {
    font-size: 2em;
    margin-bottom: 10px;
    color: #667eea;
}

.login-container h2 {
    font-size: 1.5em;
    margin-bottom: 30px;
    color: #333;
}

/* Landing + auth panel responsive */
@media (max-width: 768px) {
    .landing-header {
        padding: 10px 16px;
        max-width: 100%;
    }
    
    .landing-main {
        padding: 12px 16px 24px;
        max-width: 100%;
    }
    
    .landing-benefits {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .benefit-row {
        padding: 16px;
    }
    
    .landing-hero-headline {
        font-size: 1.35rem;
    }
    
    .landing-logo-large .logo-text {
        font-size: 1.7em;
    }
    
    .landing-logo-large .logo-icon {
        font-size: 1.8em;
    }
    
    .landing-proof {
        flex-direction: row;
        gap: 16px;
        padding: 18px 16px;
        margin-top: 18px;
    }
    
    .landing-proof-item:not(:last-child) {
        border-right: none;
    }
    
    .landing-proof-num {
        font-size: 1.5em;
    }
    
    .landing-proof-label {
        font-size: 0.78em;
    }
    
    .auth-panel-card {
        padding: 20px;
        max-height: 90vh;
        overflow-y: auto;
    }
    
    .feature-detail-cards {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .feature-detail-card {
        padding: 12px 14px;
    }
    
    .feature-details-title {
        font-size: 0.9em;
    }
}

@media (max-width: 480px) {
    .landing-btn {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
    
    .landing-cta {
        padding: 8px 16px;
        font-size: 0.85rem;
    }
    
    .landing-hero-headline {
        font-size: 1.25rem;
    }
    
    .benefit-row {
        padding: 8px 10px;
    }
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.login-form h2 {
    font-size: 1.5em;
    margin-bottom: 20px;
    color: #333;
}

.login-form .input {
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s;
}

.login-form .input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.error-message {
    color: #f44336;
    font-size: 0.9em;
    text-align: left;
    padding: 8px;
    background: #fff5f5;
    border-radius: 6px;
    border: 1px solid #ffcdd2;
}

.success-message {
    color: #4CAF50;
    font-size: 0.9em;
    text-align: left;
    padding: 8px;
    background: #f1f8f4;
    border-radius: 6px;
    border: 1px solid #c8e6c9;
}

.auth-mode-btn.active {
    background: #4CAF50 !important;
    color: white !important;
    border-color: #4CAF50 !important;
}

.auth-mode-btn:not(.active) {
    background: transparent !important;
    color: #666 !important;
    border-color: #666 !important;
}

.login-info {
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    font-size: 0.85em;
    color: #666;
}

.login-info code {
    background: #e9ecef;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: monospace;
}

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    padding: 0;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #e0e0e0;
}

.modal-header h2 {
    margin: 0;
    color: #333;
    font-size: 1.5em;
}

.modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: #666;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s;
}

.modal-close:hover {
    background: #f0f0f0;
    color: #333;
}

.modal-body {
    padding: 20px;
}

/* Edit Clock Modal - dark theme to match app */
.edit-clock-modal-overlay .edit-clock-modal-content {
    background: rgba(30, 41, 59, 0.98);
    border: 1px solid rgba(255,255,255,0.15);
}
.edit-clock-modal-overlay .modal-header {
    border-bottom-color: rgba(255,255,255,0.15);
}
.edit-clock-modal-overlay .modal-header h2 {
    color: rgba(255,255,255,0.95);
}
.edit-clock-modal-overlay .modal-close {
    color: rgba(255,255,255,0.8);
}
.edit-clock-modal-overlay .modal-close:hover {
    background: rgba(255,255,255,0.15);
    color: #fff;
}
.edit-clock-modal-overlay .modal-body {
    color: rgba(255,255,255,0.9);
}
.edit-clock-modal-overlay .modal-body label {
    color: rgba(255,255,255,0.9);
}
.edit-clock-modal-overlay .modal-body .input {
    background: rgba(0,0,0,0.3);
    color: rgba(255,255,255,0.95);
    border-color: rgba(255,255,255,0.2);
}
.edit-clock-modal-overlay .modal-body .input::placeholder {
    color: rgba(255,255,255,0.5);
}
.edit-clock-modal-overlay .modal-body .input:focus {
    border-color: rgba(99, 102, 241, 0.6);
    outline: none;
}

/* User Info in Sidebar */
.user-info {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255,255,255,0.2);
}

.user-name {
    font-size: 0.9em;
    font-weight: 600;
    margin-bottom: 5px;
}

.user-role {
    font-size: 0.8em;
    opacity: 0.9;
    margin-bottom: 10px;
}

.btn-logout {
    width: 100%;
    padding: 8px;
    background: rgba(255,255,255,0.2);
    color: white;
    border: 1px solid rgba(255,255,255,0.3);
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85em;
    transition: all 0.3s;
}

.btn-logout:hover {
    background: rgba(255,255,255,0.3);
}

/* User Accounts Management */
.user-accounts-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.user-account-item {
    padding: 15px;
    background: rgba(255,255,255,0.08);
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.15);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 15px;
    flex-wrap: wrap;
    color: rgba(255,255,255,0.95);
}

.user-account-info {
    flex: 1;
    min-width: 200px;
}

.user-account-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.user-account-name {
    font-size: 1.1em;
    font-weight: 600;
    color: rgba(255,255,255,0.95);
}

.user-account-role {
    font-size: 0.85em;
    padding: 3px 8px;
    background: #667eea;
    color: white;
    border-radius: 12px;
}

.user-account-details {
    font-size: 0.9em;
    color: rgba(255,255,255,0.85);
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.user-account-details code {
    background: rgba(0,0,0,0.3);
    color: rgba(255,255,255,0.95);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9em;
    border: 1px solid rgba(255,255,255,0.1);
}

.user-account-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.user-account-actions .btn-small {
    padding: 6px 12px;
    font-size: 0.85em;
}

.user-activity-section {
    margin-top: 10px;
}

.user-activity-history {
    font-size: 0.85em;
    margin-top: 10px;
    padding: 10px;
    background: rgba(0,0,0,0.2);
    border-radius: 6px;
    max-height: 200px;
    overflow-y: auto;
    color: rgba(255,255,255,0.9);
    border: 1px solid rgba(255,255,255,0.1);
}
.user-activity-history .activity-row {
    font-size: 0.85em;
    padding: 4px 0;
    border-bottom: 1px solid rgba(255,255,255,0.15);
    color: rgba(255,255,255,0.9);
}
.user-accounts-list .list-placeholder {
    color: rgba(255,255,255,0.8);
    text-align: center;
    padding: 20px;
}

.btn-tertiary {
    background: #6c757d;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85em;
    transition: all 0.2s;
}

.btn-tertiary:hover {
    background: #5a6268;
}

/* SOP Styles */
.sop-content {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.sop-section {
    padding: 20px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid rgba(102, 126, 234, 0.8);
    color: #fff;
}

.sop-section h3 {
    margin: 0 0 15px 0;
    color: #fff;
    font-size: 1.2em;
}

.sop-highlight {
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 8px;
    text-align: center;
    font-size: 1.3em;
    margin: 15px 0;
    font-weight: bold;
}

.sop-steps {
    margin: 15px 0;
    padding-left: 25px;
}

.sop-steps li {
    margin-bottom: 10px;
    line-height: 1.6;
    color: rgba(255,255,255,0.9);
}

.sop-steps code {
    background: rgba(255,255,255,0.15);
    color: #fff;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9em;
}

.sop-percentages {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
    margin-top: 15px;
}

.sop-percentage-item {
    padding: 10px;
    background: rgba(255,255,255,0.08);
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.2);
    text-align: center;
    font-weight: 500;
    color: #fff;
}

.sop-formulas {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 15px;
}

.sop-formula-item {
    padding: 12px;
    background: rgba(255,255,255,0.08);
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff;
}

.sop-formula-item code {
    background: rgba(255,255,255,0.15);
    padding: 4px 8px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 1em;
    color: #a5b4fc;
    font-weight: 600;
}

.sop-cart-sizes {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
    margin-top: 15px;
}

.sop-cart-size-item {
    padding: 10px;
    background: rgba(255,255,255,0.08);
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.2);
    text-align: center;
    font-weight: 500;
    color: #fff;
}

.sop-example {
    padding: 15px;
    background: rgba(255,255,255,0.08);
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.2);
    margin-top: 15px;
    color: #fff;
}

.sop-example ul {
    margin: 10px 0 0 20px;
    padding: 0;
}

.sop-example li {
    margin-bottom: 8px;
    font-family: monospace;
    color: rgba(255,255,255,0.9);
}

.sop-checklist {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 15px;
}

.sop-checklist label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: rgba(255,255,255,0.08);
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.2);
    cursor: pointer;
    color: #fff;
}

.sop-checklist input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* SOP List Styles - List Layout */
.sops-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.sops-list .sop-item {
    margin-bottom: 0;
    width: 100%;
    border-left: 4px solid #667eea !important;
    padding-left: 20px !important;
    margin-left: 0 !important;
    position: relative;
}

#sopTab .main-content {
    display: flex !important;
    flex-direction: column !important;
    grid-template-columns: none !important;
    gap: 12px !important;
}

.sops-list .sop-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.2);
    flex-wrap: wrap;
    gap: 10px;
    transition: background 0.2s;
}

.sops-list .sop-item-header h2 {
    margin: 0;
    color: #fff;
    font-size: 1.2em;
    font-weight: 600;
    flex: 1;
    user-select: none;
}

.sops-list .sop-item-header:hover {
    background: rgba(255,255,255,0.1);
    border-radius: 8px;
    padding: 5px;
    margin: -5px;
}

.sop-toggle-icon {
    font-size: 0.8em;
    color: #a5b4fc;
    transition: transform 0.2s;
    display: inline-block;
}

.sop-meta {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.sop-category-badge {
    padding: 3px 10px;
    background: #667eea;
    color: white;
    border-radius: 10px;
    font-size: 0.8em;
    font-weight: 600;
}

.sop-date {
    font-size: 0.8em;
    color: rgba(255,255,255,0.8);
}

.sop-actions {
    display: flex;
    gap: 8px;
}

.sops-list .sop-item .sop-content {
    margin-top: 0;
    padding-top: 0;
}

/* SOP list is already responsive - no media query needed */

/* Questions / Q&A Styles - Chat-like Interface */
.questions-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-height: 70vh;
    overflow-y: auto;
    padding: 10px;
}

.question-item {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    border-left: 4px solid #667eea;
    transition: transform 0.2s, box-shadow 0.2s;
}

.question-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.question-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 10px;
}

.question-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.question-author {
    font-weight: 600;
    color: #667eea;
    font-size: 0.9em;
}

.question-date {
    font-size: 0.8em;
    color: #666;
}

.question-status-badge {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
    text-transform: uppercase;
}

.question-status-badge.status-open {
    background: #fbbf24;
    color: #78350f;
}

.question-status-badge.status-answered {
    background: #10b981;
    color: white;
}

.question-status-badge.status-closed {
    background: #6b7280;
    color: white;
}

.question-text {
    font-size: 1em;
    color: #333;
    line-height: 1.6;
    margin-bottom: 15px;
    padding: 10px;
    background: white;
    border-radius: 6px;
}

.answers-section {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #e0e0e0;
}

.answers-header {
    font-weight: 600;
    color: #667eea;
    margin-bottom: 10px;
    font-size: 0.9em;
}

.answer-item {
    background: white;
    border-radius: 6px;
    padding: 12px;
    margin-bottom: 10px;
    border-left: 3px solid #10b981;
}

.answer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    flex-wrap: wrap;
    gap: 8px;
}

.answer-author {
    font-weight: 600;
    color: #10b981;
    font-size: 0.85em;
}

.answer-date {
    font-size: 0.75em;
    color: #666;
}

.answer-text {
    color: #333;
    line-height: 1.5;
    font-size: 0.9em;
}

.answer-form {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #e0e0e0;
}

.answer-input {
    margin-bottom: 10px;
    font-size: 0.9em;
}

.question-actions {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #e0e0e0;
}

.btn-delete-answer {
    background: #ef4444;
    color: white;
    border: none;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.btn-delete-answer:hover {
    background: #dc2626;
}

/* App Container with Sidebar Layout */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar Toggle Arrow - Visible on desktop, hidden on mobile initially */
.sidebar-toggle-arrow {
    display: none;
}

/* Desktop: Show toggle arrow on the right edge of sidebar */
@media (min-width: 769px) {
    .sidebar-toggle-arrow {
        display: flex;
        align-items: center;
        justify-content: center;
        position: fixed;
        left: 250px; /* Start at sidebar width */
        top: 50%;
        transform: translateY(-50%);
        width: 30px;
        height: 60px;
        background: rgba(255,255,255,0.08);
        color: rgba(255,255,255,0.9);
        border: 1px solid rgba(255,255,255,0.12);
        border-radius: 0 8px 8px 0;
        font-size: 1.5em;
        cursor: pointer;
        box-shadow: 2px 0 12px rgba(0,0,0,0.3);
        z-index: 1001;
        transition: all 0.3s ease;
    }
    
    .sidebar-toggle-arrow:hover {
        background: rgba(255,255,255,0.14);
        border-color: rgba(255,255,255,0.2);
        box-shadow: 2px 0 16px rgba(0,0,0,0.35);
    }
    
    .sidebar-toggle-arrow .arrow-icon {
        transition: transform 0.3s ease;
    }
    
    /* Move arrow when sidebar is collapsed */
    .sidebar.collapsed ~ .sidebar-toggle-arrow,
    body.sidebar-collapsed .sidebar-toggle-arrow {
        left: 60px; /* Move to collapsed sidebar width */
    }
    
    /* Collapsed sidebar state */
    .sidebar.collapsed {
        width: 60px;
    }
    
    .sidebar.collapsed .sidebar-header h1,
    .sidebar.collapsed .tab-label,
    .sidebar.collapsed .nav-group-label {
        display: none;
    }
    
    .sidebar.collapsed .sidebar-header {
        padding: 20px 12px;
        justify-content: center;
    }
    
    .sidebar.collapsed .nav-tab {
        justify-content: center;
        padding: 12px;
    }
    
    .sidebar.collapsed .tab-icon {
        font-size: 1.5em;
    }
    
    /* Adjust main content margin when sidebar is collapsed */
    body.sidebar-collapsed .main-content,
    body.sidebar-collapsed .main-content-area {
        margin-left: 60px;
    }
    
    /* Ensure sidebar transitions smoothly */
    .sidebar {
        transition: width 0.3s ease;
    }
    
    .sidebar .sidebar-header,
    .sidebar .nav-tab,
    .sidebar .nav-group-label {
        transition: opacity 0.2s ease;
    }
}

/* Left Sidebar - dark to match landing */
.sidebar {
    width: 250px;
    background: rgba(26, 27, 46, 0.98);
    backdrop-filter: blur(10px);
    border-right: 1px solid rgba(255,255,255,0.08);
    box-shadow: 2px 0 20px rgba(0,0,0,0.3);
    position: fixed;
    left: 0;
    top: 0;
    height: 100vh;
    z-index: 1000;
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    padding: 20px 18px;
    background: rgba(15, 52, 96, 0.5);
    border-bottom: 1px solid rgba(255,255,255,0.08);
    color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.sidebar-header h1 {
    font-size: 1.5em;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.sidebar-header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
}

.user-clock-in-timer {
    font-size: 0.85em;
    font-weight: 600;
    color: rgba(255,255,255,0.95);
    text-align: right;
    white-space: nowrap;
}

.user-clock-in-timer .user-clock-in-timer-label {
    display: block;
    font-size: 0.75em;
    opacity: 0.95;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.user-clock-in-timer .user-clock-in-timer-value {
    font-size: 1.15em;
    font-variant-numeric: tabular-nums;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.2);
}

.user-clock-in-timer .user-clock-in-timer-out {
    font-size: 0.85em;
    opacity: 0.9;
}

.sidebar-nav {
    flex: 1;
    padding: 15px 0;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* Sidebar scrollbar - themed to match dark sidebar (still scrollable) */
.sidebar-nav,
.sidebar {
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.25) rgba(255, 255, 255, 0.06);
}
.sidebar-nav::-webkit-scrollbar,
.sidebar::-webkit-scrollbar {
    width: 6px;
}
.sidebar-nav::-webkit-scrollbar-track,
.sidebar::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.06);
    border-radius: 3px;
}
.sidebar-nav::-webkit-scrollbar-thumb,
.sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.25);
    border-radius: 3px;
}
.sidebar-nav::-webkit-scrollbar-thumb:hover,
.sidebar::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.4);
}

@media (max-width: 768px) {
    .sidebar-nav {
        padding-bottom: 40px; /* Extra padding at bottom so last items are visible */
    }
}

.nav-group {
    margin-bottom: 12px;
}

.nav-group:last-child {
    margin-bottom: 0;
}

.nav-group-label {
    font-size: 0.65em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: rgba(255,255,255,0.5);
    padding: 5px 15px 3px 15px;
    font-weight: 600;
    margin-bottom: 3px;
}

.nav-tab {
    width: 100%;
    padding: 12px 15px;
    border: none;
    background: transparent;
    text-align: left;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s;
    color: rgba(255,255,255,0.8);
    font-size: 14px;
    font-weight: 500;
    border-left: 3px solid transparent;
}

.nav-tab:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
}

.nav-tab.active {
    background: rgba(255,255,255,0.1);
    color: #fff;
    border-left-color: #4CAF50;
    font-weight: 600;
}

.tab-icon {
    font-size: 1.3em;
    width: 24px;
    text-align: center;
    flex-shrink: 0;
}

.tab-label {
    flex: 1;
}

/* Main Content Area - dark to match landing */
.main-content-area {
    flex: 1;
    margin-left: 250px;
    padding: 24px;
    min-height: 100vh;
    transition: margin-left 0.3s ease;
    background: transparent;
}

/* Adjust main content when sidebar is collapsed on desktop */
@media (min-width: 769px) {
    body.sidebar-collapsed .main-content-area {
        margin-left: 60px; /* Collapsed sidebar width */
    }
}

.tab-content {
    display: none !important;
}

.tab-content.active {
    display: block !important;
}

.content-header {
    text-align: center;
    color: #fff;
    margin-bottom: 24px;
}

.content-header h2 {
    font-size: 2em;
    margin-bottom: 8px;
    font-weight: 700;
}

.subtitle {
    font-size: 1em;
    color: rgba(255,255,255,0.85);
}

.main-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 20px;
}

.main-content.inventory-unified {
    display: block;
    gap: 0;
}

.card {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.2);
    transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.inventory-unified .card {
    box-shadow: 0 2px 12px rgba(0,0,0,0.15);
}

.card:hover {
    transform: translateY(-2px);
    border-color: rgba(255,255,255,0.15);
    box-shadow: 0 6px 20px rgba(0,0,0,0.25);
}

.card h2 {
    color: #fff;
    margin-bottom: 16px;
    font-size: 1.35em;
    border-bottom: 1px solid rgba(255,255,255,0.15);
    padding-bottom: 10px;
}

/* Settings tab: notes and descriptions readable on dark cards */
.settings-note {
    margin-top: 15px;
    padding: 10px 14px;
    background: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.95);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 8px;
    font-size: 0.9em;
}
.settings-description {
    color: rgba(255,255,255,0.9);
    margin-bottom: 15px;
    font-size: 0.9em;
}

/* Inner panels inside cards (e.g. Users tab) - dark theme readable */
.card-inner-box {
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    color: rgba(255,255,255,0.95);
}
.card-inner-box h3 {
    margin: 0 0 15px 0;
    font-size: 1em;
    color: rgba(255,255,255,0.95);
}
.card-inner-box p {
    color: rgba(255,255,255,0.9);
    font-size: 0.9em;
    margin-bottom: 10px;
}
.card-inner-box-warning {
    background: rgba(255, 193, 7, 0.15);
    border-color: rgba(255, 193, 7, 0.4);
}
.card-inner-box-warning h3,
.card-inner-box-warning p {
    color: rgba(255,255,255,0.95);
}
.card-inner-results {
    padding: 10px;
    background: rgba(0,0,0,0.2);
    border-radius: 6px;
    color: rgba(255,255,255,0.9);
}
.card-inner-hint {
    color: rgba(255,255,255,0.75);
    font-size: 0.85em;
    display: block;
    margin-top: 4px;
}

/* Checkout & Inventory – dark theme panels and lists */
.last-scanned-box {
    margin-top: 12px;
    margin-bottom: 12px;
    padding: 16px 18px;
    background: rgba(16, 185, 129, 0.2);
    border: 2px solid rgba(16, 185, 129, 0.5);
    border-radius: 8px;
    color: rgba(255,255,255,0.95);
}
.last-scanned-box .last-scanned-label {
    font-size: 0.75em;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(16, 185, 129, 0.95);
    margin-bottom: 6px;
}
.last-scanned-box .last-scanned-name {
    font-size: 1.25em;
    font-weight: 700;
    color: rgba(255,255,255,0.95);
    margin-bottom: 4px;
}
.last-scanned-box .last-scanned-detail,
.last-scanned-box .last-scanned-meta {
    font-size: 0.95em;
    color: rgba(255,255,255,0.85);
}
.scan-error-box {
    margin-top: 8px;
    padding: 10px 12px;
    background: rgba(185, 28, 28, 0.25);
    border: 1px solid rgba(248, 113, 113, 0.4);
    border-left: 4px solid #dc2626;
    border-radius: 4px;
    color: #fecaca;
    font-size: 0.9em;
    font-weight: 500;
}
.card-hint {
    color: rgba(255,255,255,0.75);
    font-size: 0.8em;
    display: block;
    margin-bottom: 8px;
}
#currentOrderItems .list-placeholder {
    color: rgba(255,255,255,0.8);
    text-align: center;
    padding: 40px;
}
#receiptsList .list-placeholder {
    color: rgba(255,255,255,0.8);
    text-align: center;
    padding: 40px;
}
#checkoutQRCodeList .list-placeholder {
    color: rgba(255,255,255,0.8);
    text-align: center;
    padding: 40px;
}
.organizations-list .list-placeholder {
    color: rgba(255,255,255,0.8);
    text-align: center;
    padding: 20px;
}
.organizations-list .list-error {
    color: #fca5a5;
    text-align: center;
    padding: 20px;
}
.organization-item {
    margin-bottom: 15px;
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    padding: 15px;
    background: rgba(255,255,255,0.06);
    color: rgba(255,255,255,0.95);
}
.organization-item h3 {
    margin: 0;
    font-size: 1.1em;
    color: rgba(255,255,255,0.95);
}
.organization-item .org-meta {
    font-size: 0.85em;
    color: rgba(255,255,255,0.8);
    margin-top: 5px;
}
.organization-item .org-users-panel {
    margin-top: 10px;
    padding: 10px;
    background: rgba(0,0,0,0.2);
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.9);
}
.organization-item .org-users-panel .list-placeholder {
    padding: 10px;
}
.organization-item .org-user-row {
    padding: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: rgba(255,255,255,0.95);
}
.organization-item .org-user-row:last-child {
    border-bottom: none;
}
.organization-item .org-user-detail {
    font-size: 0.85em;
    color: rgba(255,255,255,0.75);
    margin-top: 4px;
}
.organization-item .org-user-detail code {
    background: rgba(0,0,0,0.3);
    padding: 2px 4px;
    border-radius: 3px;
    color: rgba(255,255,255,0.9);
}
#currentOrderItems .order-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    border-bottom: 1px solid rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.95);
}
#currentOrderItems .order-item-detail {
    font-size: 0.85em;
    color: rgba(255,255,255,0.75);
}
#currentOrderItems .order-item-qty {
    font-size: 0.9em;
    color: rgba(255,255,255,0.85);
}
#currentOrderItems .order-item-subtotal {
    font-weight: 600;
    color: #34d399;
}
#currentOrderItems .order-item-warning {
    font-size: 0.8em;
    color: #fca5a5;
    margin-top: 4px;
}
.qr-display-panel {
    padding: 15px;
    background: rgba(0,0,0,0.4);
    border-radius: 8px;
    border: 2px solid rgba(255, 152, 0, 0.5);
    color: #fff;
}
.qr-display-panel,
.qr-display-panel #qrCodeInfo,
.qr-display-panel .qr-info-inner,
.qr-display-panel .qr-info-inner div {
    color: rgba(255,255,255,0.95);
}
.qr-display-panel .qr-info-inner {
    text-align: left;
    background: rgba(0,0,0,0.25);
    padding: 12px 14px;
    border-radius: 6px;
    margin-top: 10px;
    border: 1px solid rgba(255,255,255,0.1);
}
.qr-display-panel .qr-info-inner .qr-info-muted {
    color: rgba(255,255,255,0.8);
    font-size: 0.85em;
}
.qr-display-panel .qr-info-inner .qr-info-small {
    color: rgba(255,255,255,0.75);
    font-size: 0.8em;
}
.qr-display-panel #qrCodeCanvas {
    background: #fff;
    border-radius: 4px;
    padding: 10px;
}
.input-readonly {
    background: rgba(0,0,0,0.25) !important;
    color: rgba(255,255,255,0.9) !important;
    border-color: rgba(255,255,255,0.15) !important;
}
.receipt-item {
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    margin-bottom: 10px;
    background: rgba(255,255,255,0.06);
    color: rgba(255,255,255,0.95);
}
.receipt-item summary {
    cursor: pointer;
    padding: 12px 15px;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    color: rgba(255,255,255,0.95);
}
.receipt-item .receipt-meta {
    font-size: 0.9em;
    color: rgba(255,255,255,0.75);
}
.receipt-item .receipt-total {
    font-weight: 700;
    color: #34d399;
}
.receipt-item .receipt-body {
    padding: 12px 15px 15px;
    border-top: 1px solid rgba(255,255,255,0.1);
    background: rgba(0,0,0,0.15);
    border-radius: 0 0 8px 8px;
    color: rgba(255,255,255,0.9);
}
.receipt-item .receipt-body .receipt-date {
    font-size: 0.85em;
    color: rgba(255,255,255,0.7);
}
.receipt-item .receipt-line {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 0.9em;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.9);
}
.receipt-item .receipt-line .line-detail {
    font-size: 0.85em;
    color: rgba(255,255,255,0.7);
}
.receipt-item .receipt-footer {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid rgba(255,255,255,0.15);
    font-weight: 700;
    display: flex;
    justify-content: space-between;
    color: rgba(255,255,255,0.95);
}
.receipt-item .receipt-footer .total-amount {
    color: #34d399;
}
#inventoryTestResultsSection.dark-panel {
    background: rgba(255,255,255,0.06);
    border-color: rgba(255,255,255,0.15);
}
#inventoryTestResultsDisplay.dark-panel {
    background: rgba(0,0,0,0.3);
    color: rgba(255,255,255,0.9);
    border-radius: 6px;
    padding: 15px;
    font-family: monospace;
    font-size: 0.9em;
}

.qr-placeholder-img {
    width: 80px;
    height: 80px;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 4px;
    background: rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.6);
    font-size: 0.7em;
}
.inventory-item .qr-data-code {
    background: rgba(0,0,0,0.3);
    color: rgba(255,255,255,0.95);
    padding: 2px 4px;
    border-radius: 3px;
    font-size: 0.8em;
    border: 1px solid rgba(255,255,255,0.1);
}
.qr-details-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 4px;
    padding: 6px;
    font-size: 0.8em;
    background: rgba(0,0,0,0.2);
    border-radius: 4px;
    color: rgba(255,255,255,0.9);
}

/* Inventory QR Codes tab – log list */
#qrCodeLog .list-placeholder {
    color: rgba(255,255,255,0.8);
    text-align: center;
    padding: 30px 20px;
}
.qr-log-item .qr-log-detail {
    color: rgba(255,255,255,0.88);
}

/* Inventory QR Codes tab – Trash */
.trash-header {
    padding: 8px 12px;
    background: rgba(239, 68, 68, 0.2);
    border-bottom: 2px solid rgba(239, 68, 68, 0.5);
    margin-bottom: 10px;
    border-radius: 3px 3px 0 0;
    color: rgba(255,255,255,0.95);
}
.trash-header-label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9em;
    color: rgba(255,255,255,0.95);
}
#qrCodeTrash .list-placeholder {
    color: rgba(255,255,255,0.8);
    text-align: center;
    padding: 30px 20px;
}

/* Inventory Items list – Select All header */
.inventory-list-header {
    padding: 8px 12px;
    background: rgba(102, 126, 234, 0.2);
    border-bottom: 2px solid rgba(102, 126, 234, 0.5);
    margin-bottom: 10px;
    border-radius: 3px 3px 0 0;
    color: rgba(255,255,255,0.95);
}
.inventory-list-header label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9em;
    color: rgba(255,255,255,0.95);
}
#inventoryItems .list-placeholder,
#inventoryItems .empty-state {
    color: rgba(255,255,255,0.8);
    text-align: center;
    padding: 30px 20px;
}
.inventory-item .item-details input[type="number"] {
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.2);
    color: rgba(255,255,255,0.95);
    border-radius: 4px;
    padding: 4px 8px;
}

.inventory-item.trash-item {
    background: rgba(239, 68, 68, 0.12);
    border-left: 3px solid #ef4444;
    border-radius: 3px;
    color: rgba(255,255,255,0.95);
}
.trash-item .trash-item-label {
    font-weight: 600;
    font-size: 0.95em;
    color: rgba(255,255,255,0.95);
}
.trash-item .trash-info-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    font-size: 0.8em;
    color: rgba(255,255,255,0.8);
    margin-bottom: 3px;
}
.trash-item .trash-info-cat {
    color: #a5b4fc;
}
.trash-item .trash-info-meta {
    color: rgba(255,255,255,0.8);
}
.trash-item .trash-data-preview {
    font-size: 0.75em;
    color: rgba(255,255,255,0.7);
    font-family: monospace;
    word-break: break-all;
}
.trash-item .trash-dates {
    font-size: 0.7em;
    color: rgba(255,255,255,0.7);
    margin-top: 2px;
}
.trash-item .trash-deleted-date {
    color: #fca5a5;
}

.form-group {
    margin-bottom: 15px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: rgba(255,255,255,0.9);
}

.input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 8px;
    font-size: 14px;
    background: rgba(0,0,0,0.25);
    color: #fff;
    transition: border-color 0.2s, background 0.2s;
}

.input::placeholder {
    color: rgba(255,255,255,0.5);
}

.input:focus {
    outline: none;
    border-color: rgba(76, 175, 80, 0.8);
    background: rgba(0,0,0,0.35);
}

select.input {
    cursor: pointer;
    appearance: auto;
    background: rgba(0,0,0,0.25);
    color: #fff;
}

select.input:focus {
    background: rgba(0,0,0,0.35);
}

select.input option {
    background: #1a1b2e;
    color: #fff;
}

textarea.input {
    resize: vertical;
    min-height: 80px;
    background: rgba(0,0,0,0.25);
    color: #fff;
}

textarea.input:focus {
    background: rgba(0,0,0,0.35);
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary {
    background: #4CAF50;
    color: #fff;
}

.btn-primary:hover {
    background: #43a047;
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.35);
}

.btn-secondary {
    background: rgba(255,255,255,0.1);
    color: #fff;
    border: 1px solid rgba(255,255,255,0.2);
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.16);
    border-color: rgba(255,255,255,0.3);
}

.btn-danger {
    background: #f44336;
    color: white;
    padding: 8px 16px;
    font-size: 14px;
}

.btn-danger:hover {
    background: #da190b;
}

.btn-small {
    padding: 6px 12px;
    font-size: 12px;
}

/* Projects Compact Layout */
.projects-compact {
    display: block;
}

.projects-compact-top {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 12px;
}

.projects-compact-bottom {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 12px;
}

.projects-compact-card {
    padding: 12px 15px !important;
    margin: 0 !important;
}

.projects-compact-card h3 {
    font-size: 1em;
    margin-bottom: 8px;
    font-weight: 600;
}

.projects-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.projects-list-compact {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 8px;
}

.project-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: rgba(0,0,0,0.25);
    border-radius: 6px;
    border-left: 3px solid rgba(102, 126, 234, 0.8);
    font-size: 0.9em;
    color: #fff;
}

.project-item.active {
    background: rgba(102, 126, 234, 0.25);
    border-left-color: #a5b4fc;
}

.project-name {
    font-weight: 600;
    color: #fff;
}

.summary-controls {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr auto;
    gap: 10px;
    margin-bottom: 20px;
}

.summary-results {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.summary-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
}

.summary-card h3 {
    font-size: 0.9em;
    opacity: 0.9;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.summary-card .value {
    font-size: 2em;
    font-weight: bold;
}

#summaryResults .summary-card-stat {
    background: rgba(0,0,0,0.25);
    border: 1px solid rgba(255,255,255,0.15);
    color: rgba(255,255,255,0.95);
}
#summaryResults .summary-card-stat .value { color: rgba(255,255,255,0.95); }
#summaryResults .summary-card-stat.summary-card-cost { border-left: 3px solid #818cf8; }
#summaryResults .summary-card-stat.summary-card-cost h3 { color: #a5b4fc; }
#summaryResults .summary-card-stat.summary-card-hours { border-left: 3px solid #0ea5e9; }
#summaryResults .summary-card-stat.summary-card-hours h3 { color: #7dd3fc; }
#summaryResults .summary-card-stat.summary-card-items { border-left: 3px solid #10b981; }
#summaryResults .summary-card-stat.summary-card-items h3 { color: #6ee7b7; }
#summaryResults .summary-card-stat.summary-card-entries { border-left: 3px solid #f59e0b; }
#summaryResults .summary-card-stat.summary-card-entries h3 { color: #fcd34d; }

.entry-description { margin-top: 8px; font-size: 0.85em; padding-top: 6px; border-top: 1px solid rgba(255,255,255,0.15); color: rgba(255,255,255,0.85); }
.progress-day-meta { font-size: 0.8em; margin-top: 4px; color: rgba(255,255,255,0.8); }

#projectsTab .list-placeholder { color: rgba(255,255,255,0.8); text-align: center; padding: 20px; }
#projectsTab #recentEntries .list-placeholder { padding: 15px; font-size: 0.9em; }
#projectsTab #dailyProgress .list-placeholder { padding: 20px; }

.daily-progress {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
}

.daily-progress-compact {
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 300px;
    overflow-y: auto;
}

.progress-day {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: rgba(0,0,0,0.25);
    border-radius: 6px;
    border-left: 3px solid #4CAF50;
    font-size: 0.9em;
    color: #fff;
}

.progress-date {
    font-weight: 600;
    color: #fff;
    font-size: 0.95em;
}

.progress-items {
    font-weight: 600;
    color: #4CAF50;
    font-size: 0.9em;
}

.entries-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
}

.entry-item {
    padding: 12px;
    background: rgba(0,0,0,0.25);
    border-radius: 6px;
    border-left: 3px solid rgba(102, 126, 234, 0.8);
    font-size: 0.9em;
    margin-bottom: 8px;
    color: #fff;
}

.entries-list-compact {
    max-height: 300px;
    overflow-y: auto;
}

.entries-list-compact .entry-item {
    padding: 10px 12px;
    margin-bottom: 6px;
}

.entry-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.entry-project {
    font-weight: 600;
    color: #a5b4fc;
}

.entry-date {
    color: rgba(255,255,255,0.85);
    font-size: 0.9em;
}

.entry-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 6px;
    font-size: 0.85em;
}

.entry-detail {
    color: rgba(255,255,255,0.85);
    font-size: 0.85em;
}

.entry-detail strong {
    color: #fff;
    font-weight: 600;
}


/* Time Clock Styles */
.employees-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.employee-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid rgba(102, 126, 234, 0.8);
    color: #fff;
}

.employee-item.clocked-in {
    background: rgba(76, 175, 80, 0.2);
    border-left-color: #4CAF50;
}

.employee-name {
    font-weight: 600;
    color: #fff;
    margin-right: 10px;
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    background: #4CAF50;
    color: white;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
    text-transform: uppercase;
}

.status-badge.out {
    background: #999;
}

/* Clock In/Out Test Results */
.clock-test-results {
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.15);
    font-size: 0.9em;
    color: #fff;
}

.test-results-summary {
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}

.test-results-summary strong {
    color: #fff;
}

.clock-test-results .test-result {
    padding: 6px 0;
    padding-left: 4px;
}

.clock-test-results .test-result.pass {
    color: #81c784;
}

.clock-test-results .test-result.fail {
    color: #ef9a9a;
    background: rgba(244, 67, 54, 0.2);
    margin: 4px -4px;
    padding: 6px 8px;
    border-radius: 4px;
}

.clock-status {
    margin: 20px 0;
    color: rgba(255,255,255,0.95);
}

.status-card {
    padding: 20px;
    border-radius: 8px;
    text-align: center;
}

.clocked-in-card {
    background: rgba(76, 175, 80, 0.2);
    border: 2px solid #4CAF50;
    color: #fff;
}

.clocked-in-card h3 {
    color: #fff;
    margin-bottom: 10px;
}

.clocked-out-card {
    background: rgba(244, 67, 54, 0.15);
    border: 2px solid #f44336;
    color: rgba(255,255,255,0.95);
}

.clocked-out-card h3 {
    color: #fff;
    margin-bottom: 10px;
}

.clock-buttons {
    display: flex;
    gap: 15px;
    margin: 20px 0;
}

.btn-large {
    flex: 1;
    padding: 20px;
    font-size: 18px;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

.current-session {
    margin-top: 20px;
}

.session-timer {
    text-align: center;
    padding: 24px;
    background: rgba(0, 0, 0, 0.35);
    border: 2px solid rgba(76, 175, 80, 0.6);
    border-radius: 12px;
    color: #fff;
}

.session-timer h3 {
    color: #fff;
    margin-bottom: 12px;
    font-size: 1.1em;
}

.timer-display {
    font-size: 3em;
    font-weight: bold;
    color: #4CAF50;
    font-family: 'Courier New', monospace;
    margin: 15px 0;
    text-shadow: 0 0 20px rgba(76, 175, 80, 0.5);
    letter-spacing: 0.05em;
}

.session-timer p {
    color: rgba(255,255,255,0.9);
    margin: 6px 0;
}

.clock-history {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
}

.history-item {
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid rgba(102, 126, 234, 0.8);
    color: #fff;
}

.history-item-edited {
    border-left-color: #ff9800;
    background: rgba(255, 152, 0, 0.15);
}

.history-edited-badge {
    display: inline-block;
    margin-left: 10px;
    padding: 2px 8px;
    background: #ff9800;
    color: white;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    gap: 10px;
}

.history-employee {
    font-weight: 600;
    color: #a5b4fc;
}

.history-date {
    color: rgba(255,255,255,0.8);
    font-size: 0.9em;
}

.history-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
    font-size: 0.9em;
    color: rgba(255,255,255,0.85);
}

.hours-summary {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
}

.hours-item {
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid #4CAF50;
    color: #fff;
}

.hours-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.hours-employee {
    font-weight: 600;
    color: #fff;
}

.hours-total {
    font-weight: bold;
    color: #4CAF50;
    font-size: 1.1em;
}

.hours-details {
    display: flex;
    gap: 15px;
    font-size: 0.9em;
    color: rgba(255,255,255,0.85);
}

.hours-total-card {
    padding: 20px;
    background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
    color: white;
    border-radius: 8px;
    text-align: center;
    margin-top: 10px;
}

.hours-total-card h3 {
    font-size: 1.5em;
    margin-bottom: 5px;
}

/* Payment Tracking Styles */
.payment-history {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 15px;
    max-height: 500px;
    overflow-y: auto;
}

.payment-item {
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid #4CAF50;
    color: #fff;
}

.payment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.payment-employee {
    font-weight: 600;
    color: #fff;
    font-size: 1.1em;
}

.payment-amount {
    font-weight: bold;
    color: #4CAF50;
    font-size: 1.3em;
    margin-left: 15px;
}

.payment-details {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 0.9em;
    color: rgba(255,255,255,0.85);
}

.payment-item-dark .payment-amount { font-size: 1.2em; font-weight: 600; color: #34d399; }
.payment-item-dark .payment-date-meta { font-size: 0.9em; color: rgba(255,255,255,0.75); margin-top: 4px; }
.payment-item-dark .payment-notes { margin-top: 8px; padding: 8px; background: rgba(0,0,0,0.2); border-radius: 4px; border-left: 3px solid #818cf8; color: rgba(255,255,255,0.9); font-size: 0.9em; }

.clocked-in-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    margin-bottom: 10px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid #22c55e;
    color: rgba(255,255,255,0.9);
}
.clocked-in-name { font-weight: 600; margin-bottom: 5px; color: rgba(255,255,255,0.95); }
.clocked-in-meta { font-size: 0.9em; color: rgba(255,255,255,0.8); }

.session-elapsed-box {
    text-align: center;
    padding: 15px;
    background: rgba(14, 165, 233, 0.15);
    border-radius: 8px;
    margin-top: 10px;
    border: 1px solid rgba(14, 165, 233, 0.3);
}
.session-elapsed-box .label { font-size: 0.9em; color: rgba(255,255,255,0.8); margin-bottom: 5px; }
.session-elapsed-box .value { font-size: 1.8em; font-weight: 700; color: #38bdf8; }

#payrollTab .list-placeholder,
#timeclockTab .list-placeholder,
#supportTab .list-placeholder,
#salesTab .list-placeholder,
#sopTab .list-placeholder,
#logsTab .list-placeholder,
#diagnosticsTab .list-placeholder,
#forumsTab .list-placeholder,
#timeoffTab .list-placeholder,
#inventoryTab .list-placeholder,
#spreadsheetTab .list-placeholder,
.tab-content .list-placeholder {
    color: rgba(255,255,255,0.8);
    text-align: center;
    padding: 20px;
}
.muted-text { color: rgba(255,255,255,0.6); }
.card-inner-box-alt { background: rgba(0,0,0,0.2); padding: 15px; border-radius: 6px; border: 1px solid rgba(255,255,255,0.1); color: rgba(255,255,255,0.9); }
.diagnostics-panel { background: rgba(0,0,0,0.2); padding: 15px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.1); color: rgba(255,255,255,0.9); }
.forum-post-content, .forum-reply-content { background: rgba(0,0,0,0.2); border-radius: 8px; padding: 20px; color: rgba(255,255,255,0.9); border: 1px solid rgba(255,255,255,0.08); }
.forum-reply-content { padding: 12px; border-radius: 6px; margin-top: 8px; }

.employee-item .employee-pay-meta { margin-top: 5px; font-size: 0.9em; color: rgba(255,255,255,0.8); }

/* Tab content descriptions and info boxes */
.tab-description,
.section-note { color: rgba(255,255,255,0.8); margin-bottom: 15px; font-size: 0.9em; }
.info-box {
    background: rgba(0,0,0,0.25);
    padding: 15px;
    border-radius: 8px;
    margin-top: 15px;
    border-left: 4px solid #818cf8;
    color: rgba(255,255,255,0.9);
}
.info-box h3 { margin: 0 0 10px 0; color: rgba(255,255,255,0.95); font-size: 1em; }
.info-box p { margin: 0; color: rgba(255,255,255,0.85); font-size: 0.9em; line-height: 1.5; }

#testResultsSection { background: rgba(0,0,0,0.2); }
#testResultsDisplay {
    max-height: 500px;
    overflow-y: auto;
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 6px;
    font-family: monospace;
    font-size: 0.9em;
    color: rgba(255,255,255,0.9);
    border: 1px solid rgba(255,255,255,0.1);
}

.archived-records-card.card { background: rgba(0,0,0,0.2); border: 2px solid rgba(255,255,255,0.15); }
.archived-records-card h2 { color: rgba(255,255,255,0.95); }
.archived-records-card .archived-subtitle { color: rgba(255,255,255,0.7); margin: 5px 0 0 0; font-size: 0.9em; }
.archived-records-card .list-placeholder { color: rgba(255,255,255,0.8); text-align: center; padding: 20px; }

input.scanned-qrcode.input { background: rgba(0,0,0,0.3); color: rgba(255,255,255,0.95); border-color: rgba(255,255,255,0.2); }

.sop-image-drop-zone {
    border: 2px dashed #818cf8;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    background: rgba(0,0,0,0.2);
    cursor: pointer;
    transition: all 0.3s;
}
.sop-image-drop-zone:hover { background: rgba(99, 102, 241, 0.15); border-color: #a5b4fc; }
.sop-image-drop-zone .drop-zone-title { color: #a5b4fc; font-weight: 600; margin-bottom: 5px; }
.sop-image-drop-zone .drop-zone-hint { color: rgba(255,255,255,0.7); font-size: 0.85em; }
.sop-image-preview-box {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: rgba(99, 102, 241, 0.15);
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.1);
}
.sop-image-preview-box .preview-title { font-weight: 600; color: #a5b4fc; margin-bottom: 5px; }
.sop-image-preview-box .preview-hint { font-size: 0.85em; color: rgba(255,255,255,0.8); }
.optional-label { color: rgba(255,255,255,0.6); font-weight: normal; }

.category-pill { background: rgba(0,0,0,0.3); color: rgba(255,255,255,0.95); }

.reports-modal-content.modal-content {
    background: rgba(30, 41, 59, 0.98);
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.15);
    color: rgba(255,255,255,0.9);
}
.reports-modal-content .reports-stat { background: rgba(0,0,0,0.25); padding: 15px; border-radius: 6px; border-left: 4px solid; color: rgba(255,255,255,0.9); }
.reports-modal-content .reports-stat .label { font-size: 0.9em; color: rgba(255,255,255,0.75); margin-bottom: 5px; }
.reports-modal-content .reports-stat.stat-blue { border-left-color: #0ea5e9; }
.reports-modal-content .reports-stat.stat-blue .value { color: #7dd3fc; }
.reports-modal-content .reports-stat.stat-green { border-left-color: #10b981; }
.reports-modal-content .reports-stat.stat-green .value { color: #6ee7b7; }
.reports-modal-content .reports-stat.stat-yellow { border-left-color: #eab308; }
.reports-modal-content .reports-stat.stat-yellow .value { color: #fde047; }
.reports-modal-content .reports-stat.stat-red { border-left-color: #ef4444; }
.reports-modal-content .reports-stat.stat-red .value { color: #fca5a5; }
.reports-modal-content .reports-section-box { background: rgba(0,0,0,0.2); padding: 15px; border-radius: 6px; border: 1px solid rgba(255,255,255,0.1); }
.reports-modal-content .reports-section-box > div { border-bottom-color: rgba(255,255,255,0.15); }
.reports-modal-content .reports-section-box span { color: rgba(255,255,255,0.9); }
.reports-modal-content .reports-section-box .muted { font-size: 0.9em; color: rgba(255,255,255,0.75); }
.reports-modal-content .modal-close { color: rgba(255,255,255,0.8); }

/* Sales Styles */
.sales-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 500px;
    overflow-y: auto;
}

.sale-item {
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid #4CAF50;
    color: #fff;
}

.sale-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 10px;
}

.sale-order {
    font-weight: 600;
    color: #a5b4fc;
    font-size: 1.1em;
    margin-right: 10px;
}

.sale-employee {
    color: rgba(255,255,255,0.85);
    font-size: 0.9em;
}

.sale-amount {
    font-weight: bold;
    color: #4CAF50;
    font-size: 1.2em;
}

.sale-details {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 0.9em;
    color: rgba(255,255,255,0.85);
    margin-bottom: 10px;
}

.sale-notes {
    margin-top: 10px;
    padding: 10px;
    background: rgba(255,255,255,0.08);
    border-radius: 4px;
    font-style: italic;
    color: rgba(255,255,255,0.85);
}

.sale-actions {
    display: flex;
    gap: 10px;
}

.sales-summary {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
    max-height: 400px;
    overflow-y: auto;
}

.sales-item {
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid #4CAF50;
    color: #fff;
}

.sales-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.sales-employee {
    font-weight: 600;
    color: #fff;
}

.sales-total {
    font-weight: bold;
    color: #4CAF50;
    font-size: 1.1em;
}

.sales-details {
    display: flex;
    gap: 15px;
    font-size: 0.9em;
    color: rgba(255,255,255,0.85);
}

.sales-total-card {
    padding: 20px;
    background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
    color: white;
    border-radius: 8px;
    text-align: center;
    margin-top: 10px;
}

.sales-total-card h3 {
    font-size: 1.5em;
    margin-bottom: 5px;
}

.sales-total-card p {
    margin: 5px 0;
    opacity: 0.9;
}

/* Logs Styles */
.logs-card {
    grid-column: 1 / -1;
}

.logs-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 600px;
    overflow-y: auto;
}

.log-item {
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid rgba(102, 126, 234, 0.8);
    transition: transform 0.2s;
    color: #fff;
}

.log-item:hover {
    transform: translateX(5px);
    background: rgba(0,0,0,0.35);
}

.log-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 10px;
}

.log-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2em;
    color: white;
    flex-shrink: 0;
}

.log-info {
    flex: 1;
    min-width: 0;
}

.log-action {
    font-weight: 600;
    color: #fff;
    margin-bottom: 4px;
    text-transform: capitalize;
}

.log-employee {
    font-size: 0.9em;
    color: rgba(255,255,255,0.85);
}

.log-time {
    font-size: 0.85em;
    color: rgba(255,255,255,0.7);
    white-space: nowrap;
    flex-shrink: 0;
}

.log-details {
    margin-top: 10px;
    padding: 10px;
    background: rgba(255,255,255,0.08);
    border-radius: 4px;
    font-size: 0.9em;
    color: rgba(255,255,255,0.9);
    border-left: 2px solid rgba(255,255,255,0.2);
    padding-left: 12px;
}

/* Support Ticket Styles */
.tickets-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-height: 600px;
    overflow-y: auto;
}

.ticket-item {
    padding: 20px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid #2196F3;
    color: #fff;
}

.ticket-item.customer-ticket {
    border-left-color: #ce93d8;
    background: rgba(156, 39, 176, 0.2);
}

.customer-form-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.customer-form-card h2 {
    color: white;
    border-bottom-color: rgba(255, 255, 255, 0.3);
}

.customer-form-card label {
    color: rgba(255, 255, 255, 0.9);
}

.customer-form-card .input {
    background: rgba(0,0,0,0.25);
    color: #fff;
    border: 1px solid rgba(255,255,255,0.2);
}

.customer-form-card .input::placeholder {
    color: rgba(255,255,255,0.5);
}

.customer-form-card .btn-primary {
    background: white;
    color: #667eea;
}

.customer-form-card .btn-primary:hover {
    background: #f0f0f0;
}

.ticket-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
    color: white;
    text-transform: uppercase;
}

.ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 10px;
}

.ticket-info {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.ticket-number {
    font-weight: bold;
    color: #90caf9;
    font-size: 1.1em;
}

.ticket-priority, .ticket-status {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
    color: white;
    text-transform: uppercase;
}

.ticket-date {
    font-size: 0.9em;
    color: rgba(255,255,255,0.8);
}

.ticket-customer {
    margin-bottom: 8px;
    color: #fff;
    font-size: 0.95em;
}

.ticket-subject {
    font-weight: 600;
    color: #fff;
    margin-bottom: 10px;
    font-size: 1.05em;
}

.ticket-description {
    color: rgba(255,255,255,0.9);
    margin-bottom: 10px;
    padding: 10px;
    background: rgba(255,255,255,0.08);
    border-radius: 4px;
    line-height: 1.5;
}

.ticket-assigned {
    margin-bottom: 10px;
    font-size: 0.9em;
    color: rgba(255,255,255,0.8);
}

.ticket-notes {
    margin-top: 15px;
    padding: 10px;
    background: rgba(255, 152, 0, 0.15);
    border-radius: 4px;
    border-left: 3px solid #FF9800;
}

.ticket-note {
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}

.ticket-note:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.note-text {
    display: block;
    color: #fff;
    margin-bottom: 4px;
}

.note-meta {
    font-size: 0.85em;
    color: rgba(255,255,255,0.7);
    font-style: italic;
}

.ticket-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 15px;
}

/* Time Off Management Styles */
.pto-balance {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.pto-item {
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid rgba(102, 126, 234, 0.8);
    color: #fff;
}

.pto-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.pto-name {
    font-weight: 600;
    color: #fff;
}

.pto-remaining {
    font-weight: bold;
    color: #4CAF50;
    font-size: 1.1em;
}

.pto-bar {
    width: 100%;
    height: 8px;
    background: rgba(255,255,255,0.2);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.pto-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #4CAF50 0%, #45a049 100%);
    transition: width 0.3s;
}

.pto-details {
    display: flex;
    gap: 15px;
    font-size: 0.9em;
    color: rgba(255,255,255,0.85);
}

.requests-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 500px;
    overflow-y: auto;
}

.request-item {
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border-left: 4px solid #FF9800;
    color: #fff;
}

.request-item.approved {
    border-left-color: #4CAF50;
}

.request-item.rejected {
    border-left-color: #f44336;
}

.request-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 10px;
}

.request-employee {
    font-weight: 600;
    color: #a5b4fc;
    margin-right: 10px;
}

.request-type, .request-status {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
    color: white;
    margin-right: 5px;
}

.request-days {
    font-weight: bold;
    color: #fff;
}

.request-dates {
    color: rgba(255,255,255,0.85);
    margin-bottom: 10px;
}

.request-reason {
    color: rgba(255,255,255,0.9);
    font-style: italic;
    margin-bottom: 10px;
    padding: 10px;
    background: rgba(255,255,255,0.08);
    border-radius: 4px;
}

.request-meta {
    font-size: 0.85em;
    color: rgba(255,255,255,0.75);
    margin-bottom: 10px;
}

.request-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Calendar Styles */
.calendar-card {
    grid-column: 1 / -1;
}

.calendar-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    gap: 15px;
}

.calendar-controls h3 {
    flex: 1;
    text-align: center;
    color: #667eea;
    margin: 0;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
}

.calendar-day {
    aspect-ratio: 1;
    padding: 8px;
    background: #f5f5f5;
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 60px;
}

.calendar-day.header {
    background: #667eea;
    color: white;
    font-weight: 600;
    font-size: 0.9em;
    justify-content: center;
    min-height: 40px;
}

.calendar-day.empty {
    background: transparent;
}

.calendar-day.has-timeoff {
    background: #e8f5e9;
    border: 2px solid #4CAF50;
}

.day-number {
    font-weight: 600;
    color: rgba(255,255,255,0.95);
    margin-bottom: 4px;
}

.day-timeoff {
    font-size: 0.7em;
    color: #2e7d32;
    text-align: center;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Notification Styles */
.notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
    pointer-events: none;
}

.notification {
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    padding: 15px;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
    pointer-events: auto;
    border-left: 4px solid #667eea;
}

.notification.show {
    opacity: 1;
    transform: translateX(0);
}

.notification-success {
    border-left-color: #4CAF50;
}

.notification-error {
    border-left-color: #f44336;
}

.notification-warning {
    border-left-color: #FF9800;
}

.notification-info {
    border-left-color: #2196F3;
}

.notification-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
}

.notification-message {
    flex: 1;
    color: #333;
    line-height: 1.4;
}

.notification-close {
    background: none;
    border: none;
    font-size: 1.5em;
    color: #999;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.notification-close:hover {
    color: #333;
}

/* User Activity Feed (Top Right Corner) */
.user-activity-feed {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-width: 350px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    overflow-x: hidden;
    pointer-events: none;
}

.user-activity-feed::-webkit-scrollbar {
    width: 6px;
}

.user-activity-feed::-webkit-scrollbar-thumb {
    background: rgba(102, 126, 234, 0.3);
    border-radius: 3px;
}

.user-activity-feed::-webkit-scrollbar-thumb:hover {
    background: rgba(102, 126, 234, 0.5);
}

.activity-notification {
    display: flex;
    align-items: center;
    gap: 8px;
    background: white;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 0.85em;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: auto;
    border-left: 3px solid #667eea;
    min-width: 200px;
    animation: slideInRight 0.3s ease;
}

.activity-notification.fade-out {
    opacity: 0;
    transform: translateX(100%);
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.activity-notification.recent {
    animation: slideInActivity 0.3s ease;
}

/* Removed animations to reduce flashing */

.activity-icon {
    font-size: 1.1em;
}

.activity-message {
    color: #333;
    font-weight: 500;
}

.activity-time {
    color: #666;
    font-size: 0.9em;
    margin-left: 4px;
}

.activity-notification.info {
    border-left: 3px solid #2196F3;
}

.activity-notification.success {
    border-left: 3px solid #4CAF50;
}

.activity-notification.warning {
    border-left: 3px solid #FF9800;
}

/* Mobile adjustments for activity feed */
@media (max-width: 768px) {
    .user-activity-feed {
        top: 10px;
        right: 10px;
        max-width: calc(100vw - 20px);
        max-height: calc(100vh - 20px);
    }
    
    .activity-notification {
        font-size: 0.8em;
        padding: 8px 12px;
        gap: 6px;
        min-width: auto;
        width: 100%;
    }
    
    .activity-time {
        font-size: 0.85em;
    }
}

/* Mobile Quick Actions */
.mobile-quick-actions {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 999;
    gap: 10px;
    flex-direction: column;
}

.mobile-quick-action {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: none;
    font-size: 1.5em;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    cursor: pointer;
    transition: transform 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-quick-action:active {
    transform: scale(0.95);
}

.mobile-quick-action.clock-in {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.mobile-quick-action.clock-out {
    background: #4CAF50;
    color: white;
}

@media (max-width: 768px) {
    /* Sidebar - Hidden by default, slides in from left (like quick tools) */
    .sidebar {
        width: 100%;
        max-width: 320px;
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        z-index: 10002;
        background: rgba(26, 27, 46, 0.98);
        backdrop-filter: blur(10px);
        border-right: 1px solid rgba(255,255,255,0.08);
        box-shadow: 2px 0 30px rgba(0,0,0,0.3);
        transform: translateX(-100%);
        transition: transform 0.3s ease-in-out;
        overflow-y: auto;
        /* Ensure proper scrolling with padding at bottom */
        padding-bottom: 20px;
        box-sizing: border-box;
    }
    
    /* Extra padding for sidebar nav on mobile so last items are visible */
    .sidebar .sidebar-nav {
        padding-bottom: 80px; /* Extra space so last items are fully visible when scrolling */
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    /* Toggle Arrow - Fixed position, ALWAYS visible on left edge */
    .sidebar-toggle-arrow {
        display: flex !important;
        align-items: center;
        justify-content: center;
        position: fixed;
        left: 0;
        top: 50%;
        transform: translateY(-50%);
        width: 45px;
        height: 90px;
        background: rgba(26, 27, 46, 0.95);
        color: rgba(255,255,255,0.9);
        border: 1px solid rgba(255,255,255,0.12);
        border-left: none;
        border-radius: 0 15px 15px 0;
        font-size: 2em;
        cursor: pointer;
        box-shadow: 2px 0 15px rgba(0,0,0,0.3);
        z-index: 10005;
        transition: all 0.3s ease;
    }
    
    /* Move arrow when sidebar opens - use body class or direct sibling */
    body.sidebar-open .sidebar-toggle-arrow,
    .sidebar.open ~ .sidebar-toggle-arrow {
        left: 320px;
    }
    
    /* Reset arrow position when sidebar closes */
    .sidebar:not(.open) ~ .sidebar-toggle-arrow,
    body:not(.sidebar-open) .sidebar-toggle-arrow {
        left: 0 !important;
    }
    
    .sidebar-toggle-arrow:hover {
        background: rgba(255,255,255,0.12);
        border-color: rgba(255,255,255,0.2);
        box-shadow: 2px 0 20px rgba(0,0,0,0.35);
        width: 50px;
    }
    
    .sidebar-toggle-arrow:active {
        transform: translateY(-50%) scale(0.95);
    }
    
    .sidebar-toggle-arrow .arrow-icon {
        transition: transform 0.3s ease;
        display: inline-block;
    }
    
    /* Rotate arrow when sidebar is open */
    body.sidebar-open .sidebar-toggle-arrow .arrow-icon,
    .sidebar.open ~ .sidebar-toggle-arrow .arrow-icon {
        transform: rotate(180deg);
    }
    
    /* Show tab labels on mobile when sidebar is open */
    .sidebar.open .tab-label {
        display: inline;
    }
    
    /* Sidebar Overlay - Dark background when sidebar is open (like quick tools) */
    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 10001;
        display: none;
    }
    
    .sidebar-overlay.active {
        display: block;
    }
    
    .main-content-area {
        margin-left: 0;
        padding: 15px;
        padding-top: 70px; /* Space for mobile menu button */
    }
    
    .main-content {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .summary-controls {
        grid-template-columns: 1fr;
    }
    
    .content-header h2 {
        font-size: 1.8em;
    }
    
    .clock-buttons {
        flex-direction: column;
    }
    
    .btn-large {
        padding: 18px;
        font-size: 18px;
        min-height: 60px;
    }
    
    .timer-display {
        font-size: 2em;
    }
    
    /* Hide tab labels by default on mobile, show when sidebar is open */
    .tab-label {
        display: none;
    }
    
    .sidebar-header h1 {
        font-size: 1.2em;
    }
    
    .mobile-quick-actions {
        display: none; /* Removed per user request */
    }
    
    .notification-container {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
    }
    
    .calendar-grid {
        gap: 3px;
    }
    
    .calendar-day {
        min-height: 50px;
        padding: 5px;
        font-size: 0.85em;
    }
    
    .calendar-day.header {
        min-height: 35px;
        font-size: 0.8em;
    }
    
    .day-timeoff {
        font-size: 0.6em;
    }
    
    .request-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .request-actions {
        width: 100%;
    }
    
    .request-actions .btn {
        flex: 1;
    }
    
    /* Mobile menu toggle removed - using sidebar toggle arrow instead */
}

/* Simple Inventory Styles - Compact */
.inventory-items-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    max-height: 600px;
    overflow-y: auto;
    margin-top: 10px;
}

.scan-log-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 600px;
    overflow-y: auto;
    margin-top: 10px;
}

.scan-log-item {
    padding: 12px 15px;
    background: rgba(255,255,255,0.06);
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.95);
    transition: all 0.2s ease;
}

.scan-log-item:hover {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,255,255,0.15);
    transform: translateY(-1px);
}

.inventory-item {
    padding: 6px 10px;
    background: rgba(255,255,255,0.06);
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.95);
    transition: all 0.2s;
}

.inventory-item:hover {
    border-color: rgba(102, 126, 234, 0.6);
    background: rgba(102, 126, 234, 0.1);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.15);
}

.inventory-item.low-stock {
    border-color: rgba(244, 67, 54, 0.6);
    background: rgba(244, 67, 54, 0.15);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 2px 8px rgba(244, 67, 54, 0.1); }
    50% { box-shadow: 0 2px 12px rgba(244, 67, 54, 0.3); }
}

.item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
    gap: 8px;
    flex-wrap: wrap;
}

.item-name-section {
    flex: 1;
    min-width: 120px;
}

.item-name {
    font-size: 0.95em;
    font-weight: 600;
    color: rgba(255,255,255,0.95);
    margin: 0 0 3px 0;
    line-height: 1.2;
}

.item-badges {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}

.badge {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 8px;
    font-size: 0.65em;
    font-weight: 600;
    color: white;
    line-height: 1.2;
}

.badge.product {
    background: #4CAF50;
}

.badge.supply {
    background: #2196F3;
}

.badge.strain {
    background: #667eea;
}

.badge.thc {
    background: #9C27B0;
}

.badge.expiring {
    background: #FF9800;
}

.item-quantity-section {
    text-align: right;
}

.quantity-display {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.quantity-input {
    font-size: 1.1em;
    font-weight: bold;
    color: #34d399;
    line-height: 1;
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 4px;
    padding: 2px 6px;
    width: 70px;
    text-align: center;
    transition: all 0.2s;
}

.quantity-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.1);
}

.quantity-display.low .quantity-input {
    color: #f87171;
    border-color: rgba(248, 113, 113, 0.6);
}

.low-stock-warning {
    background: #f44336;
    color: white;
    padding: 2px 6px;
    border-radius: 8px;
    font-size: 0.65em;
    font-weight: 600;
    margin-top: 2px;
    display: inline-block;
    line-height: 1.2;
}

.category-badge {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 8px;
    font-size: 0.65em;
    font-weight: 600;
    color: white;
    text-transform: capitalize;
    line-height: 1.2;
}

.custom-category-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    background: #f8f9fa;
    border-radius: 6px;
    margin-bottom: 6px;
    gap: 10px;
}

.category-name {
    font-weight: 600;
    color: #333;
    flex: 1;
    text-transform: capitalize;
    font-size: 0.9em;
}

.category-count {
    color: #666;
    font-size: 0.8em;
}

.btn-delete-small {
    padding: 4px 10px;
    background: #f44336;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.75em;
    font-weight: 600;
    transition: all 0.2s;
}

.btn-delete-small:hover {
    background: #d32f2f;
}

.item-details {
    margin-bottom: 4px;
    padding: 4px 6px;
    background: rgba(0,0,0,0.2);
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.9);
}

.detail-row {
    display: flex;
    gap: 10px;
    margin-bottom: 2px;
    font-size: 0.75em;
    color: rgba(255,255,255,0.88);
}

.detail-row .detail-muted {
    color: rgba(255,255,255,0.8);
}
.detail-row.detail-row-notes {
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px solid rgba(255,255,255,0.12);
}
    flex-wrap: wrap;
    line-height: 1.3;
}

.item-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 4px;
    flex-wrap: wrap;
}

/* Conversions Styles */
.mix-results {
    margin-top: 20px;
    margin-bottom: 20px;
}

.mix-results-container {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.mix-output {
    margin-bottom: 20px;
}

.mix-output:last-child {
    margin-bottom: 0;
}

.mix-label {
    font-size: 0.9em;
    opacity: 0.9;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mix-value {
    font-size: 2.5em;
    font-weight: bold;
    color: white;
}

.mix-value-small {
    font-size: 1.1em;
    font-weight: 600;
    line-height: 1.6;
}

.btn-terp-quick {
    padding: 8px 16px;
    background: #f0f0f0;
    color: #333;
    border: 2px solid #ddd;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9em;
    transition: all 0.2s;
}

.btn-terp-quick:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

.advanced-section {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid #e0e0e0;
}

.advanced-toggle {
    width: 100%;
    padding: 12px;
    background: #f8f9fa;
    border: 1px solid #ddd;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    color: #666;
    transition: all 0.2s;
}

.advanced-toggle:hover {
    background: #e9ecef;
    border-color: #667eea;
}

.advanced-content {
    margin-top: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.additive-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.additive-row label {
    min-width: 80px;
    font-weight: 500;
}

.input-small {
    max-width: 120px;
}

/* Multiple Calculators */
#calculatorsContainer {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 20px;
}

.calculator-item {
    margin-bottom: 0;
    min-width: 0;
}

.calculator-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid rgba(255,255,255,0.2);
}

.calculator-header h2 {
    margin: 0;
    font-size: 1.3em;
    color: rgba(255,255,255,0.95);
}

#conversionsTab .calculator-header h2 { color: rgba(255,255,255,0.95); }
#conversionsTab .calculator-item .form-group label { color: rgba(255,255,255,0.9); }
#conversionsTab .calculator-item .mix-results-container .mix-label { color: rgba(255,255,255,0.85); }
#conversionsTab .calculator-item .mix-results-container .mix-value,
#conversionsTab .calculator-item .mix-results-container .mix-value-small { color: rgba(255,255,255,0.95); }
#conversionsTab .btn-terp-quick { background: rgba(255,255,255,0.15); color: rgba(255,255,255,0.95); border: 1px solid rgba(255,255,255,0.25); }
#conversionsTab .btn-terp-quick:hover { background: rgba(255,255,255,0.25); color: #fff; }

.terp-conversion-result {
    margin-top: 20px;
}

/* Conversions page specific styles */
#conversionsTab .main-content {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

#spreadsheetTab .main-content {
    display: flex !important;
    flex-direction: column !important;
    grid-template-columns: none !important;
    gap: 15px !important;
}

#inventoryTab .main-content {
    display: flex !important;
    flex-direction: column !important;
    grid-template-columns: none !important;
    gap: 20px !important;
}

/* Inventory Unified Layout */
.inventory-unified {
    max-width: 1400px;
    margin: 0 auto;
}

/* Compact Inventory Layout */
.inventory-compact-top {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 12px;
    margin-bottom: 12px;
}

.inventory-compact-middle {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 12px;
}

.inventory-compact-card {
    padding: 12px 15px !important;
    margin: 0 !important;
}

.inventory-compact-card h3 {
    font-size: 1em;
    margin-bottom: 8px;
    font-weight: 600;
}

.inventory-barcode {
    background: rgba(102, 126, 234, 0.12);
    border: 1px solid rgba(102, 126, 234, 0.3);
    color: rgba(255,255,255,0.95);
}

.inventory-summary-card {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.95);
}

.inventory-quick-add {
    background: rgba(76, 175, 80, 0.1);
    border: 1px solid rgba(76, 175, 80, 0.3);
    color: rgba(255,255,255,0.95);
}

.inventory-qr-generator {
    background: rgba(255, 152, 0, 0.1);
    border: 1px solid rgba(255, 152, 0, 0.35);
    color: rgba(255,255,255,0.95);
}

.inventory-categories {
    background: rgba(156, 39, 176, 0.12);
    border: 1px solid rgba(156, 39, 176, 0.35);
    color: rgba(255,255,255,0.95);
}

/* Compact Input Styles */
.input-compact {
    padding: 6px 10px !important;
    font-size: 0.9em !important;
    border-radius: 6px !important;
}

.form-row-compact {
    display: flex;
    gap: 6px;
    align-items: center;
}

/* Compact Summary Results */
.summary-results-compact {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 10px;
    font-size: 0.85em;
}

.summary-results-compact .summary-card {
    padding: 12px 14px;
    margin: 0;
    border-radius: 8px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    min-height: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: rgba(255,255,255,0.95);
}

.summary-results-compact .summary-card h3 {
    font-size: 0.8em;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
    color: rgba(255,255,255,0.8);
}

.summary-results-compact .summary-card .value {
    font-size: 1.5em;
    font-weight: 700;
    color: rgba(255,255,255,0.95);
    line-height: 1.2;
}
.summary-results-compact .summary-card.summary-card-items { border-left: 4px solid rgba(102, 126, 234, 0.8); }
.summary-results-compact .summary-card.summary-card-items h3 { color: #a5b4fc; }
.summary-results-compact .summary-card.summary-card-qty { border-left: 4px solid rgba(14, 165, 233, 0.8); }
.summary-results-compact .summary-card.summary-card-qty h3 { color: #7dd3fc; }
.summary-results-compact .summary-card.summary-card-value { border-left: 4px solid rgba(16, 185, 129, 0.8); }
.summary-results-compact .summary-card.summary-card-value h3 { color: #6ee7b7; }
.summary-results-compact .summary-card.summary-card-low { border-left: 4px solid rgba(239, 68, 68, 0.8); }
.summary-results-compact .summary-card.summary-card-low h3 { color: #fca5a5; }

/* Inventory Tabs */
.inventory-tabs-container {
    margin-top: 8px;
}

.inventory-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    border-bottom: 2px solid rgba(255,255,255,0.15);
    padding-bottom: 0;
}

.inventory-tab-btn {
    background: transparent;
    border: none;
    padding: 12px 24px;
    font-size: 1em;
    font-weight: 600;
    color: rgba(255,255,255,0.8);
    cursor: pointer;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    transition: all 0.2s;
}

.inventory-tab-btn:hover {
    color: #a5b4fc;
    background: rgba(255,255,255,0.08);
}

.inventory-tab-btn.active {
    color: #a5b4fc;
    border-bottom-color: #667eea;
    background: rgba(102, 126, 234, 0.15);
}

.inventory-tab-content {
    display: none;
}

.inventory-tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Enhanced Inventory Card Styles */
.inventory-summary-card .summary-results {
    gap: 12px;
}

.inventory-summary-card .summary-card {
    padding: 15px;
    border-radius: 6px;
}

.inventory-summary-card .summary-card .value {
    font-size: 1.8em;
}

.inventory-quick-add .form-group,
.inventory-quick-add .form-row {
    margin-bottom: 12px;
}

.inventory-quick-add .input {
    font-size: 0.95em;
}

.inventory-qr-generator .input {
    font-size: 0.95em;
}

/* Mobile adjustments for inventory */
@media (max-width: 768px) {
    .inventory-compact-top {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .inventory-compact-middle {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .inventory-tabs {
        flex-wrap: wrap;
    }
    
    .inventory-tab-btn {
        padding: 8px 12px;
        font-size: 0.85em;
    }
    
    .inventory-compact-card {
        padding: 10px 12px !important;
    }
    
    .inventory-unified {
        padding: 0 10px;
    }
    
    .projects-compact-top,
    .projects-compact-bottom {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .projects-compact-card {
        padding: 10px 12px !important;
    }
}

#conversionsTab .card {
    margin-bottom: 0;
}

#calculatorsContainer .calculator-item {
    margin-bottom: 0;
}

/* Responsive grid for calculators - handled in main mobile query */

/* Legacy conversion styles (keeping for compatibility) */
.conversion-result {
    margin-top: 20px;
}

.conversion-result-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.conversion-result-header {
    margin-bottom: 15px;
    border-bottom: 1px solid rgba(255,255,255,0.3);
    padding-bottom: 10px;
}

.conversion-result-header h3 {
    margin: 0;
    font-size: 1.3em;
    color: white;
}

.conversion-result-body {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.conversion-summary {
    padding: 12px;
    background: rgba(255,255,255,0.2);
    border-radius: 8px;
    font-size: 1.1em;
    text-align: center;
    font-weight: 500;
    margin-bottom: 5px;
}

.conversion-value {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: rgba(255,255,255,0.15);
    border-radius: 8px;
}

.conversion-label {
    font-size: 1em;
    opacity: 0.9;
}

.conversion-number {
    font-size: 1.5em;
    font-weight: bold;
}

.conversion-formula {
    margin-top: 10px;
    padding: 12px;
    background: rgba(255,255,255,0.2);
    border-radius: 8px;
    font-family: monospace;
    font-size: 0.95em;
    text-align: center;
    border: 1px solid rgba(255,255,255,0.3);
}

.qty-buttons {
    display: flex;
    gap: 3px;
    flex-wrap: wrap;
}

.btn-qty {
    padding: 3px 8px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.75em;
    transition: all 0.2s;
    min-width: 32px;
    line-height: 1.2;
}

.btn-qty:hover {
    background: #5568d3;
    transform: translateY(-1px);
}

.btn-qty:active {
    transform: translateY(0);
}

.btn-delete {
    padding: 3px 8px;
    background: #f44336;
    color: white;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.75em;
    transition: all 0.2s;
    line-height: 1.2;
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: #999;
    font-size: 1.1em;
}

.summary-card.alert {
    background: linear-gradient(135deg, #f44336 0%, #d32f2f 100%);
}

/* Mobile menu toggle (hidden on desktop) */
/* Better touch targets for mobile */
@media (max-width: 768px) {
    .btn {
        min-height: 44px;
        padding: 12px 20px;
    }
    
    .input {
        min-height: 44px;
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    .nav-tab {
        min-height: 50px;
        padding: 15px 20px;
    }
}

/* Spreadsheet Styles */
.spreadsheet-container {
    overflow-x: auto;
    overflow-y: auto;
    max-height: 70vh;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: white;
}

.spreadsheet-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 500px;
}

.spreadsheet-header {
    background: #667eea;
    color: white;
    font-weight: 600;
    padding: 10px;
    text-align: center;
    min-width: 50px;
    position: sticky;
    top: 0;
    z-index: 10;
    border: 1px solid #5568d3;
}

.spreadsheet-row-header {
    background: #667eea;
    color: white;
    font-weight: 600;
    padding: 10px;
    text-align: center;
    min-width: 50px;
    position: sticky;
    left: 0;
    z-index: 5;
    border: 1px solid #5568d3;
}

.spreadsheet-cell {
    width: 100%;
    min-width: 150px;
    padding: 8px 10px;
    border: 1px solid #e0e0e0;
    background: white;
    font-size: 0.9em;
    font-family: inherit;
    outline: none;
    transition: background 0.2s;
}

.spreadsheet-cell:focus {
    background: #f0f4ff;
    border-color: #667eea;
    box-shadow: inset 0 0 0 1px #667eea;
}

.spreadsheet-cell:hover {
    background: #f8f9fa;
}

.spreadsheet-table td {
    padding: 0;
    border: 1px solid #e0e0e0;
}

/* Mobile adjustments for spreadsheet */
@media (max-width: 768px) {
    .spreadsheet-container {
        max-height: 60vh;
    }
    
    .spreadsheet-cell {
        min-width: 120px;
        padding: 6px 8px;
        font-size: 0.85em;
    }
    
    .spreadsheet-header,
    .spreadsheet-row-header {
        padding: 8px;
        font-size: 0.85em;
        min-width: 40px;
    }
}

/* Saved Spreadsheets List - Compact */
.saved-spreadsheets-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    max-height: 150px;
    overflow-y: auto;
}

.saved-spreadsheet-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 5px 8px;
    background: #f8f9fa;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
    transition: background 0.2s;
}

.saved-spreadsheet-item:hover {
    background: #f0f4ff;
    border-color: #667eea;
}

.saved-spreadsheet-item.current {
    background: #e8f0ff;
    border-color: #667eea;
    border-width: 2px;
}

.saved-spreadsheet-info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.saved-spreadsheet-name {
    font-weight: 600;
    color: #333;
    font-size: 0.85em;
}

.saved-spreadsheet-meta {
    font-size: 0.7em;
    color: #666;
}

.btn-delete-spreadsheet {
    background: none;
    border: none;
    color: #999;
    font-size: 1.2em;
    cursor: pointer;
    padding: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 3px;
    transition: all 0.2s;
    line-height: 1;
    flex-shrink: 0;
}

.btn-delete-spreadsheet:hover {
    background: #ffebee;
    color: #f44336;
}

/* Mobile adjustments for saved spreadsheets */
@media (max-width: 768px) {
    .saved-spreadsheets-list {
        max-height: 120px;
        gap: 3px;
    }
    
    .saved-spreadsheet-item {
        padding: 4px 6px;
    }
    
    .saved-spreadsheet-name {
        font-size: 0.8em;
    }
    
    .saved-spreadsheet-meta {
        font-size: 0.65em;
    }
    
    .btn-delete-spreadsheet {
        width: 18px;
        height: 18px;
        font-size: 1.1em;
    }
}

/* Payroll Calendar Styles */
#payrollTab .main-content {
    display: flex !important;
    flex-direction: column !important;
    grid-template-columns: none !important;
    gap: 15px !important;
}

/* Total Owed table - dark theme */
.total-owed-summary {
    color: rgba(255,255,255,0.95);
}
.total-owed-summary .total-owed-table {
    width: 100%;
    border-collapse: collapse;
}
.total-owed-summary .total-owed-thead tr {
    background: rgba(255,255,255,0.1);
    border-bottom: 2px solid rgba(255,255,255,0.2);
}
.total-owed-summary .total-owed-th {
    padding: 12px;
    font-weight: 600;
    color: rgba(255,255,255,0.95);
    text-align: left;
}
.total-owed-summary .total-owed-th.num {
    text-align: right;
}
.total-owed-summary .total-owed-th.owed {
    text-align: right;
    color: #fca5a5;
}
.total-owed-summary .total-owed-tbody tr {
    border-bottom: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.9);
}
.total-owed-summary .total-owed-td {
    padding: 12px;
}
.total-owed-summary .total-owed-td.num {
    text-align: right;
}
.total-owed-summary .total-owed-indicator {
    position: absolute;
    top: 5px;
    right: 5px;
    font-size: 0.75em;
    color: #a5b4fc;
    opacity: 0.9;
    z-index: 10;
    background: rgba(0,0,0,0.4);
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 500;
}
.total-owed-summary .total-owed-empty,
.total-owed-summary .total-owed-error {
    text-align: center;
    padding: 20px;
    color: rgba(255,255,255,0.8);
}
.total-owed-summary .total-owed-error {
    color: #fca5a5;
}

/* Payment history (employee detail) cards - dark theme */
.payment-history-card {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    padding: 15px;
    color: rgba(255,255,255,0.95);
}
.payment-history-card h3 {
    margin: 0 0 15px 0;
    font-size: 1.1em;
    color: rgba(255,255,255,0.95);
    border-bottom: 2px solid rgba(255,255,255,0.15);
    padding-bottom: 10px;
}
.payment-history-card .ph-deleted {
    font-size: 0.8em;
    color: rgba(255,255,255,0.6);
    font-weight: normal;
}
.payment-history-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}
.payment-history-stat {
    background: rgba(0,0,0,0.25);
    padding: 10px;
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.95);
}
.payment-history-stat .ph-label {
    font-size: 0.85em;
    color: rgba(255,255,255,0.75);
    margin-bottom: 5px;
}
.payment-history-stat .ph-value {
    font-size: 1.2em;
    font-weight: 600;
}
.payment-history-section h4 {
    margin: 0 0 10px 0;
    font-size: 0.95em;
    color: rgba(255,255,255,0.9);
}
.payment-history-list {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 4px;
    padding: 10px;
    background: rgba(0,0,0,0.15);
}
.payment-history-record {
    background: rgba(255,255,255,0.06);
    padding: 8px;
    border-radius: 4px;
    margin-bottom: 8px;
    border-left: 3px solid rgba(255,255,255,0.3);
    color: rgba(255,255,255,0.9);
}
.payment-history-record .ph-date {
    font-weight: 600;
    margin-bottom: 4px;
}
.payment-history-record .ph-meta {
    font-size: 0.85em;
    color: rgba(255,255,255,0.75);
}
.payment-history-payment {
    background: rgba(59, 130, 246, 0.15);
    padding: 8px;
    border-radius: 4px;
    margin-bottom: 8px;
    border-left: 3px solid rgba(59, 130, 246, 0.5);
    color: rgba(255,255,255,0.9);
}

/* Day details modal (payroll calendar click) */
#dayDetailsModal .day-details-content {
    background: rgba(30,30,35,0.98);
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    color: rgba(255,255,255,0.95);
    border: 1px solid rgba(255,255,255,0.15);
}
#dayDetailsModal .day-detail-card {
    background: rgba(255,255,255,0.08);
    border-radius: 6px;
    padding: 12px;
    margin-bottom: 12px;
    border-left: 4px solid rgba(76, 175, 80, 0.6);
    color: rgba(255,255,255,0.95);
}
#dayDetailsModal .day-detail-card h3 {
    margin: 0;
    font-size: 1.1em;
    color: rgba(255,255,255,0.95);
}
#dayDetailsModal .day-detail-active {
    background: rgba(76, 175, 80, 0.2);
    padding: 8px;
    border-radius: 4px;
    border: 2px solid rgba(76, 175, 80, 0.5);
    color: rgba(255,255,255,0.9);
}
#dayDetailsModal .day-detail-active .ph-meta {
    font-size: 0.85em;
    color: rgba(255,255,255,0.8);
}
#dayDetailsModal .day-detail-record {
    background: rgba(0,0,0,0.25);
    padding: 8px;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.9);
}
#dayDetailsModal .day-detail-record .ph-meta {
    font-size: 0.9em;
    color: rgba(255,255,255,0.8);
}

.payroll-calendar {
    width: 100%;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
    margin-top: 15px;
    overflow: visible;
}

.calendar-day-header {
    background: #667eea;
    color: white;
    padding: 10px;
    text-align: center;
    font-weight: 600;
    font-size: 0.9em;
    border-radius: 6px;
}

.calendar-day {
    min-height: 120px;
    height: auto;
    max-height: 250px;
    border: 2px solid rgba(255,255,255,0.15);
    border-radius: 6px;
    padding: 8px;
    background: rgba(255,255,255,0.06);
    color: rgba(255,255,255,0.95);
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow: hidden;
    position: relative;
}

.calendar-day.empty {
    background: #f8f9fa;
    border: none;
}

.calendar-day-number {
    font-weight: 600;
    font-size: 0.9em;
    color: rgba(255,255,255,0.95);
    margin-bottom: 4px;
    flex-shrink: 0;
}

.calendar-work-records {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 1;
    min-height: 0;
}

.calendar-day-button {
    width: 100%;
    background: linear-gradient(135deg, #999 0%, #777 100%);
    color: white;
    border: none;
    border-radius: 4px;
    padding: 6px 8px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.7em;
    text-align: left;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-top: 4px;
}

.calendar-day-button.active {
    background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
}

.calendar-day-button:not(.active) {
    background: linear-gradient(135deg, #f44336 0%, #d32f2f 100%);
}

.calendar-day-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(0,0,0,0.15);
}

.calendar-day-button.active:hover {
    background: linear-gradient(135deg, #45a049 0%, #4CAF50 100%);
}

.calendar-day-button:not(.active):hover {
    background: linear-gradient(135deg, #d32f2f 0%, #f44336 100%);
}

.day-button-header {
    font-weight: 600;
    font-size: 0.9em;
    margin-bottom: 4px;
}

.day-button-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85em;
    opacity: 0.95;
}

.day-button-employees {
    font-weight: 500;
}

.day-button-hours {
    font-weight: 600;
}

.day-button-pay {
    font-weight: 700;
    font-size: 0.95em;
}

.calendar-work-item {
    background: #e8f5e9;
    border-left: 3px solid #4CAF50;
    padding: 3px 5px;
    border-radius: 3px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.7em;
    flex-shrink: 0;
    line-height: 1.2;
}

.calendar-work-item.multiple-records {
    background: #c8e6c9;
    border-left-width: 4px;
    font-weight: 500;
}

.calendar-work-item:hover {
    background: #a5d6a7;
    transform: scale(1.02);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.record-count {
    font-size: 0.85em;
    color: #2e7d32;
    font-weight: 600;
}

.calendar-work-item:hover {
    background: #c8e6c9;
}

.work-employee {
    font-weight: 600;
    color: #2e7d32;
    margin-bottom: 1px;
    font-size: 0.9em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.work-hours {
    color: #555;
    font-size: 0.85em;
    margin-top: 1px;
}

.work-pay {
    color: #4CAF50;
    font-weight: 600;
    font-size: 0.85em;
    margin-top: 1px;
}

.calendar-payments {
    display: flex;
    flex-direction: column;
    gap: 3px;
    margin-top: 3px;
    min-height: 0;
}

.calendar-payment-item {
    background: #fff3e0;
    border-left: 3px solid #FF9800;
    padding: 4px 6px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
    font-size: 0.75em;
    flex-shrink: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.calendar-payment-item:hover {
    background: #ffe0b2;
}

.payment-label {
    font-weight: 600;
    color: #E65100;
    font-size: 0.8em;
    margin-bottom: 2px;
}

.payment-employee {
    color: #666;
    font-size: 0.85em;
}

.payment-amount {
    color: #FF9800;
    font-weight: 600;
    font-size: 0.9em;
}

/* Mobile adjustments for payroll calendar */
@media (max-width: 768px) {
    .calendar-grid {
        gap: 4px;
    }
    
    .calendar-day {
        min-height: 100px;
        max-height: 200px;
        padding: 6px;
        overflow: hidden;
    }
    
    .calendar-day-button {
        padding: 4px 6px;
        font-size: 0.65em;
    }
    
    .day-button-header {
        font-size: 0.8em;
        margin-bottom: 2px;
    }
    
    .day-button-summary {
        font-size: 0.75em;
    }
    
    .calendar-work-item,
    .calendar-payment-item {
        padding: 2px 4px;
        font-size: 0.65em;
    }
    
    .calendar-day-header {
        padding: 8px 4px;
        font-size: 0.8em;
    }
    
    .calendar-work-item,
    .calendar-payment-item {
        font-size: 0.7em;
        padding: 3px 4px;
    }
    
    .calendar-day-number {
        font-size: 0.85em;
    }
}

/* Forum Styles */
.forum-posts-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.forum-post-item {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.forum-post-item:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
    transform: translateY(-2px);
}

.forum-post-header {
    margin-bottom: 12px;
}

.forum-post-title-section {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.forum-post-title {
    margin: 0;
    font-size: 1.2em;
    color: #333;
    flex: 1;
    min-width: 200px;
}

.forum-post-preview {
    color: #666;
    font-size: 0.95em;
    line-height: 1.5;
    margin-bottom: 12px;
}

.forum-post-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    padding-top: 12px;
    border-top: 1px solid #f0f0f0;
}

.forum-post-meta {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.forum-post-author,
.forum-post-date {
    color: #666;
    font-size: 0.9em;
}

.forum-post-stats {
    display: flex;
    gap: 15px;
    align-items: center;
}

.forum-post-replies,
.forum-post-views {
    color: #666;
    font-size: 0.9em;
    display: flex;
    align-items: center;
    gap: 5px;
}

.forum-replies-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 20px;
}

.forum-reply-item {
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 3px solid #667eea;
}

.forum-reply-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.forum-reply-content {
    color: #333;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .forum-post-item {
        padding: 15px;
    }
    
    .forum-post-title {
        font-size: 1.1em;
    }
    
    .forum-post-footer {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Calculator Styles */
.calculator-container {
    max-width: 400px;
    margin: 0 auto;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.calculator-display {
    margin-bottom: 15px;
}

.calculator-display-input {
    width: 100%;
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-family: 'Courier New', monospace;
}

.calculator-buttons {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.calc-btn {
    padding: 20px;
    font-size: 1.2em;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    background: white;
    color: #333;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.calc-btn:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.calc-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.calc-btn-clear {
    background: #ff6b6b;
    color: white;
}

.calc-btn-clear:hover {
    background: #ff5252;
}

.calc-btn-operator {
    background: #667eea;
    color: white;
}

.calc-btn-operator:hover {
    background: #5568d3;
}

.calc-btn-equals {
    background: #10b981;
    color: white;
    grid-column: span 2;
}

.calc-btn-equals:hover {
    background: #059669;
}

.calc-btn-zero {
    grid-column: span 2;
}

/* Barcode Scanner Styles */
.barcode-scanner-input {
    border: 2px solid #667eea;
    transition: all 0.3s;
}

.barcode-scanner-input:focus {
    border-color: #764ba2;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.barcode-scanner-status {
    color: #666;
    font-weight: 500;
}

/* Quick Tools Container */
#quickToolsContainer {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
}

/* Quick Tools Toggle Button */
.quick-tools-toggle-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    white-space: nowrap;
}

.quick-tools-toggle-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

.quick-tools-toggle-btn:active {
    transform: translateY(0);
}

/* Quick Tools Floating Panel - dark to match app */
.quick-tools-panel {
    position: fixed;
    top: 0;
    right: 0;
    width: 90%;
    max-width: 1200px;
    height: 100vh;
    background: linear-gradient(160deg, #1a1b2e 0%, #16213e 40%, #0f3460 100%);
    color: rgba(255,255,255,0.9);
    box-shadow: -5px 0 30px rgba(0,0,0,0.5);
    z-index: 10000;
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.3s ease-in-out;
}

.quick-tools-panel[style*="display: block"] {
    transform: translateX(0);
}

.quick-tools-panel-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 10001;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.quick-tools-panel-header h2 {
    margin: 0;
    font-size: 1.8em;
    color: white;
    border: none;
    padding: 0;
}

.quick-tools-close-btn {
    background: rgba(255,255,255,0.2);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.5em;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.quick-tools-close-btn:hover {
    background: rgba(255,255,255,0.3);
    transform: rotate(90deg);
}

.quick-tools-panel-content {
    padding: 30px;
    background: transparent;
    color: rgba(255,255,255,0.9);
    min-height: calc(100vh - 80px);
}

.quick-tools-panel .card,
.quick-tools-panel .calculator-item {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.9);
}

.quick-tools-panel .calculator-header h2,
.quick-tools-panel .card h2,
.quick-tools-panel .card h3 {
    color: rgba(255,255,255,0.95);
}

.quick-tools-panel .form-group label,
.quick-tools-panel label {
    color: rgba(255,255,255,0.9);
}

.quick-tools-panel .input {
    background: rgba(0,0,0,0.3);
    border-color: rgba(255,255,255,0.2);
    color: rgba(255,255,255,0.95);
}

.quick-tools-panel .input::placeholder {
    color: rgba(255,255,255,0.5);
}

/* Overlay when panel is open */
.quick-tools-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 9999;
    display: none;
}

.quick-tools-overlay.active {
    display: block;
}

@media (max-width: 768px) {
    .quick-tools-panel {
        width: 100%;
        max-width: 100%;
    }
    
    .quick-tools-toggle-btn {
        padding: 10px 16px;
        font-size: 0.9em;
    }
    
    #quickToolsContainer {
        grid-template-columns: 1fr;
    }
    
    .calculator-container {
        max-width: 100%;
    }
    
    .calc-btn {
        padding: 15px;
        font-size: 1em;
    }
    
    .quick-tools-panel-content {
        padding: 20px;
    }
}
