.jcarc-nets {
    --jcarc-nets-primary: var(--jcarc-primary, #2f4778);
    --jcarc-nets-primary-dark: var(--jcarc-primary-dark, #203455);
    --jcarc-nets-border: #d8dde3;
    --jcarc-nets-ink: #20252b;
    color: var(--jcarc-nets-ink);
    font-size: 1.0625rem;
    line-height: 1.5;
    margin: 0;
    padding: 0;
}

.jcarc-nets *,
.jcarc-nets *::before,
.jcarc-nets *::after {
    box-sizing: border-box;
}

.jcarc-net-schedule-wrap {
    border: 1px solid var(--jcarc-nets-border);
    border-radius: 0.5rem;
    overflow: hidden;
}

.jcarc-net-schedule {
    border: 0;
    border-collapse: collapse;
    margin: 0;
    table-layout: fixed;
    width: 100%;
}

.jcarc-net-schedule th,
.jcarc-net-schedule td {
    border: 0;
    border-bottom: 1px solid var(--jcarc-nets-border);
    font-size: 1rem;
    line-height: 1.5;
    padding: 0.85rem 1rem;
    text-align: left;
    vertical-align: top;
}

.jcarc-net-schedule thead th {
    background: var(--jcarc-nets-primary);
    color: #fff;
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.jcarc-net-schedule thead th:nth-child(1) {
    width: 18%;
}

.jcarc-net-schedule thead th:nth-child(2) {
    width: 18%;
}

.jcarc-net-schedule thead th:nth-child(3) {
    width: 34%;
}

.jcarc-net-schedule thead th:nth-child(4) {
    width: 30%;
}

.jcarc-net-schedule tbody th {
    color: var(--jcarc-nets-primary-dark);
    font-weight: 700;
}

.jcarc-net-schedule tbody tr:nth-child(odd) > * {
    background: #f5f7f9;
}

.jcarc-net-schedule tbody tr.is-today > * {
    background: #edf7ef;
}

.jcarc-net-schedule tbody tr:last-child > * {
    border-bottom: 0;
}

.jcarc-net-schedule-today {
    background: #dff2e3;
    border-radius: 999px;
    color: #24693a;
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    margin-left: 0.45rem;
    padding: 0.15rem 0.45rem;
    text-transform: uppercase;
    vertical-align: 0.1em;
}

.jcarc-nets-error {
    border-left: 0.25rem solid #b42318;
    padding-left: 0.75rem;
}

.jcarc-net-calendar {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    margin: 0;
    padding: 0;
}

.jcarc-net-calendar-day {
    background: #fff;
    border: 1px solid var(--jcarc-nets-border);
    border-radius: 0.5rem;
    min-width: 0;
    overflow: hidden;
}

.jcarc-net-calendar-day.is-today {
    border-top: 0.3rem solid var(--jcarc-nets-primary);
}

.jcarc-net-calendar-date {
    background: #e9eef6;
    color: var(--jcarc-nets-primary-dark);
    display: grid;
    gap: 0.1rem;
    padding: 0.7rem 0.75rem;
}

.jcarc-net-calendar-weekday {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.jcarc-net-calendar-today {
    color: #24693a;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
}

.jcarc-net-calendar-events {
    padding: 0.7rem 0.75rem;
}

.jcarc-net-calendar-event + .jcarc-net-calendar-event {
    border-top: 1px solid var(--jcarc-nets-border);
    margin-top: 0.75rem;
    padding-top: 0.75rem;
}

.jcarc-net-calendar-event h3 {
    color: var(--jcarc-nets-primary-dark);
    font-size: 0.95rem;
    line-height: 1.35;
    margin: 0 0 0.35rem;
}

.jcarc-net-calendar-event p,
.jcarc-net-calendar-empty {
    font-size: 0.88rem;
    line-height: 1.4;
    margin: 0;
}

.jcarc-net-calendar-frequency {
    color: #5b6570;
    margin-top: 0.25rem !important;
}

.jcarc-net-calendar-empty {
    color: #5b6570;
}

@media (max-width: 1000px) {
    .jcarc-net-calendar {
        grid-auto-columns: minmax(10.5rem, 42%);
        grid-auto-flow: column;
        grid-template-columns: none;
        overflow-x: auto;
        overscroll-behavior-inline: contain;
        padding-bottom: 0.5rem;
        scroll-snap-type: inline proximity;
    }

    .jcarc-net-calendar-day {
        scroll-snap-align: start;
    }
}

@media (max-width: 700px) {
    .jcarc-net-schedule,
    .jcarc-net-schedule tbody {
        display: block;
        width: 100%;
    }

    .jcarc-net-schedule-wrap {
        border: 0;
        border-radius: 0;
        overflow: visible;
    }

    .jcarc-net-schedule {
        table-layout: auto;
    }

    .jcarc-net-schedule thead {
        border: 0;
        clip: rect(0 0 0 0);
        clip-path: inset(50%);
        height: 1px;
        margin: -1px;
        overflow: hidden;
        padding: 0;
        position: absolute;
        white-space: nowrap;
        width: 1px;
    }

    .jcarc-net-schedule tbody {
        display: grid;
        gap: 0.8rem;
    }

    .jcarc-net-schedule tr {
        background: #f5f7f9;
        border: 1px solid var(--jcarc-nets-border);
        border-left: 0.25rem solid var(--jcarc-nets-primary);
        border-radius: 0.4rem;
        display: grid;
        gap: 0.25rem 0.35rem;
        grid-template-columns: auto 1fr;
        padding: 0.9rem 1rem;
        width: 100%;
    }

    .jcarc-net-schedule tr.is-today {
        background: #edf7ef;
        border-left-color: #24693a;
    }

    .jcarc-net-schedule th,
    .jcarc-net-schedule td {
        background: transparent !important;
        border: 0;
        display: block;
        font-size: 1rem;
        padding: 0;
        width: auto;
    }

    .jcarc-net-schedule th::before,
    .jcarc-net-schedule td::before {
        content: none;
    }

    .jcarc-net-schedule th {
        font-size: 1.08rem;
        grid-column: 1 / -1;
        order: 1;
    }

    .jcarc-net-schedule td:nth-child(1) {
        color: #3f4852;
        font-weight: 600;
        order: 2;
    }

    .jcarc-net-schedule td:nth-child(1)::after {
        content: "·";
        margin-left: 0.35rem;
    }

    .jcarc-net-schedule td:nth-child(2) {
        color: #3f4852;
        order: 3;
    }

    .jcarc-net-schedule td:nth-child(4) {
        color: #5b6570;
        grid-column: 1 / -1;
        margin-top: 0.2rem;
        order: 4;
    }

    .jcarc-net-schedule-today {
        float: right;
        margin-left: 0.75rem;
    }
}
