/**
 * StandupClock Styles
 * Modern, clean UI with large visible timer
 */

:root {
    --primary-color: #2563eb;
    --primary-dark: #1e40af;
    --secondary-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --bg-color: #f9fafb;
    --card-bg: #ffffff;
    --text-primary: #111827;
    --text-secondary: #6b7280;
    --border-color: #e5e7eb;
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
}

.header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
}

.provider-status {
    display: flex;
    gap: 1rem;
}

.status-indicator {
    padding: 0.5rem 1rem;
    background-color: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 0.5rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.status-indicator.connected {
    background-color: var(--secondary-color);
    color: white;
    border-color: var(--secondary-color);
}

/* Connection Section */
.connection-section {
    background: var(--card-bg);
    padding: 3rem;
    border-radius: 1rem;
    box-shadow: var(--shadow-lg);
    text-align: center;
}

.connection-section h2 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.connection-section p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.provider-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn:active {
    transform: translateY(0);
}

.btn-jira {
    background-color: #0052CC;
    color: white;
}

.btn-gitlab {
    background-color: #FC6D26;
    color: white;
}

.btn-timer {
    background-color: var(--primary-color);
    color: white;
}

.btn-nav {
    background-color: var(--card-bg);
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-nav:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-nav:disabled:hover {
    transform: none;
}

.btn-refresh {
    background-color: var(--text-secondary);
    color: white;
}

/* Message */
.message {
    margin-top: 1rem;
    padding: 1rem;
    border-radius: 0.5rem;
    display: none;
}

.message.success {
    background-color: #d1fae5;
    color: #065f46;
    border: 1px solid var(--secondary-color);
}

.message.error {
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid var(--danger-color);
}

/* Timer */
.timer-container {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border-radius: 1rem;
    padding: 3rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-lg);
    text-align: center;
}

.timer-display {
    color: white;
}

.timer-time {
    font-size: 5rem;
    font-weight: 700;
    display: block;
    margin-bottom: 1.5rem;
    font-variant-numeric: tabular-nums;
    transition: color 0.3s;
}

.timer-time.warning {
    color: #fbbf24;
}

.timer-time.critical {
    color: #f87171;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.timer-controls {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Current Member */
.current-member {
    background: var(--card-bg);
    border-radius: 1rem;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
}

.member-info {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.member-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--bg-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    flex-shrink: 0;
}

.member-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.member-details {
    flex: 1;
}

.member-name {
    font-size: 1.75rem;
    margin-bottom: 0.25rem;
}

.member-email {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* Tickets */
.tickets-container {
    background: var(--card-bg);
    border-radius: 1rem;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
}

.tickets-container h3 {
    margin-bottom: 1.5rem;
    font-size: 1.25rem;
}

.tickets-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.ticket-card {
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 1.5rem;
    transition: all 0.2s;
}

.ticket-card:hover {
    box-shadow: var(--shadow);
    transform: translateY(-2px);
}

.ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.ticket-key {
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.9rem;
}

.ticket-key:hover {
    text-decoration: underline;
}

.ticket-status {
    padding: 0.25rem 0.75rem;
    background-color: var(--bg-color);
    border-radius: 0.25rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.ticket-title {
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.ticket-description {
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
    line-height: 1.5;
}

.ticket-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.875rem;
}

.ticket-priority {
    padding: 0.25rem 0.75rem;
    border-radius: 0.25rem;
    font-weight: 500;
}

.ticket-priority.priority-high {
    background-color: #fee2e2;
    color: #991b1b;
}

.ticket-priority.priority-medium {
    background-color: #fef3c7;
    color: #92400e;
}

.ticket-priority.priority-low {
    background-color: #dbeafe;
    color: #1e40af;
}

.ticket-updated {
    color: var(--text-secondary);
}

/* Team Section */
.team-section {
    background: var(--card-bg);
    border-radius: 1rem;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
}

.team-section h3 {
    margin-bottom: 1.5rem;
    font-size: 1.25rem;
}

.team-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.team-member-card {
    border: 2px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.team-member-card:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow);
}

.team-member-card.active {
    border-color: var(--primary-color);
    background-color: #eff6ff;
}

.member-avatar-small {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.member-avatar-small img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.member-info-small {
    flex: 1;
    min-width: 0;
}

.member-name-small {
    font-weight: 500;
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.member-ticket-count {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* Navigation */
.navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--card-bg);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
}

.member-counter {
    font-weight: 600;
    font-size: 1.125rem;
    color: var(--text-primary);
}

/* Refresh Section */
.refresh-section {
    text-align: center;
}

/* Loading and No Data States */
.loading, .no-data {
    text-align: center;
    color: var(--text-secondary);
    padding: 2rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }
    
    .header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .timer-time {
        font-size: 3rem;
    }
    
    .connection-section {
        padding: 2rem 1.5rem;
    }
    
    .provider-buttons {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    .member-info {
        flex-direction: column;
        text-align: center;
    }
    
    .team-list {
        grid-template-columns: 1fr;
    }
    
    .navigation {
        flex-direction: column;
        gap: 1rem;
    }
    
    .timer-controls {
        flex-direction: column;
    }
    
    .timer-controls .btn {
        width: 100%;
    }
}

