:root {
    --font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --color-bg: #ffffff;
    --color-surface: #ffffff;
    --color-border: #e2e8f0;
    --color-primary: #001c28;
    --color-primary-dark: #001018;
    --color-primary-light: #002a3a;
    --color-yellow: #e1ac3b;
    --color-yellow-light: #f4c162;
    --color-yellow-dark: #c99628;
    --color-secondary: #64748b;
    --color-success: #16a34a;
    --color-warning: #e1ac3b;
    --color-danger: #dc2626;
    --radius-lg: 18px;
    --radius-md: 12px;
    --radius-sm: 8px;
    --shadow-soft: 0 16px 40px rgba(15, 23, 42, 0.08);
}

* {
    box-sizing: border-box;
}

*,
*::before,
*::after {
    box-sizing: inherit;
}

html {
    overflow-x: hidden;
    width: 100%;
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
}

html,
body {
    min-height: 100%;
    margin: 0;
    padding: 0;
    font-family: var(--font-family);
    background: var(--color-primary);
    color: #0f172a;
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
}

body {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    padding: 0 0 16px;
    overflow-x: hidden;
}

.app-shell {
    width: 100%;
    max-width: 480px;
    display: flex;
    flex-direction: column;
    padding: 10px 14px 16px;
    gap: 12px;
    box-sizing: border-box;
    margin: 0 auto;
}

.app-shell.expanded {
    width: 100%;
    max-width: 100%;
    padding: 16px clamp(20px, 4vw, 40px) 32px;
    margin: 0;
    align-self: stretch;
}

.app-shell.expanded .app-header {
    display: none;
}

/* Admin, Accountant e Master layouts não devem ter max-width */
#companyAdminView .admin-layout,
#accountantView .admin-layout,
#masterView .admin-layout {
    max-width: 100%;
    width: 100%;
}

#companyAdminView .app-shell,
#accountantView .app-shell,
#masterView .app-shell {
    max-width: 100%;
    width: 100%;
    padding: 0;
}

.app-shell.expanded .card {
    box-shadow: 0 20px 60px rgba(0, 28, 40, 0.12);
}

.app-shell.expanded .card-header {
    padding: 20px 32px 16px;
    border-bottom: 2px solid rgba(0, 28, 40, 0.1);
    gap: 12px;
}

.app-shell.expanded .card-header h2 {
    color: var(--color-primary);
    font-size: 24px;
    font-weight: 700;
}

.app-shell.expanded .card-body {
    padding: 20px 32px;
    gap: 20px;
}

.app-shell.expanded .card-block {
    padding: 24px 28px;
}

.app-header {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    min-height: 40px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 16px;
}

.brand-icon {
    max-width: 156px;
    width: 100%;
    height: auto;
    object-fit: contain;
}

.brand-centered {
    justify-content: center;
    width: 100%;
    margin: 0 auto;
}

.app-shell.expanded .card-header .brand {
    margin-bottom: -8px;
}

#logoutBtn {
    position: absolute;
    right: 0;
}

.brand h1 {
    margin: 0;
    font-size: 28px;
}

.brand-rub {
    color: var(--color-yellow);
    font-weight: 700;
}

.brand p {
    margin: 2px 0 0;
    color: var(--color-secondary);
}

.app-main {
    display: grid;
    gap: 0;
    width: 100%;
    box-sizing: border-box;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.card {
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 60px rgba(15, 23, 42, 0.15), 0 0 0 1px rgba(15, 23, 42, 0.1);
    border: 2px solid rgba(225, 172, 59, 0.2);
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

/* Estilo de Login estilo DriveRub */
.auth-card-driverub {
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    width: 100%;
    max-width: 500px;
    padding: 24px 22px;
    transform: scale(1);
    transition: transform 0.5s ease-in-out, box-shadow 0.5s ease-in-out, max-width 0.3s ease-in-out;
    margin: 0 auto;
    border: none;
    display: block;
    position: relative;
    box-sizing: border-box;
}

.app-shell.expanded .auth-card-driverub {
    max-width: 100%;
    padding: 48px clamp(32px, 5vw, 64px);
}

.auth-card-driverub:hover {
    transform: scale(1);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.3);
}

.auth-card-logo {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 24px;
}

.auth-logo-img {
    max-height: 160px;
    height: auto;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

.auth-card-title {
    font-size: 0;
    margin: 0;
}

.auth-card-content {
    width: 100%;
}

.auth-form-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 16px;
    text-align: center;
    color: var(--color-primary);
}

.auth-form-helper {
    font-size: 14px;
    color: var(--color-secondary);
}

.auth-form {
    display: none;
    flex-direction: column;
    gap: 16px;
    animation: fadeIn 0.6s ease-out;
}

.auth-form.active {
    display: flex;
}

.auth-form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
}

.auth-form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.auth-label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    margin-bottom: 4px;
}

.auth-input {
    display: block;
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.2s ease;
    background: #ffffff;
    color: #111827;
}

.auth-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(0, 28, 40, 0.1);
}

.auth-input::placeholder {
    color: #9ca3af;
    font-size: 14px;
}

.auth-submit-btn {
    width: 100%;
    padding: 12px 18px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 700;
    background: linear-gradient(135deg, #ffb300 0%, #f4c162 100%);
    color: var(--color-primary);
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    margin-top: 4px;
}

.auth-submit-btn:hover {
    background: linear-gradient(135deg, #f4c162 0%, #ffb300 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.auth-submit-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.auth-switch-links {
    text-align: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.auth-switch-intro {
    margin: 0;
    font-size: 14px;
    color: #64748b;
    font-weight: 400;
}

.auth-switch-options {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
}

.auth-switch-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.auth-switch-link {
    color: var(--color-yellow);
    text-decoration: none;
    font-size: 13px;
    transition: all 0.2s ease;
    font-weight: 500;
    padding: 4px 0;
}

.auth-switch-link:hover {
    text-decoration: underline;
    color: var(--color-yellow-light);
}

.auth-switch-separator {
    display: inline-block;
    color: var(--color-yellow);
    font-weight: 600;
    margin: 0 6px;
}

/* Responsivo para login */
@media (max-width: 768px) {
    .auth-card-driverub {
        padding: 24px 20px;
        max-width: 100%;
        margin: 0;
        width: 100%;
        border-radius: 16px;
    }
    
    .auth-logo-img {
        max-height: 120px;
        height: auto;
        width: auto;
        max-width: 100%;
    }
    
    .auth-card-title {
        font-size: 20px;
        margin-bottom: 20px;
        line-height: 1.3;
        word-wrap: break-word;
    }
    
    .auth-form-title {
        font-size: 18px;
    }
    
    .auth-form-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .auth-switch-links {
        gap: 10px;
        padding-top: 16px;
    }
    
    .auth-switch-options {
        gap: 4px;
    }
    
    .auth-switch-row {
        gap: 6px;
    }
    
    .auth-switch-link {
        font-size: 12px;
    }
    
    .auth-switch-separator {
        font-size: 12px;
        margin: 0 2px;
    }
    
    .auth-form-group {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .auth-card-driverub {
        padding: 20px 16px;
        border-radius: 16px;
        width: 100%;
        max-width: 100%;
    }
    
    .auth-logo-img {
        max-height: 100px;
        height: auto;
        width: auto;
        max-width: 100%;
    }
    
    .auth-card-title {
        font-size: 18px;
        margin-bottom: 16px;
        line-height: 1.3;
    }
    
    .auth-form-title {
        font-size: 16px;
    }
    
    .auth-input {
        padding: 14px 16px;
        font-size: 16px; /* Evita zoom no iOS */
        width: 100%;
    }
    
    .auth-submit-btn {
        width: 100%;
        padding: 14px 20px;
    }

    /* Métricas do funcionário em mobile: 1 coluna */
    #employeeMetrics {
        grid-template-columns: 1fr !important;
        gap: 12px;
    }
    
    #employeeMetrics .metric {
        padding: 14px 16px;
    }
    
    #employeeMetrics .metric-value {
        font-size: 24px;
    }
    
    #employeeMetrics .metric-label {
        font-size: 12px;
    }

    .clock-actions-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .clock-section {
        padding: 16px;
    }
}

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

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.card-header {
    padding: 24px 20px 16px;
    border-bottom: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.card-header .brand {
    margin-bottom: 4px;
}

.company-admin-header {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 20px 32px;
    gap: 24px;
    border-bottom: 2px solid rgba(225, 172, 59, 0.2);
    flex-wrap: nowrap;
    box-sizing: border-box;
    width: 100%;
    position: relative;
    min-height: 80px;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 0 4px 16px rgba(0, 28, 40, 0.08), 0 1px 0 rgba(0, 0, 0, 0.04);
}

.header-logo-left {
    flex: 0 0 auto;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 60px;
    max-width: 80px;
}

.brand-icon-small {
    max-width: 60px;
    width: auto;
    height: auto;
    max-height: 40px;
    object-fit: contain;
    display: block;
}

/* Logo maior na versão web (visão colaborador) */
@media (min-width: 481px) {
    #employeeView .header-logo-left .brand-icon-small {
        max-width: 120px !important;
        max-height: 90px !important;
        width: auto !important;
        height: auto !important;
    }
}

