/* ===== BUTTONS ===== */
.pwa-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    min-height: 40px;
    text-decoration: none;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.pwa-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.pwa-btn:active {
    transform: translateY(0);
}

.pwa-btn-primary {
    background: #22c55e;
    color: white;
}

.pwa-btn-primary:hover {
    background: #16a34a;
}

.pwa-btn-secondary {
    background: #6b7280;
    color: white;
}

.pwa-btn-secondary:hover {
    background: #4b5563;
}

.pwa-btn-success {
    background: #10b981;
    color: white;
}

.pwa-btn-success:hover {
    background: #059669;
}

.pwa-btn-danger {
    background: #ef4444;
    color: white;
}

.pwa-btn-danger:hover {
    background: #dc2626;
}

.pwa-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.pwa-btn-full {
    width: 100%;
}

.pwa-btn-sm {
    padding: 6px 12px;
    font-size: 12px;
    min-height: 32px;
}

.pwa-btn-close {
    background: transparent;
    border: none;
    color: #666;
    cursor: pointer;
    padding: 8px;
    font-size: 20px;
    transition: color 0.2s ease;
}

.pwa-btn-close:hover {
    color: #fff;
}

/* ===== FORMS ===== */
.pwa-form-group {
    margin-bottom: 16px;
}

.pwa-form-label {
    display: block;
    color: #ccc;
    margin-bottom: 6px;
    font-weight: 500;
    font-size: 13px;
}

.pwa-form-control {
    width: 100%;
    padding: 10px 12px;
    background: #2a2a2a;
    border: 1px solid #444;
    border-radius: 6px;
    color: #ffffff;
    font-size: 14px;
    transition: all 0.2s ease;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.pwa-form-control:focus {
    outline: none;
    border-color: #22c55e;
    background: #333;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1);
}

.pwa-form-control::placeholder {
    color: #666;
}

textarea.pwa-form-control {
    resize: vertical;
    min-height: 80px;
}

select.pwa-form-control {
    cursor: pointer;
}

/* ===== CHECKBOXES ===== */
.pwa-checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
    margin-bottom: 12px;
}

.pwa-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    cursor: pointer;
}

.pwa-checkbox label {
    color: #ccc;
    font-size: 14px;
    cursor: pointer;
}

/* ===== MESSAGES ===== */
.pwa-message {
    position: fixed;
    top: 70px;
    left: 50%;
    transform: translateX(-50%);
    padding: 12px 20px;
    border-radius: 8px;
    font-weight: 500;
    z-index: 10002;
    animation: slideDown 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    text-align: center;
    min-width: 200px;
    font-size: 14px;
}

@keyframes slideDown {
    from {
        transform: translateX(-50%) translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
    }
}

.pwa-message.success {
    background: #10b981;
    color: white;
}

.pwa-message.error {
    background: #ef4444;
    color: white;
}

.pwa-message.warning {
    background: #f59e0b;
    color: white;
}

.pwa-message.info {
    background: #3b82f6;
    color: white;
}

