.om-hours,
.om-status-card,
.om-compact-card {
    --om-border: #e4e7ec;
    --om-border-soft: #eef1f4;
    --om-text: #101828;
    --om-muted: #667085;
    --om-soft: #f8fafc;
    --om-accent: #175cd3;
    --om-open: #067647;
    --om-open-bg: #ecfdf3;
    --om-closed: #b42318;
    --om-closed-bg: #fef3f2;
    --om-warning-bg: #fffaeb;
    --om-warning-border: #fedf89;
    font-family: inherit;
    color: var(--om-text);
    box-sizing: border-box;
}

.om-hours *,
.om-status-card *,
.om-compact-card * {
    box-sizing: border-box;
}

.om-hours.om-card {
    width: 100%;
    max-width: 860px;
    margin: 0;
    overflow: hidden;
    border: 1px solid var(--om-border);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(16, 24, 40, .07);
}

.om-hours .om-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 24px 28px;
    border-bottom: 1px solid var(--om-border);
    background: #fff;
}

.om-hours .om-card-title {
    min-width: 0;
}

.om-hours .om-card-head h2 {
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    color: var(--om-text);
    font-size: clamp(24px, 3vw, 30px);
    font-weight: 500;
    line-height: 1.15;
}

.om-live-status {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-width: 210px;
    max-width: 340px;
    padding: 10px 13px;
    border-radius: 12px;
    background: var(--om-closed-bg);
    color: var(--om-closed);
}

.om-live-status.is-open {
    background: var(--om-open-bg);
    color: var(--om-open);
}

.om-status-dot {
    width: 10px;
    height: 10px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: currentColor;
    box-shadow: 0 0 0 4px rgba(180, 35, 24, .09);
}

.om-live-status.is-open .om-status-dot {
    box-shadow: 0 0 0 4px rgba(6, 118, 71, .10);
}

.om-status-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 2px;
    line-height: 1.25;
}

.om-status-copy strong {
    font-size: 14px;
    font-weight: 700;
}

.om-status-copy span {
    color: var(--om-muted);
    font-size: 12px;
    line-height: 1.35;
}

/* Abweichungen stehen bewusst vor der Wochenübersicht. */
.om-hours .om-exceptions {
    padding: 22px 28px 24px;
    border-bottom: 1px solid var(--om-border);
    background: #fcfcfd;
}

.om-hours .om-section-title {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    margin: 0 0 12px;
}

.om-hours .om-section-title h3 {
    margin: 0 !important;
    padding: 0 !important;
    color: var(--om-text);
    font-size: 16px;
    font-weight: 700;
    line-height: 1.3;
}

.om-hours .om-section-title > span {
    color: var(--om-muted);
    font-size: 12px;
    line-height: 1.4;
}

.om-hours .om-exception-list {
    display: grid;
    gap: 9px;
}

.om-hours .om-exception {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    min-height: 62px;
    padding: 12px 14px;
    border: 1px solid var(--om-border);
    border-radius: 11px;
    background: #fff;
}

.om-hours .om-exception.is-active {
    border-color: var(--om-warning-border);
    background: var(--om-warning-bg);
}

.om-hours .om-exception-main {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.om-hours .om-exception-date-line {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
}

.om-hours .om-exception-main strong {
    color: var(--om-text);
    font-size: 14px;
    font-weight: 700;
}

.om-hours .om-exception-main > span {
    color: var(--om-muted);
    font-size: 13px;
    line-height: 1.35;
}

.om-hours .om-active-badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 7px;
    border-radius: 999px;
    background: #fff4e5;
    color: #b54708;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .02em;
    text-transform: uppercase;
}