.header-content-center {
    flex: 1 1 auto;
    text-align: center;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 0 12px;
    overflow: hidden;
}

.header-content-center h2 {
    margin: 0;
    font-size: 28px;
    font-weight: 700;
    color: var(--color-primary);
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
    line-height: 1.2;
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.header-content-center h2::before {
    content: '';
    display: inline-block;
    width: 4px;
    height: 32px;
    background: linear-gradient(180deg, var(--color-yellow), var(--color-yellow-dark));
    border-radius: 2px;
    flex-shrink: 0;
}

.header-subtitle {
    margin: 0;
    font-size: 14px;
    color: var(--color-secondary);
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
    line-height: 1.4;
    font-weight: 500;
    letter-spacing: 0.01em;
}

.header-content-center p {
    margin: 0;
    text-align: center;
    font-size: 12px;
    line-height: 1.3;
}

.header-content-center .hint {
    text-align: center;
    font-size: 11px;
}

.bank-hours-view {
    margin-top: 20px;
}

.bank-hours-view.hidden {
    display: none;
}

.header-actions-right {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
    flex-wrap: nowrap;
    min-width: 0;
}

.header-actions-right .btn-link {
    padding: 10px 14px;
    border-radius: 10px;
    background: rgba(0, 28, 40, 0.03);
    border: 1px solid rgba(0, 28, 40, 0.08);
    color: var(--color-primary);
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
}

.header-actions-right .btn-link:hover {
    background: rgba(225, 172, 59, 0.1);
    border-color: var(--color-yellow);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(225, 172, 59, 0.2);
}

.header-actions-right .btn-link:active {
    transform: translateY(0);
}

/* Ações desktop (escondidas em mobile) */
.header-actions-right-desktop {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    flex-wrap: nowrap;
}

/* Seção logo + ações (para mobile) */
.header-logo-section {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.company-code-box {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}

.code-label {
    font-size: 11px;
    color: var(--color-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.code-value {
    font-size: 18px;
    font-weight: 700;
    color: var(--color-yellow);
    letter-spacing: 2px;
    font-family: 'Courier New', monospace;
}

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

.card-body {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.card-block {
    background: rgba(0, 28, 40, 0.03);
    border-radius: var(--radius-md);
    padding: 20px 24px;
    border: 1px solid rgba(0, 28, 40, 0.08);
    backdrop-filter: blur(4px);
}

.card-block__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}

.card-block__header h3 {
    color: var(--color-primary);
    font-size: 18px;
    font-weight: 600;
    margin: 0;
    position: relative;
    padding-left: 12px;
}

.card-block__header h3::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 20px;
    background: var(--color-yellow);
    border-radius: 2px;
}

.form {
    display: none;
    flex-direction: column;
    gap: 12px;
    text-align: center;
}

.form.active {
    display: flex;
}

.form h2 {
    text-align: center;
    color: #0f172a;
    font-size: 24px;
    margin: 0 0 10px;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.form-subtitle {
    margin: 0;
    color: #475569;
    text-align: center;
    font-size: 14px;
    font-weight: 500;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-weight: 500;
}

.form-group span {
    color: #0f172a;
    font-weight: 600;
    font-size: 15px;
    letter-spacing: -0.01em;
}

.form-group input,
.form-group select,
.form-group textarea {
    border: 2px solid #e2e8f0;
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    font-size: 15px;
    background: #ffffff;
    color: #0f172a;
    transition: border 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    font-weight: 400;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-yellow);
    box-shadow: 0 0 0 4px rgba(225, 172, 59, 0.15);
    background: #ffffff;
}

.form-group input::placeholder,
.form-group select::placeholder,
.form-group textarea::placeholder {
    color: #94a3b8;
    font-weight: 400;
}

.form-grid {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    width: 100%;
    box-sizing: border-box;
}

.tabs {
    display: none;
}

.tab {
    display: none;
}

.auth-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
}

.auth-link {
    color: var(--color-yellow);
    text-decoration: none;
    font-size: 13px;
    transition: color 0.2s ease, opacity 0.2s ease;
    font-weight: 500;
}

.auth-link:hover {
    color: var(--color-yellow-dark);
    opacity: 0.9;
}

.auth-link.active {
    color: var(--color-yellow);
    font-weight: 600;
}

.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
}

.quick-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

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

/* Accordion para Métricas */
.metrics-accordion {
    margin-bottom: 16px;
}

.metrics-accordion-header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: rgba(0, 28, 40, 0.05);
    border: 1px solid rgba(0, 28, 40, 0.1);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 600;
    color: var(--color-primary);
    font-size: 14px;
    box-shadow: none;
    text-align: left;
}

.metrics-accordion-header:hover {
    background: rgba(0, 28, 40, 0.08);
    border-color: rgba(0, 28, 40, 0.2);
}

.accordion-icon {
    transition: transform 0.3s ease;
    font-size: 12px;
}

.metrics-accordion-content.collapsed {
    display: none !important;
}

.metrics-accordion-content {
    margin-top: 12px;
    animation: slideDown 0.3s ease;
}

.metrics-accordion-header.active .accordion-icon {
    transform: rotate(180deg);
}

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

/* Métricas da tela do funcionário: 2 colunas fixas */
#employeeMetrics {
    grid-template-columns: repeat(2, 1fr) !important;
}

/* Melhorias na seção de marcações recentes */
.time-entries-section {
    overflow: visible;
}

.time-entries-table-wrapper {
    position: relative;
}

.time-entries-table-wrapper::-webkit-scrollbar {
    height: 6px;
}

.time-entries-table-wrapper::-webkit-scrollbar-track {
    background: rgba(0, 28, 40, 0.05);
    border-radius: 3px;
}

.time-entries-table-wrapper::-webkit-scrollbar-thumb {
    background: rgba(0, 28, 40, 0.2);
    border-radius: 3px;
}

.time-entries-table-wrapper::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 28, 40, 0.3);
}

/* Mobile - melhorias na seção de marcações */
@media (max-width: 480px) {
    .time-entries-section {
        padding: 12px !important;
    }
    
    .time-entries-section .card-block__header h3 {
        font-size: 14px !important;
    }
    
    .time-entries-table-wrapper {
        margin: 0 -12px;
        padding: 0 12px;
    }
    
    .time-entries-table-header {
        font-size: 10px !important;
        padding: 6px 12px !important;
        gap: 8px !important;
    }
    
    .time-entries-list li {
        padding: 10px 12px !important;
        font-size: 12px !important;
    }
}

.metric {
    background: linear-gradient(135deg, rgba(0, 28, 40, 0.08), rgba(225, 172, 59, 0.05));
    border-radius: var(--radius-md);
    padding: 16px 18px;
    border: 2px solid rgba(225, 172, 59, 0.2);
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.metric:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 28, 40, 0.15);
    border-color: rgba(225, 172, 59, 0.4);
}

.metric-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.metric-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--color-yellow);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.metric-hint {
    font-size: 13px;
    color: var(--color-secondary);
}

.btn {
    border: none;
    border-radius: var(--radius-sm);
    padding: 10px 16px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.12);
}

.btn-primary {
    background: linear-gradient(120deg, var(--color-primary), var(--color-primary-dark));
    color: #fff;
    font-weight: 600;
    font-size: 15px;
    padding: 12px 24px;
    box-shadow: 0 4px 12px rgba(0, 28, 40, 0.2);
}

.btn-primary:hover {
    background: linear-gradient(120deg, var(--color-primary-dark), var(--color-primary));
    box-shadow: 0 6px 16px rgba(0, 28, 40, 0.3);
    transform: translateY(-1px);
}

.btn-outline {
    background: #fff;
    border: 1px solid var(--color-primary);
    color: var(--color-primary);
}

.btn-outline:hover {
    background: rgba(0, 28, 40, 0.05);
}

