/**
 * SW Trading Holidays — Consolidated Base CSS
 *
 * Single stylesheet for all three layouts: card-table, list-grid, list-table.
 * All design tokens use --swth-* CSS variables. Neutral defaults are set on
 * .swth-view, then layout-specific defaults on .swth-view--{layout}.
 * Elementor controls override via {{WRAPPER}} selectors.
 *
 * @package SW_Trading_Holidays
 */

/* ==========================================================================
   1. CSS Variable Declarations — Neutral Defaults
   ========================================================================== */

.swth-view {
    /* Container */
    --swth-container-max-width: 100%;
    --swth-container-bg: transparent;
    --swth-items-gap: 40px;

    /* Card / Event */
    --swth-card-bg: transparent;
    --swth-card-border-style: none;
    --swth-card-border-width: 0;
    --swth-card-border-color: transparent;
    --swth-card-border-radius: 0;
    --swth-card-box-shadow: none;
    --swth-card-padding-top: 0;
    --swth-card-padding-right: 0;
    --swth-card-padding-bottom: 0;
    --swth-card-padding-left: 0;
    --swth-card-gap: 40px;

    /* Header */
    --swth-header-bg: transparent;
    --swth-header-padding-top: 0;
    --swth-header-padding-right: 0;
    --swth-header-padding-bottom: 0;
    --swth-header-padding-left: 0;
    --swth-header-border-radius: 0;
    --swth-header-border-style: none;
    --swth-header-border-width: 0;
    --swth-header-border-color: transparent;

    /* Date */
    --swth-date-color: inherit;
    --swth-date-font-size: inherit;
    --swth-date-font-weight: 700;
    --swth-date-line-height: 1.3;
    --swth-date-font-family: inherit;
    --swth-date-text-transform: none;
    --swth-date-letter-spacing: 0;

    /* Title */
    --swth-title-color: inherit;
    --swth-title-font-size: inherit;
    --swth-title-font-weight: 700;
    --swth-title-line-height: 1.3;
    --swth-title-font-family: inherit;
    --swth-title-text-transform: none;
    --swth-title-letter-spacing: 0;

    /* Head label */
    --swth-head-label-color: inherit;
    --swth-head-label-font-size: inherit;
    --swth-head-label-font-weight: 600;
    --swth-head-label-line-height: 1.3;
    --swth-head-label-font-family: inherit;
    --swth-head-label-text-transform: none;
    --swth-head-label-letter-spacing: 0;

    /* Head border */
    --swth-head-border-color: transparent;
    --swth-head-border-width: 0;

    /* Asset */
    --swth-asset-color: inherit;
    --swth-asset-font-size: inherit;
    --swth-asset-font-weight: 400;
    --swth-asset-line-height: 1.35;
    --swth-asset-font-family: inherit;
    --swth-asset-text-transform: none;
    --swth-asset-letter-spacing: 0;

    /* Row */
    --swth-row-border-color: transparent;
    --swth-row-border-width: 0;
    --swth-row-padding-top: 0;
    --swth-row-padding-right: 0;
    --swth-row-padding-bottom: 0;
    --swth-row-padding-left: 0;

    /* Status */
    --swth-status-font-size: inherit;
    --swth-status-font-weight: 400;
    --swth-status-line-height: 20px;
    --swth-status-font-family: inherit;
    --swth-status-text-transform: none;
    --swth-status-letter-spacing: 0;

    /* Badge */
    --swth-badge-border-radius: 6px;
    --swth-badge-padding-top: 3px;
    --swth-badge-padding-right: 10px;
    --swth-badge-padding-bottom: 3px;
    --swth-badge-padding-left: 10px;

    /* Status colors */
    --swth-status-default-bg: rgba(255, 128, 0, 0.1);
    --swth-status-default-text: #ff8000;
    --swth-status-open-bg: #e6f5ec;
    --swth-status-open-text: #1d8b55;
    --swth-status-closed-bg: rgba(254, 90, 90, 0.2);
    --swth-status-closed-text: rgba(254, 90, 90, 1);
    --swth-status-early-close-bg: rgba(255, 128, 0, 0.1);
    --swth-status-early-close-text: #ff8000;

    /* Empty state */
    --swth-empty-color: #6d789a;
    --swth-empty-font-family: inherit;
    --swth-empty-font-size: 15px;
    --swth-empty-font-weight: 400;
    --swth-empty-line-height: 1.4;
    --swth-empty-text-transform: none;
    --swth-empty-letter-spacing: 0;

    /* List-grid specific */
    --swth-card-alt-bg: transparent;
    --swth-card-date-bg: transparent;

    /* List-table specific */
    --swth-table-header-color: inherit;
    --swth-table-header-font-size: inherit;
    --swth-table-header-font-weight: 500;
    --swth-table-header-line-height: 40px;
    --swth-table-header-font-family: inherit;
    --swth-table-header-text-transform: none;
    --swth-table-header-letter-spacing: 0;
    --swth-divider-color: transparent;
    --swth-divider-width: 0;

    /* Internal layout tokens (not exposed as Elementor controls) */
    --swth--gap-cols: 64px;
    --swth--gap-cells: 16px;
}

