/* =========================================================
   MOSKADASTR SHARED COMPONENTS

   Purpose:
   - reusable visual components shared by modern pages
   - no page layout ownership
   - no header/footer ownership
   - no legacy overrides unless explicitly documented

   Load order:
   mkadastr.css
   -> mkadastr-foundation.css
   -> mkadastr-layout.css
   -> mkadastr-shell.css
   -> mkadastr-components.css
   -> page-specific CSS

   E1a creates the layer only.
   Visual component rules will be migrated in later atomic steps.
   ========================================================= */

/* =========================================================
   CONTENT SECTION HEADING - E1b
   Shared H2 for modern content/service sections.
   ========================================================= */

.content h2.mk-content-heading {
    margin: 0 0 18px;
    padding: 10px 16px;
    background: #f7f9fa;
    border-left: 5px solid #1b78a0;
    border-radius: 4px;
    color: #222222;
    font-size: 28px;
    line-height: 1.25;
    font-weight: normal;
    text-align: left;
}

@media (max-width: 768px) {
    .content h2.mk-content-heading {
        margin-bottom: 14px;
        padding: 10px 14px;
        font-size: 24px;
        line-height: 1.25;
    }
}

/* =========================================================
   SHARED BUTTONS - E2a
   Reusable primary / secondary actions for modern content.
   ========================================================= */

.content .mk-button-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.content .mk-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 11px 17px;
    box-sizing: border-box;
    border: 1px solid transparent;
    border-radius: 7px;
    font-size: 16px;
    line-height: 1.3;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition:
        background-color 0.18s ease,
        border-color 0.18s ease,
        color 0.18s ease;
}

.content .mk-button:hover,
.content .mk-button:focus {
    text-decoration: none;
}

.content .mk-button--primary {
    background: #1b78a0;
    border-color: #1b78a0;
    color: #ffffff;
}

.content .mk-button--primary:hover,
.content .mk-button--primary:focus {
    background: #145f80;
    border-color: #145f80;
    color: #ffffff;
}

.content .mk-button--secondary {
    background: #ffffff;
    border-color: #1b78a0;
    color: #1b78a0;
}

.content .mk-button--secondary:hover,
.content .mk-button--secondary:focus {
    background: #eef7fb;
    border-color: #1b78a0;
    color: #145f80;
}

@media (max-width: 768px) {
    .content .mk-button-group {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .content .mk-button {
        width: 100%;
    }
}

/* =========================================================
   SHARED CONTENT CARD - E3a
   Reusable bordered content block for modern pages.
   ========================================================= */

.content .mk-content-card {
    margin: 0 0 16px 0;
    padding: 18px 22px;
    background: #ffffff;
    border: 1px solid #e6e6e6;
    border-left: 5px solid #1b78a0;
    border-radius: 10px;
    box-shadow: 0 3px 14px rgba(0, 0, 0, 0.05);
}

.content .mk-content-card__title {
    margin: 0 0 10px 0;
    color: #1b78a0;
    font-size: 21px;
    line-height: 1.3;
    font-weight: 700;
    text-align: left;
}

.content .mk-content-card p {
    margin: 0 0 12px 0;
    color: #333333;
    font-size: 16px;
    line-height: 1.6;
    text-align: left;
}

.content .mk-content-card p:last-child {
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .content .mk-content-card {
        margin-bottom: 14px;
        padding: 14px 15px 16px 15px;
        border-left-width: 4px;
    }

    .content .mk-content-card__title {
        font-size: 19px;
        line-height: 1.3;
    }

    .content .mk-content-card p {
        font-size: 15px;
        line-height: 1.5;
    }
}

/* =========================================================
   SHARED PRICE GRID - E4a
   Two-column pricing matrix used by modern service pages.
   This is intentionally separate from semantic HTML tables.
   ========================================================= */

.content .mk-price-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin: 0;
}

.content .mk-price-grid__panel {
    overflow: hidden;
    min-width: 0;
    background: #ffffff;
    border: 1px solid #dfe7ea;
    border-radius: 10px;
    box-shadow: 0 3px 14px rgba(0, 0, 0, 0.04);
}

.content .mk-price-grid__head,
.content .mk-price-grid__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(160px, 0.58fr);
    align-items: center;
}

.content .mk-price-grid__head {
    background: #f7f9fa;
    border-bottom: 1px solid #dfe7ea;
}

.content .mk-price-grid__head > * {
    padding: 13px 16px;
    color: #405763;
    font-size: 15px;
    line-height: 1.35;
    font-weight: 700;
}

.content .mk-price-grid__row {
    border-bottom: 1px solid #e7ecef;
}

.content .mk-price-grid__row:last-child {
    border-bottom: 0;
}

.content .mk-price-grid__row:nth-child(odd) {
    background: #fbfcfc;
}

.content .mk-price-grid__label,
.content .mk-price-grid__value {
    min-width: 0;
    padding: 13px 16px;
    font-size: 16px;
    line-height: 1.4;
}

.content .mk-price-grid__label {
    color: #333333;
}

.content .mk-price-grid__value {
    color: #1b78a0;
    font-weight: 700;
    white-space: nowrap;
}

.content .mk-price-grid__value--wrap {
    white-space: normal;
}

@media (max-width: 768px) {
    .content .mk-price-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .content .mk-price-grid__panel {
        overflow: visible;
        background: transparent;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    .content .mk-price-grid__head {
        display: none;
    }

    .content .mk-price-grid__row {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        margin: 0 0 8px 0;
        padding: 13px 14px;
        background: #ffffff;
        border: 1px solid #e0e7ea;
        border-left: 5px solid #1b78a0;
        border-radius: 8px;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    }

    .content .mk-price-grid__row:nth-child(odd) {
        background: #ffffff;
    }

    .content .mk-price-grid__label,
    .content .mk-price-grid__value {
        padding: 0;
        font-size: 16px;
    }

    .content .mk-price-grid__value {
        flex: 0 1 auto;
        text-align: right;
        white-space: normal;
    }
}