/* ===== BADGES ===== */
.pwa-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.pwa-badge-required {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.pwa-badge-success {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
}

/* ===== ICONS WITH TEXT ===== */
.pwa-icon-text {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pwa-icon-text i {
    width: 16px;
    text-align: center;
}

/* ===== SECTION HEADERS ===== */
.pwa-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.pwa-section-title {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.pwa-section-title i {
    color: #22c55e;
}

/* ===== CARDS ===== */
.pwa-card {
    background: #1e1e1e;
    border: 1px solid #333;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
}

.pwa-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid #333;
}

.pwa-card-title {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
}

.pwa-card-body {
    color: #ccc;
    font-size: 14px;
}

/* ===== LIST ITEMS ===== */
.pwa-list-item {
    display: flex;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #333;
}

.pwa-list-item:last-child {
    border-bottom: none;
}

.pwa-list-item-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: rgba(34, 197, 94, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
}

.pwa-list-item-icon i {
    color: #22c55e;
}

.pwa-list-item-content {
    flex: 1;
}

.pwa-list-item-title {
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 2px;
}

.pwa-list-item-subtitle {
    color: #999;
    font-size: 12px;
}

.pwa-list-item-action {
    color: #666;
}

/* ===== UTILITY CLASSES ===== */
.pwa-text-center {
    text-align: center;
}

.pwa-text-success {
    color: #22c55e;
}

.pwa-text-error {
    color: #ef4444;
}

.pwa-text-warning {
    color: #f59e0b;
}

.pwa-text-muted {
    color: #999;
}

.pwa-mt-8 {
    margin-top: 8px;
}

.pwa-mt-16 {
    margin-top: 16px;
}

.pwa-mb-8 {
    margin-bottom: 8px;
}

.pwa-mb-16 {
    margin-bottom: 16px;
}

.pwa-p-16 {
    padding: 16px;
}

.pwa-hidden {
    display: none !important;
}


/* Add these styles to your pwa_components.css file */

/* ===== TIMESHEETS TAB STYLES ===== */
.pwa-timesheets-container {
    padding: 0;
}

.pwa-timesheet-group {
    margin-bottom: 20px;
}

.pwa-timesheet-date {
    background: #1e1e1e;
    color: #22c55e;
    padding: 10px 14px;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    border-radius: 8px 8px 0 0;
    border: 1px solid #333;
    border-bottom: none;
}

.pwa-timesheet-entry {
    background: #1a1a1a;
    border: 1px solid #333;
    border-top: none;
    padding: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pwa-timesheet-entry:hover {
    background: #222;
    border-color: #22c55e;
}

.pwa-timesheet-entry:last-child {
    border-radius: 0 0 8px 8px;
}

.pwa-timesheet-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.pwa-timesheet-job {
    color: #fff;
    font-weight: 600;
    font-size: 14px;
}

.pwa-timesheet-hours {
    background: #22c55e;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.pwa-timesheet-details {
    display: flex;
    gap: 16px;
    color: #999;
    font-size: 12px;
}

.pwa-timesheet-time,
.pwa-timesheet-km {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pwa-timesheet-description {
    margin-top: 8px;
    color: #ccc;
    font-size: 13px;
    line-height: 1.4;
}

/* ===== PROFILE TAB STYLES ===== */
.pwa-profile-container {
    padding: 0;
}

.pwa-profile-card {
    background: #1e1e1e;
    border: 1px solid #333;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
}

.pwa-profile-header-section {
    display: flex;
    align-items: center;
    gap: 20px;
}

.pwa-profile-avatar-large {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #22c55e, #16a34a);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.pwa-profile-avatar-large i {
    font-size: 36px;
    color: white;
}

.pwa-profile-user-info {
    flex: 1;
}

.pwa-profile-user-info h2 {
    color: #fff;
    font-size: 20px;
    font-weight: 600;
    margin: 0 0 4px 0;
}

.pwa-profile-role {
    color: #22c55e;
    font-size: 14px;
    margin-bottom: 8px;
}

.pwa-profile-contact {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 12px;
    color: #999;
}

.pwa-profile-contact span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pwa-profile-contact i {
    width: 14px;
    color: #666;
}

/* Statistics Grid */
.pwa-stats-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.pwa-stat-card {
    background: #1e1e1e;
    border: 1px solid #333;
    border-radius: 8px;
    padding: 16px;
    text-align: center;
    transition: all 0.2s ease;
}

.pwa-stat-card:hover {
    border-color: #22c55e;
    transform: translateY(-2px);
}

.pwa-stat-number {
    font-size: 24px;
    font-weight: 700;
    color: #22c55e;
    margin-bottom: 4px;
}

.pwa-stat-label {
    font-size: 11px;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Settings Section */
.pwa-settings-card {
    background: #1e1e1e;
    border: 1px solid #333;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
}

.pwa-section-title {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.pwa-section-title i {
    color: #22c55e;
}

.pwa-setting-button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 12px;
    background: transparent;
    border: none;
    border-bottom: 1px solid #2a2a2a;
    color: #ccc;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pwa-setting-button:last-child {
    border-bottom: none;
}

.pwa-setting-button:hover {
    background: rgba(34, 197, 94, 0.05);
    color: #fff;
}

.pwa-setting-button i:first-child {
    width: 20px;
    color: #666;
}

.pwa-setting-button i:last-child {
    color: #666;
    font-size: 12px;
}

/* About Modal */
.pwa-about-modal .pwa-about-content {
    text-align: center;
}

.pwa-about-logo {
    font-size: 48px;
    color: #22c55e;
    margin-bottom: 16px;
}

.pwa-about-modal h2 {
    color: #fff;
    font-size: 20px;
    margin-bottom: 8px;
}

.pwa-about-version {
    color: #999;
    font-size: 14px;
    margin-bottom: 24px;
}

.pwa-about-features {
    text-align: left;
    margin-bottom: 24px;
}

.pwa-about-features h4 {
    color: #22c55e;
    font-size: 14px;
    margin-bottom: 12px;
}

.pwa-about-features ul {
    list-style: none;
    padding: 0;
}

.pwa-about-features li {
    color: #ccc;
    font-size: 13px;
    padding: 6px 0;
    padding-left: 20px;
    position: relative;
}

.pwa-about-features li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #22c55e;
}

.pwa-about-support {
    text-align: center;
    margin-bottom: 24px;
}

.pwa-about-support h4 {
    color: #22c55e;
    font-size: 14px;
    margin-bottom: 8px;
}

.pwa-about-support p {
    color: #999;
    font-size: 13px;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .pwa-stats-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .pwa-stat-card {
        padding: 12px;
    }

    .pwa-stat-number {
        font-size: 20px;
    }

    .pwa-profile-header-section {
        flex-direction: column;
        text-align: center;
    }

    .pwa-profile-avatar-large {
        margin: 0 auto;
    }
}

/* Product search results dropdown */
#product-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 0 0 8px 8px;
    max-height: 200px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
    margin-top: -1px;
}

.product-result {
    padding: 10px;
    cursor: pointer;
    border-bottom: 1px solid #2a2a2a;
    transition: background 0.2s ease;
}

.product-result:hover {
    background: #2a2a2a;
}

.product-result:last-child {
    border-bottom: none;
}

.product-name {
    color: #fff;
    font-size: 14px;
    font-weight: 500;
}

.product-info {
    color: #999;
    font-size: 12px;
    margin-top: 2px;
}

.no-results {
    padding: 10px;
    text-align: center;
    color: #999;
    font-size: 13px;
}

/* Form group positioning for dropdown */
.pwa-form-group {
    position: relative;
}