/* --------------------------------------------------------------------------
   1a. Card-Table Layout Defaults (from original default.css)
   -------------------------------------------------------------------------- */

.swth-view--card-table {
    --swth-card-bg: #ffffff;
    --swth-card-border-style: solid;
    --swth-card-border-width: 1px;
    --swth-card-border-color: #e5e7ef;
    --swth-card-border-radius: 24px;
    --swth-card-box-shadow: 0 18px 40px rgba(16, 24, 40, 0.08);
    --swth-card-gap: 40px;
    --swth-header-bg: #f4f6ff;
    --swth-header-padding-top: 14px;
    --swth-header-padding-right: 20px;
    --swth-header-padding-bottom: 14px;
    --swth-header-padding-left: 20px;
    --swth-header-border-radius: 15px;
    --swth-date-color: #1f2937;
    --swth-date-font-size: 28px;
    --swth-date-font-weight: 800;
    --swth-title-color: #0ea5a6;
    --swth-title-font-size: 28px;
    --swth-title-font-weight: 700;
    --swth-head-label-color: #1f2f5c;
    --swth-head-label-font-size: 20px;
    --swth-head-label-font-weight: 600;
    --swth-head-border-color: #cbd5f1;
    --swth-head-border-width: 3px;
    --swth-asset-color: #1f2937;
    --swth-asset-font-size: 18px;
    --swth-asset-font-weight: 600;
    --swth-row-border-color: #e7eaf8;
    --swth-row-border-width: 1px;
    --swth-row-padding-top: 7px;
    --swth-row-padding-bottom: 7px;
    --swth-status-font-size: 16px;
    --swth-status-font-weight: 700;
    --swth-empty-color: #6d789a;
}

/* --------------------------------------------------------------------------
   1b. List-Grid Layout Defaults (from original tradgrip.css)
   -------------------------------------------------------------------------- */

.swth-view--list-grid {
    --swth-items-gap: 24px;
    --swth-card-bg: #ffffff;
    --swth-card-border-radius: 10px;
    --swth-card-alt-bg: #f4f9fd;
    --swth-card-date-bg: #e8f5fc;
    --swth-date-font-size: 25px;
    --swth-date-font-weight: 400;
    --swth-date-line-height: 35px;
    --swth-date-font-family: 'Roboto', sans-serif;
    --swth-title-font-size: 25px;
    --swth-title-font-weight: 400;
    --swth-title-line-height: 35px;
    --swth-title-font-family: 'Roboto', sans-serif;
    --swth-asset-font-size: 16px;
    --swth-asset-font-weight: 400;
    --swth-asset-line-height: 26px;
    --swth-asset-font-family: 'Roboto', sans-serif;
    --swth-status-font-size: 16px;
    --swth-status-font-weight: 400;
    --swth-status-line-height: 26px;
    --swth-status-font-family: 'Roboto', sans-serif;
    --swth-head-label-font-family: 'Roboto', sans-serif;
}

/* --------------------------------------------------------------------------
   1c. List-Table Layout Defaults (from original first-ecn.css)
   -------------------------------------------------------------------------- */