.btn-link {
    background: transparent;
    color: var(--color-primary);
    padding: 0;
    text-align: left;
}

.btn-link:hover {
    color: var(--color-primary-dark);
}

.btn-success {
    background: var(--color-success);
    color: #fff;
}

.btn-warning {
    background: linear-gradient(135deg, var(--color-yellow), var(--color-yellow-dark));
    color: #001c28;
    font-weight: 700;
    font-size: 15px;
    padding: 12px 24px;
    box-shadow: 0 4px 12px rgba(225, 172, 59, 0.3);
}

.btn-warning:hover {
    background: linear-gradient(135deg, var(--color-yellow-dark), var(--color-yellow));
    box-shadow: 0 6px 16px rgba(225, 172, 59, 0.4);
    transform: translateY(-1px);
}

.btn-info {
    background: var(--color-primary);
    color: #fff;
}

.btn-info:hover {
    background: var(--color-primary-dark);
}

.btn-danger {
    background: var(--color-danger);
    color: #fff;
}

.btn.full {
    width: 100%;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.view.hidden,
.hidden {
    display: none !important;
}

.modal {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(4px);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 24px;
    z-index: 10000;
}

.modal.hidden {
    display: none !important;
}

.modal-content {
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    max-width: 420px;
    width: 100%;
    max-height: 90vh;
    padding: 32px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    overflow: hidden;
}

.modal-content header {
    flex-shrink: 0;
}

.modal-content .modal-body {
    overflow-y: auto;
    overflow-x: hidden;
    flex: 1;
    min-height: 0;
    padding-right: 8px;
    margin-right: -8px;
}

.modal-content .modal-actions {
    flex-shrink: 0;
    margin-top: 0;
    padding-top: 12px;
    border-top: 1px solid rgba(0, 28, 40, 0.1);
}

.modal-content .modal-body::-webkit-scrollbar {
    width: 6px;
}

.modal-content .modal-body::-webkit-scrollbar-track {
    background: rgba(0, 28, 40, 0.05);
    border-radius: 3px;
}

.modal-content .modal-body::-webkit-scrollbar-thumb {
    background: rgba(0, 28, 40, 0.2);
    border-radius: 3px;
}

.modal-content .modal-body::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 28, 40, 0.3);
}

.modal-content header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.modal-content h2 {
    margin: 0;
}

.modal-close {
    border: none;
    background: transparent;
    font-size: 24px;
    cursor: pointer;
    color: var(--color-secondary);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 0;
    padding-top: 12px;
    border-top: 1px solid rgba(0, 28, 40, 0.1);
    flex-shrink: 0;
}

.data-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.data-list li {
    background: linear-gradient(to right, #fff, rgba(225, 172, 59, 0.02));
    border-radius: var(--radius-sm);
    border: 1px solid rgba(225, 172, 59, 0.25);
    border-left: 4px solid var(--color-primary);
    padding: 12px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s ease;
}

.data-list li:hover {
    border-left-color: var(--color-yellow);
    background: linear-gradient(to right, rgba(225, 172, 59, 0.05), rgba(0, 28, 40, 0.02));
    transform: translateX(4px);
}

.list-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
    color: var(--color-secondary);
    font-size: 13px;
}

.data-list li.empty {
    justify-content: center;
    color: var(--color-secondary);
    font-style: italic;
}

.table {
    width: 100%;
    border-collapse: collapse;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.2);
}

.table-wrapper {
    margin-top: 18px;
}

.report-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.table th,
.table td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid rgba(148, 163, 184, 0.24);
}

.table tbody tr:hover {
    background: rgba(225, 172, 59, 0.05);
}

.status-select {
    border-radius: var(--radius-sm);
    border: 1px solid var(--color-border);
    padding: 8px 10px;
    background: #fff;
}

.table thead {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    color: #fff;
    font-weight: 600;
}

.table thead th {
    color: #fff;
    border-bottom: 2px solid var(--color-yellow);
}

.table tr.empty td {
    text-align: center;
    color: var(--color-secondary);
}

.notification-container {
    position: fixed;
    top: 28px;
    right: 28px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 10001; /* Acima dos modais (z-index: 10000) */
}

.notification {
    background: #0f172a;
    color: #fff;
    border-radius: var(--radius-sm);
    padding: 14px 18px;
    min-width: 260px;
    box-shadow: 0 18px 32px rgba(15, 23, 42, 0.18);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    animation: fadeIn 0.2s ease;
}