.om-hours .om-exception-hours {
    flex: 0 0 auto;
    color: var(--om-text);
    font-size: 14px;
    font-weight: 700;
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.om-hours .om-exception-hours.is-closed {
    color: var(--om-closed);
}

/* Wochenübersicht */
.om-hours .om-week {
    padding: 22px 28px 28px;
}

.om-hours .om-week-title {
    margin-bottom: 10px;
}

.om-hours .om-table-wrap {
    width: 100%;
    overflow: hidden;
    border: 1px solid var(--om-border);
    border-radius: 12px;
    background: #fff;
}

/* Hohe Spezifität, damit Theme-Tabellenstyles die Anordnung nicht zerlegen. */
.om-hours .om-schedule-table {
    display: table !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-collapse: collapse !important;
    border-spacing: 0 !important;
    table-layout: fixed !important;
    background: transparent !important;
    color: var(--om-text) !important;
    font-size: 14px;
    line-height: 1.35;
}

.om-hours .om-schedule-table thead {
    display: table-header-group !important;
}

.om-hours .om-schedule-table tbody {
    display: table-row-group !important;
}

.om-hours .om-schedule-table tr {
    display: table-row !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: #fff !important;
}

.om-hours .om-schedule-table th,
.om-hours .om-schedule-table td {
    display: table-cell !important;
    height: auto !important;
    margin: 0 !important;
    padding: 14px 16px !important;
    border: 0 !important;
    border-bottom: 1px solid var(--om-border-soft) !important;
    background: transparent !important;
    color: var(--om-text) !important;
    text-align: left !important;
    vertical-align: middle !important;
}

.om-hours .om-schedule-table tbody tr:last-child th,
.om-hours .om-schedule-table tbody tr:last-child td {
    border-bottom: 0 !important;
}

.om-hours .om-schedule-table thead th {
    padding-top: 10px !important;
    padding-bottom: 10px !important;
    background: var(--om-soft) !important;
    color: var(--om-muted) !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    letter-spacing: .055em;
    text-transform: uppercase;
}

.om-hours .om-schedule-table .om-col-day,
.om-hours .om-schedule-table .om-day-cell {
    width: 34%;
}

.om-hours .om-schedule-table tbody tr.om-today th,
.om-hours .om-schedule-table tbody tr.om-today td {
    background: #f7f9fc !important;
}

.om-hours .om-schedule-table tbody tr.om-has-deviation th,
.om-hours .om-schedule-table tbody tr.om-has-deviation td {
    background: #fffdfa !important;
}

.om-hours .om-schedule-table tbody tr.om-today.om-has-deviation th,
.om-hours .om-schedule-table tbody tr.om-today.om-has-deviation td {
    background: #fff9ed !important;
}

.om-hours .om-day-cell {
    font-weight: 400 !important;
}

.om-hours .om-day-line {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
    margin-bottom: 2px;
}

.om-hours .om-day {
    color: var(--om-text);
    font-size: 14px;
    font-weight: 700;
}

.om-hours .om-day-date {
    display: block;
    color: var(--om-muted);
    font-size: 11px;
    font-weight: 500;
}

.om-hours .om-today-label {
    display: inline-flex;
    align-items: center;
    padding: 2px 7px;
    border-radius: 999px;
    background: #eef4ff;
    color: #3538cd;
    font-size: 10px;
    font-weight: 700;
}

.om-hours .om-row-reason {
    display: block;
    margin-top: 5px;
    color: #b54708;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.25;
}

.om-hours .om-period-cell,
.om-hours .om-continuous-cell,
.om-hours .om-schedule-state-cell {
    font-variant-numeric: tabular-nums;
}

.om-hours .om-period-time {
    color: var(--om-text);
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
}

.om-hours .om-period-unit {
    color: var(--om-muted);
    font-size: 11px;
    white-space: nowrap;
}

.om-hours .om-period-cell.is-empty {
    color: #98a2b3 !important;
}

.om-hours .om-empty-mark {
    color: #98a2b3;
    font-size: 16px;
}

.om-hours .om-continuous-cell {
    text-align: left !important;
}

.om-hours .om-continuous-badge {
    display: inline-flex;
    align-items: center;
    margin-right: 10px;
    padding: 3px 8px;
    border-radius: 999px;
    background: #eef4ff;
    color: #1849a9;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .02em;
    text-transform: uppercase;
    vertical-align: 1px;
}

.om-hours .om-state-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 5px 9px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 700;
}

.om-hours .om-state-badge.is-closed {
    background: var(--om-closed-bg);
    color: var(--om-closed);
}

.om-hours .om-state-badge.is-muted {
    background: var(--om-soft);
    color: var(--om-muted);
}

.om-hours .om-state-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
}

/* Einzel-Shortcodes */
.om-status-card {
    display: inline-block;
    max-width: 100%;
    padding: 0;
}

.om-status-card .om-live-status {
    border: 1px solid rgba(16, 24, 40, .07);
    box-shadow: 0 5px 18px rgba(16, 24, 40, .06);
}

.om-compact-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    max-width: 560px;
    padding: 14px 16px;
    border: 1px solid var(--om-border);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 5px 18px rgba(16, 24, 40, .05);
}