.swth-view--list-table {
    --swth-items-gap: 70px;
    --swth-card-bg: #ffffff;
    --swth-card-border-radius: 100px;
    --swth-card-box-shadow: 0px 25px 25px 1px #b5d8e7;
    --swth-card-padding-top: 78px;
    --swth-card-padding-right: 50px;
    --swth-card-padding-bottom: 78px;
    --swth-card-padding-left: 50px;
    --swth-date-color: #1f2c3d;
    --swth-date-font-size: 25px;
    --swth-date-font-weight: 700;
    --swth-date-line-height: 30px;
    --swth-date-font-family: "Maven Pro", sans-serif;
    --swth-title-color: #1f2c3d;
    --swth-title-font-size: 25px;
    --swth-title-font-weight: 700;
    --swth-title-line-height: 30px;
    --swth-title-font-family: "Maven Pro", sans-serif;
    --swth-asset-color: #1f2c3d;
    --swth-asset-font-size: 18px;
    --swth-asset-font-weight: 400;
    --swth-asset-line-height: 28px;
    --swth-asset-font-family: "Roboto", sans-serif;
    --swth-status-font-size: 18px;
    --swth-status-font-weight: 400;
    --swth-status-line-height: 28px;
    --swth-status-font-family: "Roboto", sans-serif;
    --swth-table-header-font-size: 35px;
    --swth-table-header-font-weight: 500;
    --swth-table-header-line-height: 40px;
    --swth-table-header-font-family: "Maven Pro", sans-serif;
    --swth-divider-color: #faaf00;
    --swth-divider-width: 2px;
    --swth-card-date-bg: #e8f5fc;
}

/* ==========================================================================
   2. Base Layout
   ========================================================================== */

.swth-view {
    width: 100%;
    max-width: var(--swth-container-max-width);
    margin: 0 auto;
    padding: 0;
    background-color: var(--swth-container-bg);
    font-family: inherit;
    box-sizing: border-box;
}

.swth-view *,
.swth-view *::before,
.swth-view *::after {
    box-sizing: border-box;
}

/* ==========================================================================
   3. Card Table Layout
   ========================================================================== */

.swth-view--card-table {
    display: flex;
    flex-direction: column;
    gap: var(--swth-items-gap);
}

/* --- Card --- */

.swth-view--card-table .swth-card {
    padding: var(--swth-card-padding-top) var(--swth-card-padding-right) var(--swth-card-padding-bottom) var(--swth-card-padding-left);
    display: flex;
    flex-direction: column;
    gap: var(--swth-card-gap);
    background: var(--swth-card-bg);
    border-style: var(--swth-card-border-style);
    border-width: var(--swth-card-border-width);
    border-color: var(--swth-card-border-color);
    border-radius: var(--swth-card-border-radius);
    box-shadow: var(--swth-card-box-shadow);
}

/* --- Header (pill) --- */

.swth-view--card-table .swth-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--swth--gap-cells);
    text-align: center;
    background: var(--swth-header-bg);
    border-style: var(--swth-header-border-style);
    border-width: var(--swth-header-border-width);
    border-color: var(--swth-header-border-color);
    border-radius: var(--swth-header-border-radius);
    padding: var(--swth-header-padding-top) var(--swth-header-padding-right) var(--swth-header-padding-bottom) var(--swth-header-padding-left);
}

.swth-view--card-table .swth-date,
.swth-view--card-table .swth-title {
    margin: 0;
    line-height: var(--swth-date-line-height);
    font-weight: 700;
}

.swth-view--card-table .swth-date {
    color: var(--swth-date-color);
    font-family: var(--swth-date-font-family);
    font-size: var(--swth-date-font-size);
    font-weight: var(--swth-date-font-weight);
    line-height: var(--swth-date-line-height);
    text-transform: var(--swth-date-text-transform);
    letter-spacing: var(--swth-date-letter-spacing);
}

.swth-view--card-table .swth-title {
    color: var(--swth-title-color);
    font-family: var(--swth-title-font-family);
    font-size: var(--swth-title-font-size);
    font-weight: var(--swth-title-font-weight);
    line-height: var(--swth-title-line-height);
    text-transform: var(--swth-title-text-transform);
    letter-spacing: var(--swth-title-letter-spacing);
}

/* --- Body --- */