.notification.success { background: var(--color-success); }
.notification.error { background: var(--color-danger); }
.notification.warning { background: var(--color-warning); color: #1f2937; }
.notification.info { background: var(--color-primary); }

.notification button {
    background: none;
    border: none;
    color: inherit;
    font-size: 18px;
    cursor: pointer;
}

.bullet-list {
    margin: 0;
    padding-left: 18px;
    color: var(--color-secondary);
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/* Employee Dashboard Layout */
.employee-container {
    display: flex;
    gap: 20px;
    width: 100%;
    max-width: 1400px;
}

.employee-sidebar {
    width: 240px;
    min-width: 240px;
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-shadow: 0 20px 60px rgba(15, 23, 42, 0.15), 0 0 0 1px rgba(15, 23, 42, 0.1);
    border: 2px solid rgba(225, 172, 59, 0.2);
    height: fit-content;
    position: sticky;
    top: 20px;
}

.sidebar-header {
    text-align: center;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(15, 23, 42, 0.1);
}

.sidebar-logo {
    width: 60px;
    height: auto;
    margin-bottom: 8px;
}

.sidebar-header h3 {
    margin: 0;
    font-size: 16px;
    color: var(--color-primary);
    font-weight: 700;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: transparent;
    border: none;
    border-radius: var(--radius-md);
    color: var(--color-secondary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
    width: 100%;
}

.nav-item:hover {
    background: rgba(0, 28, 40, 0.05);
    color: var(--color-primary);
}

.nav-item.active {
    background: rgba(225, 172, 59, 0.15);
    color: var(--color-primary);
    font-weight: 600;
}

.nav-item span:first-child {
    font-size: 18px;
}

.sidebar-footer {
    padding-top: 20px;
    border-top: 1px solid rgba(15, 23, 42, 0.1);
}

.employee-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.accountant-company-list {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    list-style: none;
    padding: 0;
    margin: 0;
}

.accountant-company-card {
    background: linear-gradient(135deg, rgba(0, 28, 40, 0.04), rgba(225, 172, 59, 0.06));
    border: 1px solid rgba(0, 28, 40, 0.12);
    border-radius: var(--radius-md);
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.accountant-company-card header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.accountant-company-card h4 {
    margin: 0;
    font-size: 18px;
    color: var(--color-primary);
}

.accountant-company-card .accountant-company-meta {
    display: flex;
    flex-direction: column;
    gap: 4px;
    color: var(--color-secondary);
    font-size: 13px;
}

.accountant-company-card footer {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

.accountant-report-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.accountant-company-list .hint {
    margin: 0;
    width: 100%;
}

.accountant-company-code {
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--color-yellow);
}

.accountant-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(0, 28, 40, 0.08);
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.accountant-badge.active {
    background: rgba(22, 163, 74, 0.12);
    color: #166534;
}

.accountant-badge.pending {
    background: rgba(225, 172, 59, 0.12);
    color: #92400e;
}

.accountant-badge.suspended {
    background: rgba(220, 38, 38, 0.15);
    color: #991b1b;
}

.employee-section {
    display: none;
}

.employee-section.active {
    display: block;
}

.clock-display {
    font-size: 32px;
    font-weight: 700;
    color: var(--color-primary);
    font-family: 'Courier New', monospace;
    margin: 8px 0;
    text-align: center;
}

.metrics-grid.expanded {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.metrics-grid.expanded .metric {
    min-height: 120px;
}

/* Responsividade: Métricas do funcionário em tablets */
@media (max-width: 768px) {
    #employeeMetrics {
        grid-template-columns: 1fr !important;
        gap: 12px;
    }
}

.btn-large {
    padding: 20px 24px;
    font-size: 16px;
    font-weight: 600;
}

.btn-icon {
    font-size: 24px;
    margin-right: 8px;
}

.actions-grid.large {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.actions-grid.large .btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.clock-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
}

.clock-actions-grid .btn-large {
    min-height: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 16px;
    font-weight: 700;
    border-radius: var(--radius-md);
    box-shadow: 0 4px 12px rgba(0, 28, 40, 0.1);
    transition: all 0.3s ease;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.clock-actions-grid .btn-large::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.clock-actions-grid .btn-large:hover::before {
    left: 100%;
}

.clock-actions-grid .btn-large:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 28, 40, 0.15);
}

.clock-actions-grid .btn-large:active {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 28, 40, 0.1);
}

.clock-actions-grid .btn-success {
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
    border-color: #16a34a;
    color: white;
}

.clock-actions-grid .btn-success:hover {
    background: linear-gradient(135deg, #15803d 0%, #166534 100%);
    border-color: #15803d;
}

.clock-actions-grid .btn-primary {
    background: linear-gradient(135deg, #001c28 0%, #002a3a 100%);
    border-color: #001c28;
    color: white;
}

.clock-actions-grid .btn-primary:hover {
    background: linear-gradient(135deg, #002a3a 0%, #003a4a 100%);
    border-color: #002a3a;
}

.clock-actions-grid .btn-danger {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    border-color: #dc2626;
    color: white;
}

.clock-actions-grid .btn-danger:hover {
    background: linear-gradient(135deg, #b91c1c 0%, #991b1b 100%);
    border-color: #b91c1c;
}

.clock-actions-grid .btn-icon {
    font-size: 32px;
    line-height: 1;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.clock-actions-grid .btn-text {
    font-size: 15px;
    letter-spacing: 0.3px;
}

.clock-section {
    background: linear-gradient(135deg, rgba(0, 28, 40, 0.03) 0%, rgba(225, 172, 59, 0.05) 100%);
    border: 2px solid rgba(225, 172, 59, 0.2);
    padding: 20px;
}

.clock-section .card-block__header {
    display: none;
}

.time-entries-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.time-entries-list li {
    transition: background-color 0.2s ease;
}

/* Garantir alinhamento à esquerda nos cabeçalhos e dados da tabela */
.time-entries-table-header {
    display: grid !important;
    grid-template-columns: 60px 1fr 1fr 1fr 1fr !important;
    text-align: left;
}

.time-entries-table-header > span {
    text-align: left !important;
    display: block !important;
    grid-column: auto !important;
}

.time-entries-list li {
    text-align: left;
}

.time-entries-list li > * {
    text-align: left !important;
    justify-content: flex-start !important;
    display: flex;
    align-items: center;
}

.time-entries-list li:not(.empty):hover {
    background-color: rgba(0, 28, 40, 0.03);
}

@media (max-width: 480px) {
    .time-entries-table-header,
    .time-entries-list li {
        grid-template-columns: 50px 1fr 1fr 1fr 1fr;
        gap: 8px;
        padding: 10px 12px;
        font-size: 13px;
    }

    #employeeLiveClock {
        font-size: 14px;
    }
}

.form-inline {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 16px;
    align-items: end;
}

.profile-info {
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 12px 20px;
    margin: 0;
}

.profile-info dt {
    font-weight: 600;
    color: var(--color-primary);
}

.profile-info dd {
    margin: 0;
    color: var(--color-secondary);
}

@media (max-width: 1024px) {
    .employee-container {
        flex-direction: column;
    }
    
    .employee-sidebar {
        width: 100%;
        position: relative;
        top: 0;
    }
    
    .sidebar-nav {
        flex-direction: row;
        overflow-x: auto;
    }
    
    .nav-item {
        white-space: nowrap;
        min-width: fit-content;
    }
    
    .metrics-grid.expanded {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .actions-grid.large {
        grid-template-columns: 1fr;
    }
    
    .form-inline {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .metrics-grid.expanded {
        grid-template-columns: 1fr;
    }
}

.hint {
    color: var(--color-secondary);
    font-size: 14px;
    margin-top: 12px;
}

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

/* Modal grande */
.modal-content.modal-large {
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
}

/* Lista de colaboradores no modal */
.employees-settings-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.employee-settings-item {
    background: rgba(0, 28, 40, 0.03);
    border: 1px solid rgba(0, 28, 40, 0.08);
    border-radius: var(--radius-md);
    padding: 20px;
    transition: all 0.2s ease;
}

.employee-settings-item:hover {
    background: rgba(0, 28, 40, 0.05);
    border-color: var(--color-yellow);
    box-shadow: 0 4px 12px rgba(225, 172, 59, 0.1);
}

.employee-settings-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 12px;
}

.employee-settings-header > div {
    flex: 1;
}

.employee-settings-header strong {
    display: block;
    color: var(--color-primary);
    font-size: 16px;
    margin-bottom: 4px;
}

.employee-settings-header small {
    display: block;
    color: var(--color-secondary);
    font-size: 13px;
    margin-bottom: 8px;
}

.employee-settings-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px;
    margin-top: 12px;
}

.detail-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.detail-label {
    font-size: 12px;
    color: var(--color-secondary);
    font-weight: 500;
}

.detail-value {
    font-size: 14px;
    color: var(--color-primary);
    font-weight: 600;
}

/* Badges */
.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: var(--color-primary);
    color: #fff;
    margin-top: 4px;
}

.badge-small {
    padding: 2px 8px;
    font-size: 10px;
    margin-left: 8px;
}

.badge-info {
    background: var(--color-primary);
    color: #fff;
}

.badge-warning {
    background: var(--color-yellow);
    color: var(--color-primary);
}

/* Lista de colaboradores na aba Equipe */
.employee-list-item {
    background: linear-gradient(to right, #fff, rgba(225, 172, 59, 0.02));
    border: 1px solid rgba(0, 28, 40, 0.1);
    border-radius: var(--radius-md);
    padding: 16px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.employee-list-item:hover {
    background: rgba(0, 28, 40, 0.05) !important;
    border-color: var(--color-yellow);
    transform: translateX(4px);
    box-shadow: 0 2px 8px rgba(225, 172, 59, 0.2);
}

.employee-list-main {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 12px;
}

.employee-list-main > div {
    flex: 1;
}

.employee-list-main strong {
    display: block;
    color: var(--color-primary);
    font-size: 15px;
    margin-bottom: 4px;
}

.employee-list-main small {
    display: block;
    color: var(--color-secondary);
    font-size: 13px;
}

@media (max-width: 768px) {
    .app-shell {
        padding: 24px clamp(16px, 4vw, 32px);
    }

    .card-body {
        padding: 24px;
    }

    .card-block {
        padding: 16px 18px;
    }

    .notification-container {
        top: auto;
        bottom: 24px;
        right: 50%;
        transform: translateX(50%);
    }

    .employee-settings-details {
        grid-template-columns: 1fr;
    }

    .employee-list-main {
        flex-direction: column;
    }
}

/* Dashboard Inteligente */
.dashboard-intelligent {
    background: linear-gradient(135deg, rgba(0, 28, 40, 0.05) 0%, rgba(225, 172, 59, 0.05) 100%);
    border: 1px solid rgba(0, 28, 40, 0.1);
}

.dashboard-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.dashboard-metric {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: #fff;
    border-radius: var(--radius-md);
    border: 1px solid rgba(0, 28, 40, 0.1);
    transition: all 0.2s ease;
}

.dashboard-metric:hover {
    border-color: var(--color-yellow);
    box-shadow: 0 4px 12px rgba(225, 172, 59, 0.15);
    transform: translateY(-2px);
}

.dashboard-metric .metric-icon {
    font-size: 32px;
    line-height: 1;
}

.dashboard-metric .metric-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dashboard-metric .metric-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1.2;
}

.dashboard-metric .metric-label {
    font-size: 13px;
    color: var(--color-secondary);
    font-weight: 500;
}

/* Busca/Filtro */
.search-box {
    position: relative;
    display: flex;
    align-items: center;
    max-width: 300px;
    width: 100%;
}

.search-input {
    width: 100%;
    padding: 10px 40px 10px 16px;
    border: 2px solid rgba(0, 28, 40, 0.1);
    border-radius: var(--radius-sm);
    font-size: 14px;
    transition: all 0.2s ease;
}

.search-input:focus {
    outline: none;
    border-color: var(--color-yellow);
    box-shadow: 0 0 0 4px rgba(225, 172, 59, 0.15);
}

.search-icon {
    position: absolute;
    right: 12px;
    font-size: 18px;
    color: var(--color-secondary);
    pointer-events: none;
}

.search-box-modal {
    margin-bottom: 20px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* Detalhes do colaborador */
.employee-details-inline {
    display: flex;
    gap: 16px;
    margin-top: 8px;
    flex-wrap: wrap;
}

.employee-details-inline .detail-info {
    font-size: 12px;
    color: var(--color-secondary);
}

.employee-details-inline .detail-info strong {
    color: var(--color-primary);
    font-weight: 600;
    margin-right: 4px;
}

@media (max-width: 768px) {
    .dashboard-metrics {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .header-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .search-box {
        max-width: 100%;
    }
}

/* ========================================
   RESPONSIVIDADE COMPLETA
   ======================================== */

/* Desktop (acima de 1200px) - já está configurado */

/* Tablet (768px - 1199px) */
@media (max-width: 1199px) {
    .app-shell.expanded {
        width: 100%;
        max-width: 100%;
        padding: 24px clamp(20px, 3vw, 32px);
    }
    
    .app-shell.expanded .card-header {
        padding: 16px 24px 12px;
    }
    
    .app-shell.expanded .card-body {
        padding: 16px 24px;
    }
    
    .app-shell.expanded .card-block {
        padding: 20px 24px;
    }
    
    .form-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Tablet Pequeno / Mobile Grande (481px - 767px) */
@media (max-width: 768px) {
    body {
        padding: 0;
        overflow-x: hidden;
    }
    
    .app-shell {
        width: 100%;
        max-width: 100%;
        padding: 12px;
        gap: 12px;
        margin: 0;
    }
    
    .app-shell.expanded {
        width: 100%;
        max-width: 100%;
        padding: 12px;
        margin: 0;
    }
    
    .app-shell.expanded .auth-card-driverub {
        max-width: 100%;
        padding: 32px 24px;
    }
    
    .auth-card-driverub {
        padding: 24px 20px;
        max-width: 100%;
    }
    
    .auth-logo-img {
        height: 100px;
    }
    
    .auth-card-title {
        font-size: 20px;
        margin-bottom: 20px;
    }
    
    .auth-form-title {
        font-size: 18px;
    }

    .card-body {
        padding: 16px;
    }

    .card-block {
        padding: 16px;
    }
    
    .card-header {
        padding: 20px 16px 12px;
    }
    
    .app-shell.expanded .card-header {
        padding: 16px;
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .company-admin-header {
        flex-wrap: wrap;
        padding: 12px 16px !important;
        gap: 12px;
    }
    
    .header-logo-left {
        order: 1;
        flex: 0 0 auto;
    }
    
    .header-content-center {
        order: 2;
        width: 100%;
        min-width: 0;
        text-align: center;
        margin-top: 8px;
    }
    
    .header-content-center h2 {
        text-align: center;
        font-size: 18px;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
    
    .header-subtitle {
        text-align: center;
        font-size: 12px;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
    
    .header-actions-right {
        order: 3;
        width: 100%;
        justify-content: space-between;
        margin-top: 8px;
        flex-wrap: wrap;
        gap: 8px;
    }

    .notification-container {
        top: auto;
        bottom: 16px;
        right: 16px;
        left: 16px;
        transform: none;
        max-width: calc(100vw - 32px);
    }
    
    .brand-icon {
        max-width: 140px;
        width: 100%;
    }
    
    .brand-icon-small {
        max-width: 90px;
        width: 100%;
    }
    
    .form h2 {
        font-size: 20px;
    }
    
    .form-subtitle {
        font-size: 13px;
    }
    
    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 14px 16px;
        font-size: 16px; /* Evita zoom no iOS */
    }
    
    .btn {
        padding: 14px 24px;
        font-size: 16px;
        min-height: 48px; /* Área de toque maior */
    }
    
    .btn-small {
        padding: 10px 16px;
        font-size: 14px;
        min-height: 40px;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .actions-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .clock-actions-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .dashboard-metrics {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .dashboard-metric {
        padding: 16px;
    }
    
    .dashboard-metric .metric-icon {
        font-size: 28px;
    }
    
    .dashboard-metric .metric-value {
        font-size: 20px;
    }
    
    .dashboard-metric .metric-label {
        font-size: 12px;
    }
    
    .employee-settings-details {
        grid-template-columns: 1fr;
    }

    .employee-list-main {
        flex-direction: column;
        gap: 8px;
    }
    
    .header-actions {
        flex-direction: column;
        width: 100%;
        gap: 12px;
    }
    
    .search-box {
        max-width: 100%;
    }
    
    .table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        width: 100%;
        margin: 0 -12px;
        padding: 0 12px;
    }
    
    .table {
        min-width: 600px;
        width: 100%;
    }
    
    .data-list li {
        padding: 14px 16px;
    }
    
    .card-block__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .card-block__header h3 {
        font-size: 16px;
    }
    
    .metrics-grid.expanded {
        grid-template-columns: 1fr;
    }
}

/* Mobile Pequeno (até 480px) */
@media (max-width: 480px) {
    body {
        padding: 0;
        overflow-x: hidden;
        -webkit-text-size-adjust: 100%;
        -ms-text-size-adjust: 100%;
    }
    
    .app-shell {
        width: 100%;
        max-width: 100%;
        padding: 8px;
        gap: 10px;
        margin: 0;
    }
    
    .app-shell.expanded {
        width: 100%;
        max-width: 100%;
        padding: 8px;
        margin: 0;
    }
    
    .app-shell.expanded .auth-card-driverub {
        padding: 32px 24px;
        max-width: 100%;
    }
    
    .card {
        border-radius: var(--radius-md);
    }
    
    .card-header {
        padding: 16px 12px 10px;
    }
    
    .card-body {
        padding: 12px;
    }
    
    .card-block {
        padding: 12px;
    }
    
    /* Status card do funcionário */
    #employeeStatusIndicator {
        width: 10px;
        height: 10px;
    }
    
    #employeeStatusText {
        font-size: 13px !important;
    }
    
    #employeeLastPoint {
        font-size: 11px !important;
    }
    
    #employeeNextActionHint {
        font-size: 11px !important;
        padding: 6px 10px !important;
        width: 100%;
        text-align: center;
        margin-top: 8px;
    }
    
    .employee-status-container {
        flex-direction: column;
        align-items: flex-start !important;
    }
    
    .employee-status-container > div:first-child {
        width: 100%;
        min-width: 100% !important;
    }
    
    /* Header do funcionário em mobile */
    .company-admin-header {
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .header-content-center {
        width: 100%;
        order: 1;
    }
    
    .header-actions-right {
        width: 100%;
        justify-content: space-between;
        order: 2;
    }
    
    /* Tabela de marcações recentes - scroll horizontal */
    .time-entries-table-header,
    .time-entries-list {
        font-size: 12px;
    }
    
    .time-entries-list li {
        padding: 10px 8px;
        font-size: 12px;
    }
    
    .brand-icon {
        max-width: 120px;
        width: 100%;
    }
    
    .brand-icon-small {
        max-width: 70px;
        width: 100%;
    }
    
    .form h2 {
        font-size: 18px;
        margin-bottom: 8px;
    }
    
    .form-subtitle {
        font-size: 12px;
    }
    
    .form-group span {
        font-size: 13px;
    }
    
    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 12px 14px;
        font-size: 16px;
    }
    
    .btn {
        padding: 12px 20px;
        font-size: 15px;
        width: 100%;
    }
    
    .btn:not(.full) {
        width: 100%;
    }
    
    .actions-grid {
        grid-template-columns: 1fr;
    }
    
    .clock-actions-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .clock-actions-grid .btn-large {
        min-height: 90px;
        min-width: 100%; /* Garante touch target adequado */
        padding: 20px;
        touch-action: manipulation; /* Remove delay de 300ms no touch */
        -webkit-tap-highlight-color: rgba(0, 28, 40, 0.1);
    }
    
    .clock-actions-grid .btn-icon {
        font-size: 28px;
    }
    
    .clock-actions-grid .btn-text {
        font-size: 14px;
    }
    
    /* Garante que botões tenham área de toque adequada (mínimo 44x44px) */
    .btn-large {
        min-height: 44px;
        min-width: 44px;
    }
    
    .dashboard-metrics {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .dashboard-metric {
        padding: 14px;
    }
    
    .dashboard-metric .metric-icon {
        font-size: 24px;
    }
    
    .dashboard-metric .metric-value {
        font-size: 18px;
    }
    
    .company-admin-header {
        padding: 12px !important;
    }
    
    .header-content-center {
        text-align: center;
    }
    
    .header-content-center h2 {
        font-size: 16px;
        text-align: center;
    }
    
    .header-subtitle {
        font-size: 11px;
        text-align: center;
    }
    
    .code-value {
        font-size: 16px;
    }
    
    .table-wrapper {
        margin: 0 -12px;
        padding: 0 12px;
    }
    
    .table {
        font-size: 13px;
    }
    
    .table th,
    .table td {
        padding: 10px 8px;
    }
    
    .table thead th {
        font-size: 12px;
    }
    
    .data-list li {
        padding: 12px;
        font-size: 14px;
    }
    
    .card-block__header h3 {
        font-size: 15px;
    }
    
    .auth-links {
        flex-direction: column;
        gap: 12px;
    }
    
    .auth-links span {
        display: none;
    }
    
    .auth-link {
        display: block;
        padding: 12px;
        text-align: center;
        background: rgba(225, 172, 59, 0.1);
        border-radius: var(--radius-sm);
    }
    
    .modal-content {
        margin: 10px;
        max-height: calc(100vh - 20px);
        max-width: calc(100vw - 20px);
    }
    
    .modal-content header {
        padding: 16px;
    }
    
    .modal-content .modal-body {
        padding: 16px;
    }
    
    .modal-actions {
        padding: 16px;
        gap: 10px;
    }
    
    .modal-actions .btn {
        flex: 1;
    }
}

/* Mobile Extra Pequeno (até 360px) */
@media (max-width: 360px) {
    .app-shell {
        padding: 6px;
    }
    
    .form h2 {
        font-size: 16px;
    }
    
    .brand-icon {
        max-width: 80px;
        width: 100%;
    }
    
    .dashboard-metric .metric-value {
        font-size: 16px;
    }
    
    .table {
        font-size: 12px;
    }
    
    .table th,
    .table td {
        padding: 8px 6px;
    }
    
    /* Ajustes extras para telas muito pequenas */
    .clock-actions-grid .btn-large {
        min-height: 80px;
        padding: 16px;
    }
    
    .clock-actions-grid .btn-icon {
        font-size: 24px;
    }
    
    .clock-actions-grid .btn-text {
        font-size: 13px;
    }
    
    #employeeMetrics .metric-value {
        font-size: 20px;
    }
    
    .card-block {
        padding: 10px;
    }
}

/* ============================================
   CORREÇÕES DE RESPONSIVIDADE - VISÃO COLABORADOR
   ============================================ */

/* Mobile pequeno (até 360px) - Header ultra compacto */
@media (max-width: 360px) {
    #employeeView .company-admin-header {
        padding: 6px 8px !important;
        gap: 4px !important;
        min-height: 44px !important;
        max-height: 44px !important;
    }
    
    #employeeView .header-logo-left {
        flex: 0 0 32px !important;
        max-width: 32px !important;
        min-width: 32px !important;
        padding: 0 !important;
    }
    
    #employeeView .header-logo-left .brand-icon-small {
        max-width: 32px !important;
        max-height: 24px !important;
        padding: 0 !important;
    }
    
    #employeeView .header-content-center {
        padding: 0 4px !important;
        gap: 0 !important;
    }
    
    #employeeView .header-content-center h2 {
        font-size: 11px !important;
        line-height: 1.1 !important;
        margin: 0 !important;
    }
    
    #employeeView .header-content-center p {
        font-size: 8px !important;
        line-height: 1 !important;
        margin: 0 !important;
    }
    
    #employeeView .header-actions-right {
        gap: 2px !important;
        padding: 0 !important;
    }
    
    #employeeView .header-actions-right .btn {
        min-width: 24px !important;
        width: 24px !important;
        height: 24px !important;
        padding: 2px !important;
        font-size: 12px !important;
        margin: 0 !important;
    }
    
    #employeeView .header-actions-right #logoutBtnEmployee {
        min-width: auto !important;
        width: auto !important;
        padding: 2px 6px !important;
        font-size: 9px !important;
        height: 24px !important;
    }
    
    #employeeView .header-content-center .header-clock-label {
        display: none;
    }
}

