/* ===========================
   Code & Rules Page — The ADR Initiative
   =========================== */

/* ── Hero ─────────────────────────────────────────────────── */

.cr-hero {
    background-color: var(--color-white);
    padding: 80px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cr-hero::before {
    content: '';
    position: absolute;
    top: -50px;
    left: -60px;
    width: 340px;
    height: 340px;
    background-image: radial-gradient(circle, rgba(87, 7, 102, 0.40) 3px, transparent 3px);
    background-size: 24px 24px;
    -webkit-mask-image: radial-gradient(ellipse 60% 60% at 32% 34%, black 26%, rgba(0,0,0,0.30) 52%, transparent 74%);
    mask-image:         radial-gradient(ellipse 60% 60% at 32% 34%, black 26%, rgba(0,0,0,0.30) 52%, transparent 74%);
    pointer-events: none;
    z-index: 0;
}

.cr-hero::after {
    content: '';
    position: absolute;
    bottom: -80px;
    right: -80px;
    width: 280px;
    height: 280px;
    border-radius: 50%;
    border: 2px dashed rgba(87, 7, 102, 0.14);
    pointer-events: none;
    z-index: 0;
    animation: deco-spin-slow 26s linear infinite;
}

.cr-hero-title {
    font-family: var(--font-heading);
    font-size: clamp(28px, 4vw, 48px);
    font-weight: 500;
    color: var(--color-black);
    line-height: 1.2;
    margin: 0 0 20px;
}

.cr-hero-subtitle {
    font-family: var(--font-body);
    font-size: clamp(15px, 2vw, 17px);
    color: var(--color-text);
    line-height: 1.75;
    max-width: 620px;
    margin: 0 auto;
}

/* ── Section 2 — Rules & Code of Conduct ─────────────────── */

.cr-rules {
    background-color: var(--color-bg-light);
    padding: 80px 0;
}

.cr-rules-inner {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 60px;
    align-items: center;
}

.cr-rules-content .section-label {
    display: block;
    margin-bottom: 12px;
}

.cr-rules-title {
    font-family: var(--font-heading);
    font-size: clamp(24px, 3vw, 38px);
    font-weight: 700;
    color: var(--color-black);
    line-height: 1.25;
    margin: 0 0 20px;
}

.cr-rules-desc {
    font-family: var(--font-body);
    font-size: 16px;
    color: var(--color-text);
    line-height: 1.8;
    margin: 0 0 32px;
    max-width: 560px;
}

.cr-rules-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

/* ── Decorative Circles ───────────────────────────────────── */

.cr-rules-deco {
    display: flex;
    align-items: center;
    justify-content: center;
}

.cr-circles {
    position: relative;
    width: 260px;
    height: 220px;
}

.cr-circle {
    position: absolute;
    border-radius: 50%;
    border: 2px solid var(--color-primary);
    opacity: 0.75;
}

.cr-circle--1 {
    width: 160px;
    height: 160px;
    top: 0;
    left: 0;
}

.cr-circle--2 {
    width: 160px;
    height: 160px;
    top: 0;
    left: 80px;
}

.cr-circle--3 {
    width: 160px;
    height: 160px;
    top: 55px;
    left: 40px;
}

/* ── Section 3 — Our Fees ─────────────────────────────────── */

.cr-fees {
    background-color: var(--color-white);
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}

.cr-fees::before {
    content: '';
    position: absolute;
    top: -80px;
    right: -80px;
    width: 380px;
    height: 380px;
    border-radius: 50%;
    background: radial-gradient(ellipse at center, rgba(87, 7, 102, 0.07) 0%, rgba(87, 7, 102, 0.03) 45%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.cr-fees::after {
    content: '';
    position: absolute;
    bottom: -60px;
    left: -60px;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: radial-gradient(
        circle,
        transparent 22%, rgba(87, 7, 102, 0.13) 22%, rgba(87, 7, 102, 0.13) 27%, transparent 27%,
        transparent 38%, rgba(87, 7, 102, 0.09) 38%, rgba(87, 7, 102, 0.09) 43%, transparent 43%,
        transparent 54%, rgba(87, 7, 102, 0.05) 54%, rgba(87, 7, 102, 0.05) 59%, transparent 59%
    );
    pointer-events: none;
    z-index: 0;
}

.cr-fees-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.cr-fees-line {
    width: 40px;
    height: 3px;
    background: var(--color-black);
    margin-bottom: 20px;
}

.cr-fees-title {
    font-family: var(--font-heading);
    font-size: clamp(28px, 3.5vw, 44px);
    font-weight: 700;
    color: var(--color-black);
    line-height: 1.2;
    margin: 0;
}

.cr-fees-desc {
    font-family: var(--font-body);
    font-size: 16px;
    color: var(--color-text);
    line-height: 1.8;
    margin: 0 0 28px;
}

/* ── Responsive ───────────────────────────────────────────── */

@media (max-width: 1024px) {
    .cr-rules-inner {
        grid-template-columns: 1fr 300px;
        gap: 40px;
    }

    .cr-circles {
        width: 200px;
        height: 180px;
    }

    .cr-circle {
        width: 130px;
        height: 130px;
    }

    .cr-circle--2 { left: 60px; }
    .cr-circle--3 { top: 44px; left: 30px; }
}

@media (max-width: 768px) {
    .cr-hero,
    .cr-rules,
    .cr-fees {
        padding: 60px 0;
    }

    .cr-rules-inner {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .cr-rules-deco {
        order: -1;
    }

    .cr-fees-inner {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .cr-rules-btns {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 480px) {
    .cr-hero,
    .cr-rules,
    .cr-fees {
        padding: 48px 0;
    }

    .cr-circles {
        width: 160px;
        height: 140px;
    }

    .cr-circle {
        width: 100px;
        height: 100px;
    }

    .cr-circle--2 { left: 48px; }
    .cr-circle--3 { top: 34px; left: 24px; }
}

@media (max-width: 768px) {
    .cr-hero::before,  .cr-hero::after,
    .cr-fees::before,  .cr-fees::after {
        display: none;
    }
}