.swth-view--card-table .swth-body {
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* --- Head border (column headings) --- */

.swth-view--card-table .swth-head-border {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: var(--swth--gap-cols);
}

.swth-view--card-table .swth-head-border > div {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: var(--swth--gap-cols);
    align-items: end;
    padding-bottom: 10px;
    border-bottom: var(--swth-head-border-width) solid var(--swth-head-border-color);
}

.swth-view--card-table .swth-head-label {
    color: var(--swth-head-label-color);
    font-family: var(--swth-head-label-font-family);
    font-size: var(--swth-head-label-font-size);
    font-weight: var(--swth-head-label-font-weight);
    line-height: var(--swth-head-label-line-height);
    text-transform: var(--swth-head-label-text-transform);
    letter-spacing: var(--swth-head-label-letter-spacing);
}

/* --- Row groups --- */

.swth-view--card-table .swth-row-group {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: var(--swth--gap-cols);
}

/* --- Rows --- */

.swth-view--card-table .swth-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: var(--swth--gap-cols);
    align-items: start;
    padding: var(--swth-row-padding-top) var(--swth-row-padding-right) var(--swth-row-padding-bottom) var(--swth-row-padding-left);
    border-bottom: var(--swth-row-border-width) solid var(--swth-row-border-color);
}

.swth-view--card-table .swth-row-group:last-child .swth-row {
    border-bottom: none;
}

/* --- Asset cell --- */

.swth-view--card-table .swth-cell--asset {
    color: var(--swth-asset-color);
    font-family: var(--swth-asset-font-family);
    font-size: var(--swth-asset-font-size);
    font-weight: var(--swth-asset-font-weight);
    line-height: var(--swth-asset-line-height);
    text-transform: var(--swth-asset-text-transform);
    letter-spacing: var(--swth-asset-letter-spacing);
}

/* --- Status cell --- */

.swth-view--card-table .swth-cell--status {
    display: flex;
    align-items: center;
    justify-self: start;
    font-family: var(--swth-status-font-family);
    font-size: var(--swth-status-font-size);
    font-weight: var(--swth-status-font-weight);
    text-transform: var(--swth-status-text-transform);
    letter-spacing: var(--swth-status-letter-spacing);
}

/* ==========================================================================
   4. List Grid Layout
   ========================================================================== */

.swth-view--list-grid {
    display: grid;
    gap: var(--swth-items-gap);
}

/* --- Event --- */

.swth-view--list-grid .swth-event {
    display: flex;
    align-items: stretch;
    background: var(--swth-card-bg);
    border-radius: var(--swth-card-border-radius);
    overflow: hidden;
}

.swth-view--list-grid .swth-event--even {
    background: var(--swth-card-alt-bg);
}

.swth-view--list-grid .swth-event--odd {
    background: var(--swth-card-bg);
}

.swth-view--list-grid .swth-event--first {
    border-radius: var(--swth-card-border-radius) var(--swth-card-border-radius) 0 0;
}

.swth-view--list-grid .swth-event--last {
    border-radius: 0 0 var(--swth-card-border-radius) var(--swth-card-border-radius);
}

/* --- Header --- */

.swth-view--list-grid .swth-header {
    display: flex;
    align-items: stretch;
    flex: 0 0 50%;
    border-style: var(--swth-header-border-style);
    border-width: var(--swth-header-border-width);
    border-color: var(--swth-header-border-color);
}

/* --- Date & Title --- */

.swth-view--list-grid .swth-date,
.swth-view--list-grid .swth-title,
.swth-view--list-grid .swth-cell--asset,
.swth-view--list-grid .swth-cell--status {
    display: flex;
    align-items: center;
    align-self: center;
    margin: 0;
}

.swth-view--list-grid .swth-date {
    flex: 0 0 50%;
    padding: 24px 32px;
    text-align: center;
    justify-content: center;
    color: var(--swth-date-color);
    font-family: var(--swth-date-font-family);
    font-size: var(--swth-date-font-size);
    font-weight: var(--swth-date-font-weight);
    line-height: var(--swth-date-line-height);
    text-transform: var(--swth-date-text-transform);
    letter-spacing: var(--swth-date-letter-spacing);
}

.swth-view--list-grid .swth-title {
    flex: 0 0 50%;
    padding: 24px 32px;
    text-align: left;
    justify-content: flex-start;
    color: var(--swth-title-color);
    font-family: var(--swth-title-font-family);
    font-size: var(--swth-title-font-size);
    font-weight: var(--swth-title-font-weight);
    line-height: var(--swth-title-line-height);
    text-transform: var(--swth-title-text-transform);
    letter-spacing: var(--swth-title-letter-spacing);
}

