:root { 
    --primary: #007bff; 
    --bg: #f0f2f5; 
    --text: #1c1e21; 
    --note-bg: #fff9c4; 
    --note-border: #fbc02d; 
}

body { 
    font-family: -apple-system, sans-serif; 
    margin: 0; 
    padding: 0; 
    background: var(--bg); 
    color: var(--text); 
}

.header { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    padding: 15px 20px; 
    background: #fff; 
    border-bottom: 1px solid #ddd; 
    position: sticky; 
    top: 0; 
    z-index: 100; 
}

.header h1 { margin: 0; font-size: 1.2rem; }
.header a { text-decoration: none; color: #65676b; font-weight: bold; font-size: 0.9rem; }

.container { padding: 15px; max-width: 500px; margin: 0 auto; box-sizing: border-box; }

.card { 
    background: #fff; 
    padding: 20px; 
    border-radius: 16px; 
    box-shadow: 0 4px 12px rgba(0,0,0,0.08); 
    margin-bottom: 20px; 
    box-sizing: border-box;
    width: 100%;
}

.resume-card { border: 2px dashed var(--primary); background: #f0f7ff; }
.stack-label { color: #65676b; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1px; font-weight: 700; }
.task-name { margin: 8px 0; font-size: 1.5rem; line-height: 1.2; }

.task-note-box { 
    background: var(--note-bg); 
    border-left: 4px solid var(--note-border); 
    padding: 12px; 
    margin: 15px 0; 
    border-radius: 6px; 
    font-size: 0.95rem; 
    color: #444; 
}

.photo-gallery { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.mini-photo { width: 60px; height: 60px; object-fit: cover; border-radius: 6px; cursor: pointer; border: 1px solid rgba(0,0,0,0.1); }
.mini-photo.enlarged { width: 100%; height: auto; max-height: 400px; object-fit: contain; z-index: 10; }

.checklist-container { background: #ffffff; border: 1px solid #e4e6eb; border-radius: 10px; padding: 12px; margin: 15px 0; }
.checklist-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid #f0f2f5; font-size: 0.95rem; }
.checklist-row:last-child { border-bottom: none; }
.checklist-row input[type="checkbox"] { width: 18px; height: 18px; cursor: pointer; }
.checklist-row label { cursor: pointer; flex: 1; }

.timer-container { text-align: center; margin: 20px 0; }
.timer-text { font-size: 4rem; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -2px; }
.timer-target { font-size: 0.9rem; color: #65676b; font-weight: 600; margin-bottom: 5px; }

/* Update existing progress container to allow relative positioning */
.progress-container { 
    background: #e4e6eb; 
    height: 16px; 
    border-radius: 8px; 
    overflow: visible; /* Changed from hidden to show the tick label if needed */
    margin: 10px 0; 
    position: relative; /* Essential for the tick placement */
}

/* New style for the Tick/Goal Marker */
.progress-tick {
    position: absolute;
    top: -2px;
    bottom: -2px;
    width: 4px;
    border-radius: 2px;
    z-index: 5;
    transition: left 0.3s ease;
}

.tick-goal { background: #dc3545; }   /* Red for Goal */
.tick-avg { background: #2ecc71; }    /* Green for Average */

/* Ensure the fill stays inside the rounded corners */
.progress-fill { 
    height: 100%; 
    transition: width 1s linear; 
    width: 0%; 
    border-radius: 8px;
}

.bg-green { background: #2ecc71; }
.bg-yellow { background: #f1c40f; }
.bg-neutral { background: #bdc3c7; }

.upcoming { margin-top: 25px; padding-top: 20px; border-top: 1px solid #eee; }
.upcoming-item { display: flex; justify-content: space-between; align-items: center; font-size: 0.9rem; margin-bottom: 12px; }
.end-time-row { margin-top: 15px; padding-top: 12px; border-top: 2px dashed #eee; color: #dc3545; font-weight: bold; }

.badge { font-size: 0.65rem; padding: 3px 6px; border-radius: 4px; color: white; text-transform: uppercase; font-weight: bold; margin-right: 6px; }
.badge-task { background: #007bff; }
.badge-milestone { background: #6f42c1; }

.eta-label { font-weight: 700; color: #2ecc71; font-variant-numeric: tabular-nums; }
.eta-label.final-end { color: #dc3545; }

.btn-group { display: flex; gap: 12px; margin-top: 20px; }
.btn { flex: 1; padding: 18px; border: none; border-radius: 12px; font-weight: bold; font-size: 1rem; cursor: pointer; text-align: center; text-decoration: none; }
.btn-finish { background: var(--primary); color: white; box-shadow: 0 4px 0 #0056b3; }
.btn-stop { background: #f0f2f5; color: #4b4f56; }

.skip-container { 
    margin-top: 12px; 
    display: flex; 
    gap: 4px; 
    background: #f8f9fa; 
    padding: 6px; 
    border-radius: 10px; 
    align-items: center; 
    box-sizing: border-box;
    width: 100%;
}
.skip-select { 
    flex: 1; 
    min-width: 0; 
    padding: 8px 4px; 
    border-radius: 6px; 
    border: 1px solid #ddd; 
    font-size: 0.8rem; 
    background: #fff; 
}
.btn-skip, .btn-jump { 
    flex: 0 0 auto; 
    padding: 8px 10px; 
    color: white; 
    border-radius: 6px; 
    border: none; 
    font-weight: bold; 
    font-size: 0.75rem; 
    cursor: pointer; 
    white-space: nowrap; 
}
.btn-skip { background: #6c757d; }
.btn-jump { background: #17a2b8; }

.btn-pause-icon { background: none; border: none; font-size: 1.4rem; cursor: pointer; padding: 0; display: flex; align-items: center; }