/**
 * Shared styles for the assigned Kayan pages.
 * OWNER: Team lead only.
 * Page developers must put their styles in their assigned page CSS file.
 */

.kayan-page {
    --kayan-page-primary: #8d1126;
    --kayan-page-primary-dark: #75222f;
    --kayan-page-primary-soft: #f6ecee;
    --kayan-page-text: #1b1f2e;
    --kayan-page-muted: #7a7a7a;
    --kayan-page-background: #ffffff;
    --kayan-page-surface: #f6f7f9;
    --kayan-page-border: #e8e8e8;
    --kayan-page-radius: 30px;
    --kayan-page-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    direction: rtl;
    color: var(--kayan-page-text);
    background: var(--kayan-page-background);
    font-family: "Cairo", sans-serif;
    font-size: 16px;
    line-height: 1.9;
    text-align: right;
    overflow: hidden;
}

.kayan-page *,
.kayan-page *::before,
.kayan-page *::after {
    box-sizing: border-box;
}

.kayan-page__container {
    width: min(1200px, calc(100% - 48px));
    margin-inline: auto;
    padding-block: 80px;
}

.kayan-page__title {
    position: relative;
    margin: 0 0 40px;
    padding-bottom: 18px;
    color: var(--kayan-page-primary);
    font-size: clamp(2rem, 4.5vw, 3.25rem);
    font-weight: 800;
    line-height: 1.3;
}

.kayan-page__title::after,
.kayan-section__title::after {
    position: absolute;
    right: 0;
    bottom: 0;
    width: 72px;
    height: 4px;
    border-radius: 999px;
    background: var(--kayan-page-primary);
    content: "";
}

.kayan-page__content {
    color: var(--kayan-page-text);
    font-size: 1.05rem;
    line-height: 1.9;
}

.kayan-page__content > :first-child {
    margin-top: 0;
}

.kayan-page__content > :last-child {
    margin-bottom: 0;
}

.kayan-page p {
    margin: 0 0 1.25em;
}

.kayan-page a {
    color: var(--kayan-page-primary);
}

.kayan-page__content img {
    max-width: 100%;
    height: auto;
    border-radius: var(--kayan-page-radius);
}

/* Reusable section */
.kayan-section {
    position: relative;
    padding-block: 80px;
}

.kayan-section--light {
    background: var(--kayan-page-surface);
}

.kayan-section--burgundy {
    color: #fff;
    background: var(--kayan-page-primary);
}

.kayan-section__inner {
    width: min(1200px, calc(100% - 48px));
    margin-inline: auto;
}

.kayan-section__eyebrow {
    display: block;
    margin-bottom: 10px;
    color: var(--kayan-page-primary);
    font-size: 0.9rem;
    font-weight: 800;
}

.kayan-section__title {
    position: relative;
    margin: 0 0 32px;
    padding-bottom: 16px;
    color: var(--kayan-page-text);
    font-size: clamp(1.65rem, 3vw, 2.5rem);
    font-weight: 800;
    line-height: 1.4;
}

.kayan-section--burgundy .kayan-section__title,
.kayan-section--burgundy .kayan-section__eyebrow {
    color: #fff;
}

.kayan-section--burgundy .kayan-section__title::after {
    background: #fff;
}

/* Hero */
.kayan-hero {
    position: relative;
    min-height: 420px;
    display: grid;
    place-items: center;
    padding-block: 96px;
    color: #fff;
    background-color: var(--kayan-page-primary-dark);
    background-position: center;
    background-size: cover;
    isolation: isolate;
}

.kayan-hero::before {
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(90deg, rgba(94, 1, 0, 0.88), rgba(141, 17, 38, 0.58));
    content: "";
}

.kayan-hero__content {
    width: min(1200px, calc(100% - 48px));
    margin-inline: auto;
}

.kayan-hero__title {
    max-width: 850px;
    margin: 0 0 18px;
    color: #fff;
    font-size: clamp(2.25rem, 5vw, 4.25rem);
    font-weight: 900;
    line-height: 1.25;
}

.kayan-hero__text {
    max-width: 720px;
    margin: 0;
    color: rgba(255, 255, 255, 0.92);
    font-size: clamp(1rem, 2vw, 1.25rem);
}

/* Grids and cards */
.kayan-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.kayan-grid--two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.kayan-card {
    height: 100%;
    padding: 32px;
    border: 1px solid var(--kayan-page-border);
    border-radius: var(--kayan-page-radius);
    background: #fff;
    box-shadow: var(--kayan-page-shadow);
    transition: transform 180ms ease, box-shadow 180ms ease;
}

.kayan-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 38px rgba(0, 0, 0, 0.13);
}

.kayan-card__title {
    margin: 0 0 14px;
    color: var(--kayan-page-primary);
    font-size: 1.35rem;
    font-weight: 800;
    line-height: 1.5;
}

.kayan-card__text {
    margin: 0;
    color: var(--kayan-page-muted);
}

/* Two-column content and media */
.kayan-split {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: center;
    gap: clamp(32px, 6vw, 72px);
}

.kayan-media {
    display: block;
    width: 100%;
    height: auto;
    border-radius: var(--kayan-page-radius);
    box-shadow: var(--kayan-page-shadow);
}

/* Buttons */
.kayan-button {
    display: inline-flex;
    min-height: 50px;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 28px;
    border: 2px solid var(--kayan-page-primary);
    border-radius: 12px;
    color: #fff !important;
    background: var(--kayan-page-primary);
    font-family: inherit;
    font-weight: 700;
    line-height: 1.4;
    text-decoration: none !important;
    transition: color 180ms ease, background 180ms ease, transform 180ms ease;
}

.kayan-button:hover,
.kayan-button:focus-visible {
    color: #fff !important;
    background: var(--kayan-page-primary-dark);
    border-color: var(--kayan-page-primary-dark);
    transform: translateY(-2px);
}

.kayan-button--outline {
    color: var(--kayan-page-primary) !important;
    background: transparent;
}

.kayan-button--outline:hover,
.kayan-button--outline:focus-visible {
    color: #fff !important;
}

/* Lists, quotations, and small accents */
.kayan-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.kayan-list li {
    position: relative;
    margin-bottom: 14px;
    padding-right: 28px;
}

.kayan-list li::before {
    position: absolute;
    top: 0.7em;
    right: 0;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--kayan-page-primary);
    content: "";
    transform: translateY(-50%);
}

.kayan-quote {
    margin: 32px 0;
    padding: 28px 32px;
    border: 0;
    border-right: 5px solid var(--kayan-page-primary);
    border-radius: 16px;
    color: var(--kayan-page-text);
    background: var(--kayan-page-primary-soft);
    font-size: 1.15rem;
    font-weight: 600;
}

.kayan-text-center {
    text-align: center;
}

.kayan-text-center .kayan-section__title::after {
    right: 50%;
    transform: translateX(50%);
}

@media (max-width: 1024px) {
    .kayan-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .kayan-page__container {
        width: min(100% - 32px, 1200px);
        padding-block: 48px;
    }

    .kayan-section {
        padding-block: 56px;
    }

    .kayan-section__inner,
    .kayan-hero__content {
        width: min(100% - 32px, 1200px);
    }

    .kayan-hero {
        min-height: 340px;
        padding-block: 72px;
    }

    .kayan-grid,
    .kayan-grid--two,
    .kayan-split {
        grid-template-columns: 1fr;
    }

    .kayan-card {
        padding: 24px;
        border-radius: 22px;
    }

    .kayan-media {
        border-radius: 22px;
    }

    .kayan-button {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .kayan-card,
    .kayan-button {
        transition: none;
    }
}