/* Mobile (até 480px) - Header: Logo esquerda, ? e 👤 direita */
@media (max-width: 480px) {
    #employeeView .company-admin-header {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        padding: 8px 10px !important;
        gap: 8px !important;
        min-height: 50px !important;
        overflow: hidden !important;
        flex-wrap: nowrap !important;
    }
    
    /* Logo à esquerda - AUMENTADA EM 300% */
    #employeeView .header-logo-left {
        flex: 0 0 auto !important;
        max-width: 120px !important;
        min-width: 120px !important;
        padding: 0 !important;
        margin: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
    
    #employeeView .header-logo-left .brand-icon-small {
        max-width: 120px !important;
        max-height: 90px !important;
        width: auto !important;
        height: auto !important;
        padding: 0 !important;
        margin: 0 !important;
    }
    
    /* Esconde conteúdo central em mobile (relógio e subtítulo) */
    #employeeView .header-content-center {
        display: none !important;
    }
    
    /* ? e 👤 NO CANTO DIREITO - SEMPRE VISÍVEIS */
    #employeeView .header-actions-right {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: flex-end !important;
        gap: 4px !important;
        flex-shrink: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        margin-left: auto !important;
        min-width: 70px !important;
        width: auto !important;
        position: relative !important;
    }
    
    /* Mostra nome do colaborador no mobile - dentro do header-actions-right */
    #employeeView .header-actions-right::before {
        content: attr(data-employee-name);
        font-size: 11px !important;
        font-weight: 600 !important;
        color: var(--color-primary) !important;
        margin-right: 6px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        max-width: 120px !important;
        display: inline-block !important;
        flex-shrink: 1 !important;
        order: -1 !important;
    }
    
    #employeeView .header-actions-right .btn {
        padding: 4px 6px !important;
        min-width: 30px !important;
        width: 30px !important;
        height: 30px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 14px !important;
        border-radius: 4px;
        flex-shrink: 0 !important;
        margin: 0 !important;
        background: transparent !important;
        border: none !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    
    #employeeView .header-actions-right .btn span {
        margin: 0 !important;
        padding: 0 !important;
        font-size: 18px !important;
        line-height: 1;
    }
    
    /* Garantir que os botões específicos estejam visíveis */
    #employeeView .header-actions-right #employeeHelpBtn,
    #employeeView .header-actions-right #employeeProfileBtn {
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    
    /* Botão Sair embaixo dos botões de registro - SEMPRE VISÍVEL EM MOBILE */
    #employeeView .employee-logout-mobile {
        display: block !important;
        margin-top: 12px !important;
        text-align: center !important;
    }
    
    #employeeView .employee-logout-mobile #logoutBtnEmployeeMobile {
        padding: 8px 20px !important;
        font-size: 13px !important;
        width: auto;
        min-width: 100px;
        border-radius: var(--radius-sm);
    }
    
    /* Esconde botão Sair mobile em desktop */
    @media (min-width: 481px) {
        #employeeView .employee-logout-mobile {
            display: none !important;
        }
    }
    
    /* Tabela de marcações - cabeçalhos LADO A LADO horizontalmente, NÃO EMPILHADOS */
    #employeeView .time-entries-table-header {
        display: grid !important;
        grid-template-columns: 28px 0.7fr 0.8fr 0.8fr 0.6fr !important;
        gap: 2px !important;
        padding: 5px 3px !important;
        font-size: 6.5px !important;
        font-weight: 600 !important;
        text-transform: uppercase !important;
        background: rgba(0, 28, 40, 0.05) !important;
        border-radius: var(--radius-sm) !important;
        margin-bottom: 8px !important;
        width: 100% !important;
        box-sizing: border-box !important;
        overflow: visible !important;
        min-width: 0 !important;
    }
    
    /* TODAS as células do cabeçalho - FORÇA LADO A LADO, NÃO EMPILHADAS, ALINHADAS À ESQUERDA */
    #employeeView .time-entries-table-header {
        display: grid !important;
        text-align: left !important;
    }
    
    #employeeView .time-entries-table-header > span {
        display: block !important;
        text-align: left !important;
        font-size: 6.5px !important;
        line-height: 1 !important;
        white-space: nowrap !important;
        word-break: normal !important;
        overflow: visible !important;
        padding: 1px !important;
        min-width: 0 !important;
    }
    
    /* Células multiline - não usado mais, mas mantido para compatibilidade */
    #employeeView .time-entries-table-header .header-cell-multiline {
        display: block !important;
        text-align: left !important;
        font-size: 6.5px !important;
        line-height: 1 !important;
        padding: 1px !important;
        min-width: 0 !important;
    }
    
    #employeeView .time-entries-table-header .header-cell-multiline .line1,
    #employeeView .time-entries-table-header .header-cell-multiline .line2 {
        display: block !important;
        font-size: 5.5px !important;
        line-height: 0.9 !important;
        white-space: nowrap !important;
    }
    
    /* Lista de marcações - scroll horizontal se necessário */
    #employeeView .time-entries-list {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        width: 100%;
        display: block;
    }
    
    #employeeView .time-entries-list li {
        display: grid !important;
        grid-template-columns: 28px 0.7fr 0.8fr 0.8fr 0.6fr !important;
        gap: 2px !important;
        padding: 6px 3px !important;
        font-size: 9px !important;
        border-bottom: 1px solid rgba(0, 28, 40, 0.1);
        width: 100% !important;
        box-sizing: border-box !important;
        min-width: 0 !important;
    }
    
    #employeeView .time-entries-list li > * {
        display: flex !important;
        align-items: center !important;
        justify-content: flex-start !important;
        text-align: left !important;
        font-size: 9px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        min-width: 0 !important;
    }
}