/* --- Body --- */

.swth-view--list-grid .swth-body {
    display: flex;
    flex: 0 0 50%;
    flex-wrap: wrap;
    align-items: center;
    row-gap: 8px;
}

/* --- Body headings --- */

.swth-view--list-grid .swth-body-headings {
    display: none;
    flex: 0 0 100%;
}

.swth-view--list-grid .swth-body-heading {
    margin: 0;
    font-weight: 700;
    text-align: left;
    font-family: var(--swth-head-label-font-family);
    color: var(--swth-head-label-color);
}

/* --- Cells --- */

.swth-view--list-grid .swth-cell--asset {
    flex: 0 0 50%;
    padding: 24px 32px;
    color: var(--swth-asset-color);
    font-family: var(--swth-asset-font-family);
    font-size: var(--swth-asset-font-size);
    font-weight: var(--swth-asset-font-weight);
    line-height: var(--swth-asset-line-height);
    text-transform: var(--swth-asset-text-transform);
    letter-spacing: var(--swth-asset-letter-spacing);
    text-align: left;
    justify-content: flex-start;
}

.swth-view--list-grid .swth-cell--status {
    flex: 0 0 50%;
    padding: 24px 32px;
    font-family: var(--swth-status-font-family);
    font-size: var(--swth-status-font-size);
    font-weight: var(--swth-status-font-weight);
    line-height: var(--swth-status-line-height);
    text-transform: var(--swth-status-text-transform);
    letter-spacing: var(--swth-status-letter-spacing);
    justify-content: flex-start;
}

/* --- Spacer --- */

.swth-view--list-grid .swth-event--spacer .swth-date,
.swth-view--list-grid .swth-event--spacer .swth-title,
.swth-view--list-grid .swth-event--spacer .swth-cell--asset,
.swth-view--list-grid .swth-event--spacer .swth-cell--status {
    visibility: hidden;
}

/* ==========================================================================
   5. List Table Layout
   ========================================================================== */

.swth-view--list-table {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: var(--swth-items-gap);
}

/* --- Table header (desktop column labels) --- */

.swth-view--list-table .swth-table-header {
    display: flex;
    align-items: center;
    width: 100%;
    align-self: stretch;
    padding-inline: 50px;
    margin-bottom: 20px;
    text-align: center;
    color: var(--swth-table-header-color);
    font-family: var(--swth-table-header-font-family);
    font-size: var(--swth-table-header-font-size);
    font-weight: var(--swth-table-header-font-weight);
    line-height: var(--swth-table-header-line-height);
    text-transform: var(--swth-table-header-text-transform);
    letter-spacing: var(--swth-table-header-letter-spacing);
}

.swth-view--list-table .swth-table-heading {
    flex: 0 0 25%;
    padding-inline: 16px;
    font-size: inherit;
    font-weight: inherit;
    line-height: inherit;
    text-align: center;
    margin: 0;
}

/* --- Event card --- */

.swth-view--list-table .swth-event {
    position: relative;
    display: flex;
    align-items: stretch;
    padding: var(--swth-card-padding-top) var(--swth-card-padding-right) var(--swth-card-padding-bottom) var(--swth-card-padding-left);
    width: 100%;
    align-self: stretch;
    background: var(--swth-card-bg);
    border-radius: var(--swth-card-border-radius);
    box-shadow: var(--swth-card-box-shadow);
    isolation: isolate;
}

/* --- Column dividers (pseudo-element) --- */

.swth-view--list-table .swth-event::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: var(--swth-card-padding-left);
    right: var(--swth-card-padding-right);
    background-image:
        linear-gradient(180deg, rgba(250, 175, 0, 0) 0%, var(--swth-divider-color) 50%, rgba(250, 175, 0, 0) 100%),
        linear-gradient(180deg, rgba(250, 175, 0, 0) 0%, var(--swth-divider-color) 50%, rgba(250, 175, 0, 0) 100%),
        linear-gradient(180deg, rgba(250, 175, 0, 0) 0%, var(--swth-divider-color) 50%, rgba(250, 175, 0, 0) 100%);
    background-repeat: no-repeat;
    background-size: var(--swth-divider-width) max(56px, calc(100% - 128px));
    background-position:
        25% center,
        50% center,
        75% center;
    pointer-events: none;
    opacity: 0.6;
    z-index: 0;
}

