/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* MAIN CONTAINER */
.gantt-chart {
    display: flex;
    flex-direction: column;
    width: 100%;
    border: 1px solid #ccc;
    border-radius: 4px;

    /* Prevent ANY horizontal overflow */
    overflow-x: hidden;
    overflow-y: hidden;

    /* Remove any accidental spacing */
    padding: 0;
    margin: 0;
}

/* HEADER */
.header {
    display: flex;
    flex-wrap: nowrap;
    width: 100%;
}

/* ROWS CONTAINER */
.rows-container {
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* ROWS */
.row {
    display: flex;
    flex-wrap: nowrap;
    width: 100%;
    position: relative;
}

/* HEADER CELLS + TASK CELLS */
.day-of-week,
.task {
    flex: 1 1 0;          /* equal columns, shrink allowed */
    min-width: 0;         /* prevents overflow */
    text-align: center;
    font-weight: bold;
    position: relative;

    /* Remove any default spacing */
    padding: 0;
    margin: 0;
}

/* ALTERNATING COLUMN COLORS */
.day-of-week:nth-child(odd),
.task:nth-child(odd) {
    background-color: #ffffff;
}

.day-of-week:nth-child(even),
.task:nth-child(even) {
    background-color: #f7f9fc;
}

/* TASK CELLS */
.task {
    height: 40px;
    border-bottom: 1px solid #ddd;
}

/* HEADER LABELS */
.day-label {
    display: flex;
    flex-direction: column;
}

.weekday {
    font-weight: bold;
    font-size: 12px;
    color: #555;
}

.daynum {
    font-size: 0.85rem;
    margin-top: 2px;
}

/* WEEKDAY PILL */
.weekday-pill {
    display: inline-block;
    padding: 4px 10px;
    background-color: #fafafa;
    border: 1px solid #ddd;
    font-size: 12px;
    font-weight: 600;
    color: #555;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    user-select: none;
    text-align: center;
    white-space: nowrap;
}

/* EVENT BARS */
.event-bar-wk {
    position: absolute;
    top: 15%;
    height: 70%;
    background-color: #c79b21;
    border-radius: 4px;
    color: white;
    font-size: 12px;
    padding-left: 4px;
    display: flex;
    align-items: center;
}

/* MOBILE: condensed but same grid */
@media (max-width: 768px) {
    .task {
        height: 32px;
    }
    .weekday,
    .weekday-pill,
    .event-bar-wk {
        font-size: 11px;
    }
}

@media (max-width: 480px) {
    .task {
        height: 28px;
    }
    .weekday,
    .weekday-pill,
    .event-bar-wk {
        font-size: 10px;
    }
}