/* Tablet e Mobile grande (481px - 768px) */
@media (min-width: 481px) and (max-width: 768px) {
    #employeeView .company-admin-header {
        grid-template-columns: 60px 1fr auto;
        padding: 12px 16px !important;
        gap: 12px !important;
    }
    
    #employeeView .header-logo-left .brand-icon-small {
        max-width: 60px;
        max-height: 40px;
    }
    
    #employeeView .header-content-center {
        padding: 0 8px;
    }
    
    #employeeView .header-content-center h2 {
        font-size: 16px !important;
    }
    
    #employeeView .header-content-center h2::before {
        width: 3px !important;
        height: 20px !important;
    }
    
    #employeeView .header-content-center p {
        font-size: 11px !important;
    }
    
    #employeeView .header-actions-right .btn {
        min-width: 36px;
        width: 36px;
        height: 36px;
        padding: 8px !important;
        font-size: 18px;
    }
}

/* Tablet grande e Desktop pequeno (769px - 1024px) */
@media (min-width: 769px) and (max-width: 1024px) {
    #employeeView .company-admin-header {
        display: flex !important;
        flex-direction: row;
        padding: 14px 20px !important;
        gap: 16px !important;
    }
    
    #employeeView .header-logo-left {
        flex: 0 0 auto;
        max-width: 70px;
    }
    
    #employeeView .header-content-center {
        flex: 1;
        text-align: center;
        padding: 0 12px;
    }
    
    #employeeView .header-content-center h2 {
        font-size: 17px !important;
    }
    
    #employeeView .header-content-center p {
        font-size: 12px !important;
    }
    
    #employeeView .header-actions-right {
        flex-direction: row;
        gap: 8px;
    }
    
    #employeeView .header-actions-right .btn {
        min-width: auto;
        width: auto;
        height: auto;
        padding: 6px 10px !important;
        font-size: 14px;
    }
    
    #employeeView .header-actions-right #employeeUserInfo {
        display: flex !important;
        margin-right: 8px;
    }
}