/* Ensure content sits above dividers */
.swth-view--list-table .swth-header,
.swth-view--list-table .swth-body,
.swth-view--list-table .swth-date,
.swth-view--list-table .swth-title,
.swth-view--list-table .swth-cell--asset,
.swth-view--list-table .swth-cell--status,
.swth-view--list-table .swth-body-heading {
    position: relative;
    z-index: 1;
}

/* --- Header --- */

.swth-view--list-table .swth-header {
    flex: 0 0 50%;
    display: flex;
    align-items: stretch;
    border-style: var(--swth-header-border-style);
    border-width: var(--swth-header-border-width);
    border-color: var(--swth-header-border-color);
}

/* --- Date & Title --- */

.swth-view--list-table .swth-date,
.swth-view--list-table .swth-title {
    flex: 0 0 50%;
    padding-inline: 16px;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--swth-date-color);
    font-family: var(--swth-date-font-family);
    font-size: var(--swth-date-font-size);
    font-weight: var(--swth-date-font-weight);
    line-height: var(--swth-date-line-height);
    text-transform: var(--swth-date-text-transform);
    letter-spacing: var(--swth-date-letter-spacing);
}

.swth-view--list-table .swth-title {
    color: var(--swth-title-color);
    font-family: var(--swth-title-font-family);
    font-size: var(--swth-title-font-size);
    font-weight: var(--swth-title-font-weight);
    line-height: var(--swth-title-line-height);
    text-transform: var(--swth-title-text-transform);
    letter-spacing: var(--swth-title-letter-spacing);
}

/* --- Body --- */

.swth-view--list-table .swth-body {
    flex: 0 0 50%;
    display: flex;
    flex-wrap: wrap;
    width: 100%;
    row-gap: 10px;
}

/* --- Body headings --- */

.swth-view--list-table .swth-body-heading {
    display: none;
    font-family: var(--swth-head-label-font-family);
    font-size: 16px;
    font-weight: 700;
    line-height: 22px;
}

/* --- Cells --- */

.swth-view--list-table .swth-cell--asset,
.swth-view--list-table .swth-cell--status {
    margin: 0;
    padding-inline: 16px;
}

.swth-view--list-table .swth-cell--asset {
    flex: 0 0 50%;
    color: var(--swth-asset-color);
    font-family: var(--swth-asset-font-family);
    font-size: var(--swth-asset-font-size);
    font-weight: var(--swth-asset-font-weight);
    line-height: var(--swth-asset-line-height);
    text-transform: var(--swth-asset-text-transform);
    letter-spacing: var(--swth-asset-letter-spacing);
    text-align: center;
}

.swth-view--list-table .swth-cell--status {
    flex: 0 0 50%;
    font-family: var(--swth-status-font-family);
    font-size: var(--swth-status-font-size);
    font-weight: var(--swth-status-font-weight);
    line-height: var(--swth-status-line-height);
    text-transform: var(--swth-status-text-transform);
    letter-spacing: var(--swth-status-letter-spacing);
    text-align: center;
}

/* --- Spacer --- */

.swth-view--list-table .swth-event--spacer .swth-date,
.swth-view--list-table .swth-event--spacer .swth-title,
.swth-view--list-table .swth-event--spacer .swth-cell--asset,
.swth-view--list-table .swth-event--spacer .swth-cell--status,
.swth-view--list-table .swth-event--spacer .swth-body-heading {
    visibility: hidden;
}

/* ==========================================================================
   6. Status Badges
   ========================================================================== */

.swth-status {
    display: inline-flex;
    align-items: center;
    border-radius: var(--swth-badge-border-radius);
    padding: var(--swth-badge-padding-top) var(--swth-badge-padding-right) var(--swth-badge-padding-bottom) var(--swth-badge-padding-left);
    line-height: var(--swth-status-line-height);
    font-family: var(--swth-status-font-family);
    font-size: var(--swth-status-font-size);
    font-weight: var(--swth-status-font-weight);
    text-transform: var(--swth-status-text-transform);
    letter-spacing: var(--swth-status-letter-spacing);
    background: var(--swth-status-default-bg);
    color: var(--swth-status-default-text);
}

.swth-status--open {
    background: var(--swth-status-open-bg);
    color: var(--swth-status-open-text);
}

