/* Dashboard Layout */
.dashboard-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.dashboard-header h1 {
    margin: 0;
    font-size: 2rem;
    color: #1a202c;
}

.today-summary {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.today-summary span {
    color: #718096;
}

.today-summary strong {
    color: #2d3748;
    font-size: 1.2rem;
}

/* Quick Actions */
.quick-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.quick-actions button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Dashboard Sections */
.dashboard-section {
    margin-bottom: 3rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.section-header h2 {
    margin: 0;
    font-size: 1.5rem;
    color: #2d3748;
}

/* Project Grid */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    max-height: 70vh;
    overflow-y: auto;
    padding: 0.5rem;
}

/* Add scrollbar styling */
.project-grid::-webkit-scrollbar {
    width: 8px;
}

.project-grid::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.project-grid::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.project-grid::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.project-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1.5rem;
    transition: all 0.2s;
    position: relative;
}

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

/* Pinned Projects Grid */
.pinned-projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 0.5rem;
    margin-bottom: 1rem;
}

/* Pinned Project Cards */
.pinned-project-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    position: relative;
}

.pinned-project-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    border-color: #cbd5e1;
}

.pinned-project-content {
    padding: 1.25rem;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.pinned-project-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.pinned-project-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.125rem;
    box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
}

.pinned-project-unpin {
    background: transparent;
    border: none;
    color: #94a3b8;
    padding: 0.25rem;
    cursor: pointer;
    transition: all 0.2s;
    border-radius: 6px;
    opacity: 0;
    transition: opacity 0.2s;
}

.pinned-project-card:hover .pinned-project-unpin {
    opacity: 1;
}

.pinned-project-unpin:hover {
    background: #fee2e2;
    color: #ef4444;
}

.pinned-project-info {
    flex: 1;
    margin-bottom: 1rem;
}

.pinned-project-client {
    color: #64748b;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.pinned-project-name {
    color: #1e293b;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.pinned-project-footer {
    margin-top: auto;
}

.pinned-project-btn {
    width: 100%;
    padding: 0.625rem 1rem;
    border: none;
    border-radius: 10px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.pinned-project-btn.start {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
}

.pinned-project-btn.start:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    transform: translateY(-1px);
    box-shadow: 0 6px 8px -1px rgba(59, 130, 246, 0.4);
}

.pinned-project-btn.active {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    cursor: not-allowed;
    opacity: 0.9;
}