.om-compact-card > div {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.om-compact-label,
.om-note {
    color: var(--om-muted);
    font-size: 12px;
}

.om-compact-card strong {
    font-size: 15px;
}

.om-note {
    text-align: right;
}

@media (max-width: 680px) {
    .om-hours .om-card-head {
        align-items: stretch;
        flex-direction: column;
        gap: 14px;
        padding: 20px;
    }

    .om-hours .om-live-status {
        width: 100%;
        max-width: none;
    }

    .om-hours .om-exceptions,
    .om-hours .om-week {
        padding: 18px 20px 20px;
    }

    .om-hours .om-section-title {
        align-items: flex-start;
        flex-direction: column;
        gap: 3px;
    }

    .om-hours .om-exception {
        align-items: flex-start;
        flex-direction: column;
        gap: 7px;
    }

    .om-hours .om-exception-hours {
        text-align: left;
    }

    .om-hours .om-schedule-table th,
    .om-hours .om-schedule-table td {
        padding: 12px 10px !important;
    }

    .om-hours .om-schedule-table .om-col-day,
    .om-hours .om-schedule-table .om-day-cell {
        width: 36%;
    }

    .om-hours .om-period-time {
        font-size: 13px;
    }

    .om-hours .om-period-unit {
        display: none;
    }

    .om-hours .om-continuous-badge {
        display: block;
        width: fit-content;
        margin: 0 0 4px;
    }

    .om-compact-card {
        align-items: flex-start;
        flex-direction: column;
        gap: 7px;
    }

    .om-note {
        text-align: left;
    }
}

@media (max-width: 430px) {
    .om-hours .om-exceptions,
    .om-hours .om-week {
        padding-right: 14px;
        padding-left: 14px;
    }

    .om-hours .om-schedule-table {
        font-size: 12px;
    }

    .om-hours .om-schedule-table thead th {
        padding-right: 7px !important;
        padding-left: 7px !important;
        font-size: 9px !important;
    }

    .om-hours .om-schedule-table th,
    .om-hours .om-schedule-table td {
        padding: 11px 7px !important;
    }

    .om-hours .om-day,
    .om-hours .om-period-time {
        font-size: 12px;
    }

    .om-hours .om-day-date,
    .om-hours .om-row-reason {
        font-size: 10px;
    }

    .om-hours .om-today-label {
        padding: 1px 5px;
        font-size: 9px;
    }
}

/* Version 2.6 – exakte 3-Spalten-Abweichungen und durchgehende Zeit mittig */
.om-hours.om-card {
    --om-screen-shift: 0px;
    position: relative !important;
    left: var(--om-screen-shift) !important;
    width: min(980px, calc(100vw - 40px)) !important;
    max-width: none !important;
    margin: 0 auto !important;
}

.om-hours .om-exceptions {
    background: #fff;
}

.om-hours .om-exceptions .om-section-title {
    margin-bottom: 12px;
}

.om-hours .om-exception-table {
    overflow: hidden;
    border: 1px solid var(--om-border);
    border-radius: 12px;
    background: #fff;
}

.om-hours .om-exception-head,
.om-hours .om-exception {
    display: grid;
    grid-template-columns: minmax(190px, .95fr) minmax(280px, 1.65fr) minmax(180px, .8fr);
    column-gap: 22px;
    align-items: center;
    width: 100%;
}

.om-hours .om-exception-head {
    padding: 10px 18px;
    background: var(--om-soft);
    color: var(--om-muted);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .055em;
    line-height: 1.2;
    text-align: left;
    text-transform: uppercase;
}

.om-hours .om-exception-list {
    display: block;
}

.om-hours .om-exception {
    min-height: 58px;
    padding: 14px 18px;
    border: 0;
    border-top: 1px solid var(--om-border-soft);
    border-radius: 0;
    background: #fff;
    box-shadow: none;
}

.om-hours .om-exception:first-child {
    border-top: 0;
}

.om-hours .om-exception.is-active {
    border-color: var(--om-border-soft);
    background: #fffaf0;
    box-shadow: inset 3px 0 0 #f79009;
}

.om-hours .om-exception-date,
.om-hours .om-exception-main,
.om-hours .om-exception-hours {
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    text-align: left !important;
}

.om-hours .om-exception-date {
    display: block;
}

.om-hours .om-exception-date strong,
.om-hours .om-exception-main strong,
.om-hours .om-exception-hours {
    color: var(--om-text);
    font-size: 13px;
    line-height: 1.4;
}

.om-hours .om-exception-date strong {
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.om-hours .om-exception-main {
    display: block;
}

.om-hours .om-exception-main strong {
    display: block;
    font-weight: 650;
}

.om-hours .om-exception-hours {
    display: block;
    min-width: 0;
    font-weight: 700;
    white-space: normal;
}

.om-hours .om-exception-hours.is-closed {
    color: var(--om-closed);
}

.om-hours .om-exception-hours.is-open {
    color: var(--om-open);
}

/* Ein einziges durchgehendes Zeitfenster belegt beide Spalten und steht mittig. */
.om-hours .om-continuous-cell {
    text-align: center !important;
}

.om-hours .om-continuous-cell .om-period-time,
.om-hours .om-continuous-cell .om-period-unit {
    vertical-align: middle;
}

@media (max-width: 760px) {
    .om-hours.om-card {
        width: calc(100vw - 24px) !important;
    }

    .om-hours .om-exception-head {
        display: none;
    }

    .om-hours .om-exception {
        grid-template-columns: 1fr;
        row-gap: 5px;
        padding: 14px 15px;
    }

    .om-hours .om-exception-date,
    .om-hours .om-exception-main,
    .om-hours .om-exception-hours {
        display: grid;
        grid-template-columns: 72px minmax(0, 1fr);
        column-gap: 10px;
        align-items: baseline;
    }

    .om-hours .om-exception-date::before,
    .om-hours .om-exception-main::before,
    .om-hours .om-exception-hours::before {
        color: var(--om-muted);
        font-size: 10px;
        font-weight: 700;
        letter-spacing: .045em;
        text-transform: uppercase;
    }

    .om-hours .om-exception-date::before { content: "Datum"; }
    .om-hours .om-exception-main::before { content: "Grund"; }
    .om-hours .om-exception-hours::before { content: "Art"; }
}


/* Version 2.6 */
.om-hours .om-exception-head,
.om-hours .om-exception {
    grid-template-columns: minmax(200px, 1fr) minmax(300px, 1.6fr) minmax(180px, 0.9fr) !important;
}

.om-hours .om-exception-head > span:nth-child(1),
.om-hours .om-exception > .om-exception-date {
    grid-column: 1 !important;
}

.om-hours .om-exception-head > span:nth-child(2),
.om-hours .om-exception > .om-exception-main {
    grid-column: 2 !important;
}

.om-hours .om-exception-head > span:nth-child(3),
.om-hours .om-exception > .om-exception-hours {
    grid-column: 3 !important;
}

.om-hours .om-exception-date,
.om-hours .om-exception-main,
.om-hours .om-exception-hours,
.om-hours .om-exception-head > span {
    justify-self: start !important;
    align-self: center !important;
    text-align: left !important;
}

.om-hours .om-exception-hours strong {
    font-size: 13px;
    font-weight: 700;
}

.om-hours .om-continuous-cell {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.om-hours .om-continuous-wrap {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    text-align: center !important;
    gap: 0 !important;
}

.om-hours .om-continuous-wrap .om-period-time,
.om-hours .om-continuous-wrap .om-period-unit {
    display: inline-block;
}

@media (max-width: 760px) {
    .om-hours .om-exception-date,
    .om-hours .om-exception-main,
    .om-hours .om-exception-hours {
        grid-template-columns: 92px minmax(0, 1fr) !important;
    }

    .om-hours .om-exception-hours::before {
        content: "Abweichung";
    }
}


/* Version 2.8 – Zeitspalten zentriert; durchgehend über beide Zeitspalten */
.om-hours .om-schedule-table thead th:nth-child(2),
.om-hours .om-schedule-table thead th:nth-child(3) {
    text-align: center !important;
}

.om-hours .om-schedule-table td.om-period-cell,
.om-hours .om-schedule-table td.om-schedule-state-cell,
.om-hours .om-schedule-table td.om-continuous-cell {
    text-align: center !important;
}

.om-hours .om-period-cell .om-period-time,
.om-hours .om-period-cell .om-period-unit {
    display: inline-block;
}

/* Die zusammengefasste Zelle umfasst ausschließlich Vormittag + Nachmittag. */
.om-hours .om-continuous-cell {
    padding-left: 16px !important;
    padding-right: 16px !important;
}

.om-hours .om-continuous-wrap {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    transform: none !important;
    text-align: center !important;
    white-space: nowrap !important;
}

.om-hours .om-continuous-wrap .om-period-time,
.om-hours .om-continuous-wrap .om-period-unit {
    display: inline-block;
}


/* Version 2.9 – etwas groessere, besser lesbare Typografie */
.om-hours .om-section-title h3 {
    font-size: 18px !important;
}

.om-hours .om-section-title > span {
    font-size: 13px !important;
}

.om-hours .om-exception-head {
    font-size: 12px !important;
}

.om-hours .om-exception-date strong,
.om-hours .om-exception-main strong,
.om-hours .om-exception-hours,
.om-hours .om-exception-hours strong {
    font-size: 14px !important;
}

.om-hours .om-schedule-table {
    font-size: 15px !important;
}

.om-hours .om-schedule-table thead th {
    font-size: 12px !important;
}

.om-hours .om-day {
    font-size: 15px !important;
}

.om-hours .om-day-date {
    font-size: 12px !important;
}

.om-hours .om-period-time {
    font-size: 15px !important;
}

.om-hours .om-period-unit {
    font-size: 12px !important;
}

.om-hours .om-state-badge {
    font-size: 13px !important;
}

.om-hours .om-row-reason {
    font-size: 12px !important;
}

.om-hours .om-today-label {
    font-size: 11px !important;
}

.om-hours .om-status-copy strong {
    font-size: 15px !important;
}

.om-hours .om-status-copy span {
    font-size: 13px !important;
}

@media (max-width: 430px) {
    .om-hours .om-schedule-table {
        font-size: 13px !important;
    }

    .om-hours .om-schedule-table thead th {
        font-size: 10px !important;
    }

    .om-hours .om-day,
    .om-hours .om-period-time {
        font-size: 13px !important;
    }

    .om-hours .om-day-date,
    .om-hours .om-row-reason {
        font-size: 11px !important;
    }
}

/* Version 3.0 – mobile Abweichungen als lesbare Karten */
@media (max-width: 760px) {
    .om-hours .om-exceptions {
        padding: 18px 16px 20px !important;
    }

    .om-hours .om-exceptions .om-section-title {
        justify-content: center !important;
        margin-bottom: 14px !important;
        text-align: center !important;
    }

    .om-hours .om-exception-table {
        overflow: visible !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: transparent !important;
    }

    .om-hours .om-exception-list {
        display: grid !important;
        gap: 10px !important;
    }

    .om-hours .om-exception {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 11px !important;
        min-height: 0 !important;
        padding: 14px 15px !important;
        border: 1px solid var(--om-border) !important;
        border-radius: 12px !important;
        background: #fff !important;
        box-shadow: 0 2px 8px rgba(16, 24, 40, .03) !important;
    }

    .om-hours .om-exception.is-active {
        border-color: var(--om-warning-border) !important;
        background: var(--om-warning-bg) !important;
        box-shadow: none !important;
    }

    .om-hours .om-exception-date,
    .om-hours .om-exception-main,
    .om-hours .om-exception-hours {
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 3px !important;
        width: 100% !important;
        min-width: 0 !important;
        text-align: left !important;
    }

    .om-hours .om-exception-date::before,
    .om-hours .om-exception-main::before,
    .om-hours .om-exception-hours::before {
        display: block !important;
        color: var(--om-muted) !important;
        font-size: 10px !important;
        font-weight: 700 !important;
        letter-spacing: .055em !important;
        line-height: 1.2 !important;
        text-transform: uppercase !important;
    }

    .om-hours .om-exception-date::before { content: "Datum" !important; }
    .om-hours .om-exception-main::before { content: "Grund" !important; }
    .om-hours .om-exception-hours::before { content: "Abweichung" !important; }

    .om-hours .om-exception-date strong,
    .om-hours .om-exception-main strong,
    .om-hours .om-exception-hours,
    .om-hours .om-exception-hours strong {
        max-width: 100% !important;
        font-size: 14px !important;
        line-height: 1.4 !important;
        overflow-wrap: anywhere !important;
    }

    .om-hours .om-exception-hours strong {
        display: inline-flex !important;
        width: auto !important;
        padding: 5px 9px !important;
        border-radius: 8px !important;
        background: var(--om-open-bg) !important;
        color: var(--om-open) !important;
    }

    .om-hours .om-exception-hours.is-closed strong {
        background: var(--om-closed-bg) !important;
        color: var(--om-closed) !important;
    }
}

@media (max-width: 430px) {
    .om-hours .om-exceptions {
        padding-right: 12px !important;
        padding-left: 12px !important;
    }

    .om-hours .om-exception {
        padding: 13px !important;
    }

    .om-hours .om-exceptions .om-section-title h3 {
        font-size: 17px !important;
    }
}