.swth-status--closed {
    background: var(--swth-status-closed-bg);
    color: var(--swth-status-closed-text);
}

.swth-status--early-close {
    background: var(--swth-status-early-close-bg);
    color: var(--swth-status-early-close-text);
}

/* ==========================================================================
   7. Empty State
   ========================================================================== */

.swth-empty {
    color: var(--swth-empty-color);
    font-family: var(--swth-empty-font-family);
    font-size: var(--swth-empty-font-size);
    font-weight: var(--swth-empty-font-weight);
    line-height: var(--swth-empty-line-height);
    text-transform: var(--swth-empty-text-transform);
    letter-spacing: var(--swth-empty-letter-spacing);
    text-align: center;
    padding-bottom: 8px;
}

/* ==========================================================================
   8. Responsive: Laptop (max-width: 1440px)
   ========================================================================== */

@media (max-width: 1440px) {

    /* List-table: scale down text */
    .swth-view--list-table .swth-date,
    .swth-view--list-table .swth-title {
        font-size: 20px;
    }

    .swth-view--list-table .swth-cell--asset,
    .swth-view--list-table .swth-cell--status {
        font-size: 15px;
        line-height: 25px;
    }
}

/* ==========================================================================
   9. Responsive: Tablet (max-width: 1024px)
   ========================================================================== */

@media (max-width: 1024px) {

    /* ----- Card Table: Tablet ----- */

    .swth-view--card-table .swth-card {
        padding: 28px;
        border-radius: 20px;
    }

    .swth-view--card-table .swth-date {
        font-size: var(--swth-date-font-size-tablet, var(--swth-date-font-size));
    }

    .swth-view--card-table .swth-title {
        font-size: var(--swth-title-font-size-tablet, var(--swth-title-font-size));
    }

    /* Collapse to single column */
    .swth-view--card-table .swth-head-border {
        grid-template-columns: 1fr;
    }

    .swth-view--card-table .swth-head-border > div:nth-child(n + 2) {
        display: none;
    }

    .swth-view--card-table .swth-row-group {
        grid-template-columns: 1fr;
    }

    /* ----- List Grid: Tablet ----- */

    .swth-view--list-grid .swth-event {
        display: flex;
        flex-direction: column;
        border-radius: var(--swth-card-border-radius);
        overflow: hidden;
        box-shadow: 0 12px 18px 1px rgba(0, 0, 0, 0.08);
    }

    .swth-view--list-grid .swth-event--first,
    .swth-view--list-grid .swth-event--last {
        border-radius: var(--swth-card-border-radius);
    }

    .swth-view--list-grid .swth-event--last.swth-event--spacer {
        display: none;
    }

    .swth-view--list-grid .swth-header {
        display: flex;
        flex-direction: column;
        width: 100%;
        flex: 0 0 auto;
    }

    .swth-view--list-grid .swth-date,
    .swth-view--list-grid .swth-title {
        padding: 12px 20px;
        width: 100%;
        text-align: left;
        font-size: 16px;
        font-weight: 700;
        line-height: 26px;
    }

    .swth-view--list-grid .swth-date {
        display: grid;
        grid-template-columns: 1fr 1fr;
        align-items: center;
        gap: 12px;
        background: var(--swth-card-date-bg);
        justify-content: flex-start;
    }

    .swth-view--list-grid .swth-date::before {
        content: attr(data-label);
        font-weight: 700;
    }

    .swth-view--list-grid .swth-title {
        background: #f4f9fe;
        font-weight: 700;
        justify-content: flex-start;
    }

    .swth-view--list-grid .swth-body {
        display: grid;
        grid-template-columns: 1fr 1fr;
        width: 100%;
        padding: 12px 20px 20px;
        column-gap: 16px;
        row-gap: 12px;
        background: var(--swth-card-bg);
        flex: 0 0 auto;
        align-items: stretch;
    }

    .swth-view--list-grid .swth-body-headings {
        display: grid;
        grid-template-columns: 1fr 1fr;
        grid-column: 1 / -1;
    }

    .swth-view--list-grid .swth-body-heading {
        display: block;
        font-size: 16px;
        line-height: 26px;
    }

    .swth-view--list-grid .swth-cell--asset,
    .swth-view--list-grid .swth-cell--status {
        padding: 0;
        font-size: 16px;
        line-height: 26px;
        font-weight: 400;
        text-align: left;
        flex: none;
    }

    /* ----- List Table: Tablet ----- */

    .swth-view--list-table {
        gap: 55px;
    }

    .swth-view--list-table .swth-table-header {
        display: none;
    }

    .swth-view--list-table .swth-event {
        display: flex;
        flex-direction: column;
        width: 100%;
        padding: 57px 0;
        border-radius: 48px;
        box-shadow: 0px 18px 20px 1px #b5d8e7;
    }

    .swth-view--list-table .swth-event::before {
        display: none;
    }

    .swth-view--list-table .swth-header {
        flex: 0 0 auto;
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        text-align: start;
    }

    .swth-view--list-table .swth-date {
        display: grid;
        grid-template-columns: 1fr 1fr;
        align-items: center;
        gap: 12px;
        width: 100%;
        justify-content: flex-start;
        padding: 10px 30px;
        background: var(--swth-card-date-bg);
        font-size: 15px;
        line-height: 25px;
        text-align: left;
    }

    .swth-view--list-table .swth-date::before {
        content: attr(data-label);
        font-weight: 500;
    }

    .swth-view--list-table .swth-title {
        flex: 0 0 auto;
        width: 100%;
        justify-content: flex-start;
        padding: 10px 30px;
        background: #f4fbff;
        font-size: 15px;
        line-height: 25px;
        font-weight: 700;
        text-align: start;
    }

    .swth-view--list-table .swth-body {
        display: grid;
        grid-template-columns: 1fr 1fr;
        flex: 0 0 auto;
        width: 100%;
        padding: 10px 30px;
        column-gap: 16px;
        row-gap: 10px;
    }

    .swth-view--list-table .swth-body-heading {
        display: block;
        font-size: 15px;
        line-height: 25px;
        font-weight: 500;
        text-align: start;
    }

    .swth-view--list-table .swth-body-heading--status {
        visibility: hidden;
    }

    .swth-view--list-table .swth-cell--asset,
    .swth-view--list-table .swth-cell--status {
        font-size: 15px;
        line-height: 25px;
        font-weight: 400;
        text-align: start;
        background: #ffffff;
        padding: 12px 0 4px;
        flex: 0 0 auto;
        width: auto;
    }
}