.pinned-project-btn .active-indicator {
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

/* New Compact Pinned Project Cards */
.pinned-project-card-compact {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.5rem 0.625rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.15s;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.pinned-project-card-compact:hover {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
    border-color: #cbd5e1;
}

.pinned-project-info-compact {
    flex: 1;
    min-width: 0;
    padding-right: 0.5rem;
}

.pinned-project-client-compact {
    color: #94a3b8;
    font-size: 0.625rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 0;
    line-height: 1.2;
}

.pinned-project-name-compact {
    color: #1e293b;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}

.pinned-project-actions-compact {
    display: flex;
    gap: 0.25rem;
    align-items: center;
}

.pinned-btn-start {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
}

.pinned-btn-start:hover {
    background: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 1px 3px rgba(59, 130, 246, 0.3);
}

.pinned-btn-active {
    background: #10b981;
    color: white;
    border: none;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 600;
    cursor: not-allowed;
    opacity: 0.9;
}

.pinned-btn-unpin {
    background: transparent;
    border: none;
    color: #cbd5e1;
    font-size: 1rem;
    line-height: 1;
    width: 18px;
    height: 18px;
    padding: 0;
    cursor: pointer;
    transition: all 0.15s;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
}

.pinned-project-card-compact:hover .pinned-btn-unpin {
    opacity: 1;
}

.pinned-btn-unpin:hover {
    background: #fee2e2;
    color: #ef4444;
}

/* Compact project cards container - keeping for backward compatibility */
.project-grid-compact {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 0.75rem;
    margin-bottom: 1rem;
}

/* Compact project cards - keeping for backward compatibility */
.project-card-compact {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.project-card-compact:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

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

.project-compact-client {
    color: #94a3b8;
    font-size: 0.7rem;
    font-weight: 600;
    margin-bottom: 0.125rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.project-compact-name {
    color: #1e293b;
    font-size: 0.875rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 140px;
}

.project-compact-actions {
    display: flex;
    gap: 0.375rem;
    align-items: center;
}

.project-compact-actions .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
}

.btn-unpin {
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 1.25rem;
    line-height: 1;
    padding: 0.25rem;
    cursor: pointer;
    transition: color 0.2s;
}

.btn-unpin:hover {
    color: #ef4444;
}

/* Timer cards grid */
.timers-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

/* Compact timer cards */
.timer-card-compact {
    background: white;
    border: 2px solid #10b981;
    border-radius: 8px;
    padding: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    flex: 1 1 300px;
    min-width: 280px;
    max-width: 400px;
}

.timer-card-compact.paused {
    border-color: #f59e0b;
    background: #fffbeb;
}

.timer-compact-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.timer-compact-info {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.timer-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10b981;
    animation: pulse 2s infinite;
}

.timer-indicator.paused {
    background: #f59e0b;
    animation: none;
}

.timer-client {
    color: #94a3b8;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.timer-project {
    color: #1e293b;
    font-size: 0.875rem;
    font-weight: 600;
}

.timer-time-display {
    font-family: monospace;
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    background: #f1f5f9;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.timer-compact-notes {
    margin-bottom: 0.5rem;
}

.timer-notes-input {
    width: 100%;
    padding: 0.375rem 0.5rem;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    font-size: 0.8rem;
    background: white;
}

.timer-compact-controls {
    display: flex;
    gap: 0.375rem;
}

.btn-xs {
    padding: 0.25rem 0.5rem;
    font-size: 0.7rem;
    border-radius: 4px;
}

.project-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 0.5rem;
}

.project-header h3 {
    margin: 0;
    font-size: 1.1rem;
    color: #2d3748;
    font-weight: 600;
}

.btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    opacity: 0.6;
    transition: opacity 0.2s;
}

.btn-icon:hover {
    opacity: 1;
}

.project-client {
    color: #718096;
    font-size: 0.8rem;
    margin: 0 0 0.25rem 0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.project-stats {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: #718096;
    margin-bottom: 1rem;
}

/* Timer Display */
.project-timer {
    margin-top: 1rem;
}

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

.timer-time {
    font-size: 1.5rem;
    font-weight: bold;
    font-family: 'Monaco', 'Consolas', monospace;
    color: #dc2626;
    margin-bottom: 0.5rem;
}

.timer-notes {
    margin-bottom: 0.5rem;
}

.timer-notes-input {
    width: 100%;
    padding: 0.25rem 0.5rem;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    font-size: 0.85rem;
    text-align: center;
    background: #f8fafc;
    transition: all 0.2s;
}

.timer-notes-input:focus {
    outline: none;
    border-color: #3b82f6;
    background: white;
}

.timer-notes-input-inline {
    width: 100%;
    padding: 0.25rem 0.5rem;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    font-size: 0.85rem;
    margin: 0.25rem 0;
    background: white;
    transition: all 0.2s;
}

.timer-notes-input-inline:focus {
    outline: none;
    border-color: #3b82f6;
}

/* Active Timers Section */
.timers-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.active-timer-card {
    border-radius: 8px;
    padding: 1rem;
    display: flex;
    gap: 1rem;
    align-items: center;
    position: relative;
    transition: all 0.2s;
}

.timer-running {
    background: #f0fdf4;
    border: 2px solid #86efac;
}

.timer-paused {
    background: #fef3c7;
    border: 2px solid #fde68a;
}

.timer-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
}

.indicator-running {
    background: #10b981;
    animation: pulse 2s ease-in-out infinite;
}

.indicator-paused {
    background: #f59e0b;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}

.timer-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.timer-project-info {
    display: flex;
    flex-direction: column;
}

.timer-client {
    font-size: 0.75rem;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.timer-info h4 {
    margin: 0;
    color: #1f2937;
    font-size: 1rem;
}

.timer-time-display {
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 1.25rem;
    font-weight: bold;
    color: #059669;
}

.timer-controls {
    display: flex;
    gap: 0.5rem;
}

.timer-controls button {
    width: 36px;
    height: 36px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

/* Support for new timer structure */
.timer-bottom-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.timer-badge {
    background: #10b981;
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    font-size: 0.875rem;
    text-align: center;
}

.timer-badge-small {
    background: #10b981;
    color: white;
    padding: 0.125rem 0.5rem;
    border-radius: 3px;
    font-size: 0.75rem;
}

.has-timer {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Today's Entries */
.entries-list {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
}

.today-project {
    border-bottom: 1px solid #e2e8f0;
}

.today-project:last-child {
    border-bottom: none;
}

.project-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: #f7fafc;
}

.project-summary h4 {
    margin: 0;
    font-size: 1rem;
    color: #2d3748;
}

.client-name {
    font-size: 0.85rem;
    color: #718096;
}

.project-total {
    font-weight: bold;
    color: #4a5568;
}

.project-entries {
    padding: 0.5rem 1.5rem 1rem;
}

.entry-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.5rem 0;
    font-size: 0.9rem;
}

.entry-time {
    font-weight: 500;
    color: #4a5568;
    min-width: 3rem;
}

.entry-desc {
    flex: 1;
    color: #718096;
}

/* Empty States */
.empty-state {
    text-align: center;
    padding: 3rem;
    color: #718096;
}

.loading-spinner {
    text-align: center;
    padding: 2rem;
    color: #718096;
}

/* Button Variants */
.btn-ghost {
    background: transparent;
    border: none;
    color: #4a5568;
    padding: 0.5rem 1rem;
}

.btn-ghost:hover {
    background: #f7fafc;
}

.btn-block {
    width: 100%;
}

.btn svg {
    width: 16px;
    height: 16px;
}

/* Team Grid */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
}

/* Project Selector */
.project-select-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid #e2e8f0;
    cursor: pointer;
    transition: background-color 0.2s;
}

.project-select-item:hover {
    background-color: #f7fafc;
}

.project-select-item h4 {
    margin: 0 0 0.25rem 0;
    font-size: 1rem;
    color: #2d3748;
}

.project-select-item p {
    margin: 0;
    font-size: 0.875rem;
    color: #718096;
}

.text-muted {
    color: #718096;
}

/* Responsive */
@media (max-width: 768px) {
    .dashboard-container {
        padding: 1rem;
    }
    
    .dashboard-header {
        flex-direction: column;
        align-items: start;
        gap: 1rem;
    }
    
    .project-grid {
        grid-template-columns: 1fr;
    }
    
    .quick-actions {
        flex-direction: column;
    }
    
    .quick-actions button {
        width: 100%;
    }
}