/* Desktop (acima de 1024px) */
@media (min-width: 1025px) {
    #employeeView .company-admin-header {
        display: flex !important;
        flex-direction: row;
        padding: 16px 24px !important;
        gap: 20px !important;
    }
    
    #employeeView .header-logo-left {
        flex: 0 0 auto;
        max-width: 80px;
    }
    
    #employeeView .header-content-center {
        flex: 1;
        text-align: center;
        padding: 0 16px;
    }
    
    #employeeView .header-content-center h2 {
        font-size: 18px !important;
    }
    
    #employeeView .header-content-center p {
        font-size: 13px !important;
    }
    
    #employeeView .header-actions-right {
        flex-direction: row;
        gap: 12px;
    }
    
    #employeeView .header-actions-right .btn {
        min-width: auto;
        width: auto;
        height: auto;
        padding: 6px 12px !important;
        font-size: 14px;
    }
    
    #employeeView .header-actions-right #employeeUserInfo {
        display: flex !important;
        margin-right: 12px;
    }
    
    #employeeView .header-actions-right #employeeAdminViewBtn {
        display: flex;
        padding: 6px 12px !important;
    }
    
    #employeeView .header-actions-right #employeeAdminViewBtn::before {
        content: "👑 ";
        margin-right: 4px;
    }
    
    /* Botão Sair no desktop - mostra texto completo */
    #employeeView .header-actions-right #logoutBtnEmployee {
        padding: 6px 12px !important;
        font-size: 14px !important;
        min-width: auto !important;
        width: auto !important;
        height: auto !important;
        color: inherit !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
    
    /* Esconde ícone em desktop, mostra apenas texto "Sair" */
    #employeeView .header-actions-right #logoutBtnEmployee::after {
        display: none;
    }
}

@media (max-width: 768px) {
    /* Visão Colaborador - Correções Gerais */
    #employeeView {
        overflow-x: hidden !important;
        width: 100% !important;
        max-width: 100vw !important;
    }
    
    #employeeView .card {
        overflow-x: hidden !important;
        width: 100% !important;
        max-width: 100vw !important;
        margin: 0;
        border-radius: 0;
        border-left: none;
        border-right: none;
    }
    
    #employeeView .card-body {
        padding: 12px !important;
        overflow-x: hidden !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    #employeeView .card-block {
        padding: 12px !important;
        overflow-x: hidden !important;
        width: 100% !important;
        box-sizing: border-box !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    
    /* Header do colaborador em mobile - Layout Flex Compacto em uma linha */
    #employeeView .company-admin-header {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        padding: 8px 12px !important;
        gap: 8px !important;
        width: 100% !important;
        box-sizing: border-box !important;
        border-bottom: 1px solid rgba(0, 28, 40, 0.1);
        flex-wrap: nowrap !important;
        overflow: hidden !important;
        min-height: 50px;
    }
    
    /* Logo e conteúdo - APENAS PARA TABLET (481px-768px), NÃO para mobile pequeno */
    @media (min-width: 481px) {
        #employeeView .header-logo-left {
            flex: 0 0 40px !important;
            max-width: 40px !important;
            min-width: 40px !important;
            display: flex;
            align-items: center;
            justify-content: center;
            flex-shrink: 0;
        }
        
        #employeeView .header-logo-left .brand-icon-small {
            max-width: 40px !important;
            max-height: 30px !important;
            width: auto;
            height: auto;
            object-fit: contain;
        }
        
        #employeeView .header-content-center {
            flex: 1 1 auto !important;
            min-width: 0 !important;
            padding: 0 6px !important;
            text-align: left !important;
            display: flex;
            flex-direction: column;
            gap: 1px;
            overflow: hidden;
            flex-shrink: 1;
        }
    }
    
    #employeeView .header-content-center h2 {
        font-size: 13px !important;
        font-weight: 600;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        margin: 0 !important;
        text-align: left;
        line-height: 1.2;
        color: var(--color-primary);
    }
    
    #employeeView .header-content-center p,
    #employeeView .header-content-center .header-subtitle {
        font-size: 9px !important;
        margin: 0 !important;
        text-align: left;
        line-height: 1.1;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        color: var(--color-secondary);
    }
    
    
    /* Ações à direita - todos na mesma linha, compactos */
    #employeeView .header-actions-right {
        flex: 0 0 auto !important;
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: flex-end !important;
        gap: 4px !important;
        flex-wrap: nowrap !important;
        flex-shrink: 0 !important;
        min-width: 0 !important;
        margin-left: auto !important;
    }
    
    /* Esconde info do usuário em mobile */
    #employeeView .header-actions-right #employeeUserInfo {
        display: none !important;
    }
    
    /* Botões de ação - ícones pequenos e compactos */
    #employeeView .header-actions-right .btn {
        padding: 4px 6px !important;
        min-width: 28px !important;
        width: auto !important;
        height: 28px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 14px !important;
        border-radius: 4px;
        flex-shrink: 0 !important;
        margin: 0 !important;
    }
    
    #employeeView .header-actions-right .btn-small {
        padding: 4px 6px !important;
        min-width: 28px !important;
        width: auto !important;
        height: 28px !important;
        font-size: 14px !important;
    }
    
    #employeeView .header-actions-right .btn span {
        margin: 0;
        font-size: 14px !important;
        line-height: 1;
    }
    
    /* Botão Admin View - apenas ícone pequeno */
    #employeeView .header-actions-right #employeeAdminViewBtn {
        padding: 4px 6px !important;
        min-width: 28px !important;
        width: 28px !important;
        height: 28px !important;
        font-size: 14px !important;
    }
    
    #employeeView .header-actions-right #employeeAdminViewBtn:not(.hidden) {
        display: flex !important;
    }
    
    /* Botão Sair - texto pequeno, não ícone */
    #employeeView .header-actions-right #logoutBtnEmployee {
        padding: 4px 8px !important;
        min-width: auto !important;
        width: auto !important;
        height: 28px !important;
        font-size: 11px !important;
        white-space: nowrap;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
    
    /* Remove qualquer conteúdo de ícone do botão Sair */
    #employeeView .header-actions-right #logoutBtnEmployee::before,
    #employeeView .header-actions-right #logoutBtnEmployee::after {
        display: none !important;
        content: none !important;
    }
    
    /* Tabela de marcações - APENAS PARA MOBILE PEQUENO (até 480px) - NÃO afeta desktop */
    /* Essas regras serão sobrescritas pela media query de 480px que vem depois */
    
    /* Botões de ação em mobile */
    #employeeView .clock-actions-grid {
        grid-template-columns: 1fr 1fr !important;
        gap: 12px;
    }
    
    #employeeView .clock-actions-grid .btn-large {
        padding: 14px 10px;
        font-size: 13px;
        min-height: 70px;
    }
    
    #employeeView .clock-actions-grid .btn-icon {
        font-size: 24px;
    }
    
    #employeeView .clock-actions-grid .btn-text {
        font-size: 12px;
    }
    
    /* Grid de ações e ferramentas */
    #employeeView .card-block > div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }
    
    /* Formulário de histórico em mobile */
    #employeeHistoryFilter > div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
        gap: 12px;
    }
    
    #employeeHistoryFilter .btn-primary {
        width: 100%;
    }
    
    /* Status do dia em mobile */
    #employeeView .employee-status-container {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 8px;
    }
    
    #employeeView .employee-status-container > div {
        width: 100%;
    }
    
    #employeeNextActionHint {
        width: 100% !important;
        text-align: center;
    }
    
    /* Card block header em mobile */
    #employeeView .card-block__header {
        flex-wrap: wrap;
        gap: 12px;
    }
    
    #employeeView .card-block__header h3 {
        font-size: 14px;
        flex: 1 1 100%;
    }
    
    /* Modal em mobile */
    #employeeView .modal-content {
        margin: 10px;
        max-width: calc(100vw - 20px);
        padding: 20px 16px;
    }
    
    /* Garantir que não há overflow horizontal */
    #employeeView * {
        max-width: 100%;
        box-sizing: border-box;
    }
    
    #employeeView table,
    #employeeView .table {
        width: 100%;
        max-width: 100%;
        table-layout: auto;
    }
    
    /* Métricas em 1 coluna em mobile pequeno */
    #employeeMetrics {
        grid-template-columns: 1fr !important;
    }
    
    /* Link company form inline */
    #linkCompanyFormInline {
        flex-direction: column;
        gap: 12px;
    }
    
    #linkCompanyFormInline input {
        width: 100%;
    }
    
    #linkCompanyFormInline button {
        width: 100%;
    }
}