/* ==========================================================================
   10. Responsive: Mobile (max-width: 767px)
   ========================================================================== */

@media (max-width: 767px) {

    /* ----- Card Table: Mobile ----- */

    .swth-view--card-table .swth-card {
        padding: 0 25px;
    }

    .swth-view--card-table .swth-date {
        font-size: var(--swth-date-font-size-mobile, var(--swth-date-font-size-tablet, var(--swth-date-font-size)));
    }

    .swth-view--card-table .swth-title {
        font-size: var(--swth-title-font-size-mobile, var(--swth-title-font-size-tablet, var(--swth-title-font-size)));
    }

    .swth-view--card-table .swth-header {
        flex-direction: column;
        gap: 0;
        border-radius: 16px;
    }

    .swth-view--card-table .swth-head-label {
        font-size: 18px;
    }

    .swth-view--card-table .swth-cell--asset {
        font-size: 17px;
    }

    .swth-view--card-table .swth-cell--status {
        font-size: 15px;
    }

    /* ----- List Grid: Mobile ----- */

    .swth-view--list-grid .swth-event {
        box-shadow: 0 10px 14px 1px rgba(0, 0, 0, 0.07);
    }

    .swth-view--list-grid .swth-date,
    .swth-view--list-grid .swth-title {
        font-size: 15px;
        line-height: 25px;
    }

    .swth-view--list-grid .swth-date {
        grid-template-columns: 1fr auto;
    }

    .swth-view--list-grid .swth-body {
        row-gap: 14px;
    }

    .swth-view--list-grid .swth-body-heading,
    .swth-view--list-grid .swth-cell--asset,
    .swth-view--list-grid .swth-cell--status {
        font-size: 15px;
        line-height: 25px;
    }

    /* ----- List Table: Mobile ----- */

    .swth-view--list-table {
        gap: 15px;
    }

    .swth-view--list-table .swth-event {
        box-shadow: 0px 14px 16px 1px #b5d8e7;
    }

    .swth-view--list-table .swth-body {
        row-gap: 12px;
        column-gap: 16px;
    }
}