/* Landscape Mobile */
@media (max-width: 768px) and (orientation: landscape) {
    body {
        padding: 8px 0;
    }
    
    .app-shell {
        padding: 12px;
    }
    
    .card-header {
        padding: 12px 16px;
    }
    
    .card-body {
        padding: 12px 16px;
    }
    
    .modal-content {
        max-height: calc(100vh - 10px);
    }
}

/* Role Badges - Indicadores de Papel do Usuário */
.role-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.role-badge:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.role-badge-employee {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
}

.role-badge-admin {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
}

.role-badge-accountant {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    color: white;
}

.role-badge-master {
    background: linear-gradient(135deg, #e1ac3b, #c99628);
    color: var(--color-primary);
    font-weight: 800;
    box-shadow: 0 2px 12px rgba(225, 172, 59, 0.4);
}

/* Responsividade para badges */
@media (max-width: 768px) {
    .role-badge {
        font-size: 10px;
        padding: 4px 10px;
    }
}

@media (max-width: 480px) {
    .role-badge {
        font-size: 9px;
        padding: 3px 8px;
    }
}

/* Estilos para Edição de Horários */
.time-entry-edit-day {
    background: white;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 16px;
    margin-bottom: 16px;
}

.time-entry-edit-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--color-border);
}

.time-entry-edit-header strong {
    font-size: 16px;
    color: var(--color-primary);
}

.time-entry-edit-fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px;
}

.time-entry-edit-fields .form-group {
    margin: 0;
}

.time-entry-edit-fields .form-group > div {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.time-entry-edit-fields input[type="time"] {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-family: 'Courier New', monospace;
    background: white;
}

.time-entry-edit-fields input[type="time"]:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(0, 28, 40, 0.1);
}

.time-entry-edit-fields input[type="time"]:not(:first-of-type) {
    margin-top: 4px;
}

/* Estilos para botões de ponto desabilitados */
.clock-actions-grid .btn-large:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    filter: grayscale(50%);
}

.clock-actions-grid .btn-large:disabled:hover {
    transform: none;
    box-shadow: none;
}

/* Status indicator */
#employeeStatusIndicator {
    transition: background-color 0.3s ease;
    box-shadow: 0 0 0 2px rgba(0, 28, 40, 0.1);
}

/* Melhor hierarquia visual para métricas */
#employeeMetrics {
    margin-top: 20px;
    margin-bottom: 20px;
}

#employeeMetrics .metric {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

#employeeMetrics .metric:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 28, 40, 0.1);
}

.time-entries-edit-list {
    max-height: 500px;
    overflow-y: auto;
    padding: 8px 0;
}

/* Impressão */
/* Modal de Visualização de Documentos */
#documentViewerModal {
    z-index: 10000;
}

#documentViewerModal .modal-content {
    display: flex;
    flex-direction: column;
    background: var(--color-bg);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-soft);
}

#documentViewerContent {
    min-height: 400px;
}

#documentImageViewer {
    cursor: zoom-in;
    transition: transform 0.2s;
}

#documentImageViewer:hover {
    transform: scale(1.02);
}

#documentPdfViewer {
    background: #525252;
}

#documentViewerDownload {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

#documentDownloadLink {
    text-decoration: none;
}

/* Responsividade para mobile */
@media (max-width: 768px) {
    #documentViewerModal .modal-content {
        max-width: 95vw !important;
        max-height: 95vh !important;
    }

    #documentViewerContent {
        padding: 12px !important;
        max-height: calc(95vh - 60px) !important;
    }

/* Help Modal Styles */
.help-tab-btn {
    padding: 10px 20px;
    border: none;
    background: transparent;
    color: var(--color-secondary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
}

.help-tab-btn:hover {
    color: var(--color-primary);
}

.help-tab-btn.active {
    color: var(--color-primary);
    border-bottom-color: var(--color-primary);
}

.help-content {
    animation: fadeIn 0.3s ease-in;
}

.help-section {
    transition: transform 0.2s, box-shadow 0.2s;
}

.help-section:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 28, 40, 0.1);
}

.faq-item {
    transition: transform 0.2s, box-shadow 0.2s;
}

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

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

/* Help button in headers */
#employeeHelpBtn,
#adminHelpBtn,
#accountantHelpBtn,
#masterHelpBtn {
    transition: transform 0.2s;
}

#employeeHelpBtn:hover,
#adminHelpBtn:hover,
#accountantHelpBtn:hover,
#masterHelpBtn:hover {
    transform: scale(1.1);
}

    #documentImageViewer {
        max-height: 60vh !important;
    }

    #documentViewerPdf {
        height: 60vh !important;
    }
}

@media print {
    @page {
        size: A4;
        margin: 10mm;
    }
    
    .app-header,
    .btn,
    .header-actions,
    .notification-container {
        display: none !important;
    }
    
    #print-area {
        width: 100% !important;
        max-width: 100% !important;
        padding: 15mm !important;
        font-size: 11px !important;
        line-height: 1.3 !important;
        page-break-inside: avoid;
    }
    
    #print-area h2 {
        font-size: 1.3em !important;
        margin: 8px 0 !important;
    }
    
    #print-area h3 {
        font-size: 1.15em !important;
        margin: 12px 0 !important;
    }
    
    #print-area h4 {
        font-size: 1em !important;
        margin: 10px 0 !important;
    }
    
    #print-area table {
        font-size: 10px !important;
        page-break-inside: auto;
    }
    
    #print-area table tr {
        page-break-inside: avoid;
        page-break-after: auto;
    }
    
    #print-area table thead {
        display: table-header-group;
    }
    
    #print-area table tbody {
        display: table-row-group;
    }
    
    #print-area table td,
    #print-area table th {
        padding: 5px !important;
        font-size: 10px !important;
    }
    
    .card {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}

