/**
 * RAVIDEX 1.4 — final visual system
 *
 * This layer intentionally comes last. It consolidates typography, spacing,
 * approved photography, gallery behaviour and the RAVIDEX brand system
 * without rewriting the legacy stylesheet.
 */

/*
 * Estedad is distributed under the SIL Open Font License 1.1.
 * The complete license is bundled at assets/fonts/estedad/OFL.txt.
 */
@font-face {
    font-family: "Estedad";
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
    src: url("../fonts/estedad/Estedad-wght.woff2") format("woff2");
}

:root {
    --rv-color-cream: #fbf7ef;
    --rv-section-space: 84px;
    --rv-font-family: "Estedad", Tahoma, Arial, sans-serif;
}

body,
button,
input,
select,
textarea,
h1,
h2,
h3,
h4,
h5,
h6,
p,
a,
li,
span,
label,
blockquote,
.rv-brand-meaning__english,
.rv-brand-story__formula,
.rv-brand-pillar__mark,
.rv-brand-pillar__english {
    font-family: var(--rv-font-family);
}

/* Brand assets */

.rv-brand__logo,
.rv-footer-logo {
    display: inline-flex;
    align-items: center;
}

.rv-brand__logo img {
    display: block;
    width: clamp(172px, 14.5vw, 205px);
    height: auto;
    border-radius: 9px;
    box-shadow: 0 7px 18px rgba(15, 23, 42, 0.14);
}

.rv-footer-logo {
    margin-bottom: 19px;
}

.rv-footer-logo img {
    display: block;
    width: min(100%, 300px);
    height: auto;
    border-radius: 12px;
}

.rv-footer-brandline {
    margin-top: 11px !important;
    color: var(--rv-color-secondary) !important;
    font-size: 0.84rem !important;
    font-weight: 800;
}

.rv-header--compact .rv-brand__logo img {
    width: 168px;
}

.rv-lighthouse-brand {
    display: block;
    width: min(100%, 420px);
    height: auto;
    margin: 0 0 24px;
}

/* Calm cream/white rhythm and consistent section spacing */

.rv-approach,
.rv-home-tools,
.rv-home-experience,
.rv-about-intro,
.rv-experience,
.rv-events,
.rv-about-values,
.rv-sp-intro,
.rv-sp-process,
.rv-wp-intro,
.rv-wp-method,
.rv-pp-about,
.rv-pp-topics,
.rv-lp-problem,
.rv-lp-use,
.rv-contact-main,
.rv-ip-intro,
.rv-ip-articles {
    background: var(--rv-color-cream);
}

.rv-why-v2,
.rv-services-v2,
.rv-workshops-v2,
.rv-brand-story,
.rv-sp-services,
.rv-sp-models,
.rv-wp-programs,
.rv-pp-season,
.rv-lp-principles,
.rv-ip-topics {
    background: #ffffff;
}

.rv-approach,
.rv-why-v2,
.rv-services-v2,
.rv-workshops-v2,
.rv-home-experience,
.rv-home-tools,
.rv-insights,
.rv-brand-story,
.rv-about-intro,
.rv-experience,
.rv-events,
.rv-about-values,
.rv-sp-intro,
.rv-sp-services,
.rv-sp-process,
.rv-sp-models,
.rv-wp-intro,
.rv-wp-programs,
.rv-wp-method,
.rv-wp-audience,
.rv-pp-about,
.rv-pp-season,
.rv-pp-topics,
.rv-lp-problem,
.rv-lp-principles,
.rv-lp-use,
.rv-contact-main,
.rv-ip-intro,
.rv-ip-articles,
.rv-ip-topics {
    padding-top: var(--rv-section-space);
    padding-bottom: var(--rv-section-space);
}

.rv-card,
.rv-challenge-card,
.rv-service-card,
.rv-workshop-card,
.rv-home-tool,
.rv-insight-card,
.rv-brand-pillar,
.rv-experience-card,
.rv-about-values__grid article,
.rv-sp-service,
.rv-sp-process__grid article,
.rv-wp-program,
.rv-wp-method__grid article,
.rv-pp-episode,
.rv-pp-topics__grid article,
.rv-lp-problem__cards article,
.rv-lp-principles__grid article,
.rv-ip-card {
    background-color: #ffffff;
}

/* About hero: portrait and founder context are visible above the fold. */

.rv-about-hero {
    min-height: auto;
    padding: 66px 0;
    background:
        radial-gradient(circle at 10% 18%, rgba(20, 184, 166, 0.14), transparent 32%),
        linear-gradient(135deg, #071121, #11223b 62%, #182a45);
}

.rv-about-hero__grid {
    display: grid;
    grid-template-columns: minmax(270px, 0.72fr) minmax(0, 1.28fr);
    align-items: center;
    gap: clamp(42px, 6vw, 82px);
    direction: ltr;
}

.rv-about-hero__portrait {
    position: relative;
    width: min(100%, 360px);
    aspect-ratio: 928 / 1695;
    justify-self: center;
    margin: 0;
    overflow: hidden;
    background: #0b1930;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 24px;
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.38);
}

.rv-about-hero__portrait::after {
    position: absolute;
    inset: 12px;
    border: 1px solid rgba(245, 158, 11, 0.38);
    border-radius: 17px;
    content: "";
    pointer-events: none;
}

.rv-about-hero__portrait img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.rv-about-hero__content {
    max-width: 720px;
    direction: rtl;
}

.rv-about-hero__eyebrow {
    margin: 0 0 16px;
    color: var(--rv-color-secondary);
    font-size: 0.88rem;
    font-weight: 800;
}

.rv-about-hero__content h1 {
    margin: 0 0 20px;
    color: #ffffff;
    font-size: clamp(2.25rem, 4.6vw, 4.4rem);
    line-height: 1.36;
}

.rv-about-hero__content h1 span {
    display: block;
    color: var(--rv-color-secondary);
}

.rv-about-hero__content > p:not(.rv-about-hero__eyebrow):not(.rv-about-hero__role) {
    max-width: 650px;
    margin: 0 0 18px;
    color: #dbe4ef;
    line-height: 2;
}

.rv-about-hero__role {
    margin: 0 0 25px;
    color: #ffffff;
    font-weight: 800;
}

#rv-about-story {
    scroll-margin-top: 105px;
}

/* Approved portrait on the home page. */

.rv-home-experience__grid {
    grid-template-columns: minmax(290px, 0.7fr) minmax(0, 1.3fr);
}

.rv-home-experience__media {
    width: min(100%, 430px);
    aspect-ratio: 4 / 5;
    justify-self: center;
}

.rv-home-experience__media img {
    object-position: center 8%;
}

/* Event highlights and horizontal gallery. */

.rv-events {
    overflow: hidden;
}

.rv-events__header {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.95fr);
    align-items: end;
    gap: 55px;
    margin-bottom: 36px;
}

.rv-events__header h2 {
    margin: 0;
    font-size: clamp(2rem, 4vw, 3.2rem);
}

.rv-events__header > p {
    margin: 0;
    color: var(--rv-color-text-soft);
    line-height: 2;
}

.rv-events__highlights {
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(250px, 0.7fr);
    align-items: start;
    gap: 20px;
    margin-bottom: 44px;
}

.rv-events__highlights figure,
.rv-gallery__slide {
    position: relative;
    margin: 0;
    overflow: hidden;
    background: var(--rv-color-primary);
    border-radius: 18px;
}

.rv-events__highlight--landscape {
    aspect-ratio: 16 / 9;
}

.rv-events__highlight--portrait {
    aspect-ratio: 3 / 4;
}

.rv-events__highlights figure::after,
.rv-gallery__slide::after {
    position: absolute;
    inset: 42% 0 0;
    background: linear-gradient(transparent, rgba(5, 13, 27, 0.9));
    content: "";
    pointer-events: none;
}

.rv-events__highlights img,
.rv-gallery__slide img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 550ms ease;
}

.rv-events__highlights figure:hover img,
.rv-gallery__slide:hover img,
.rv-gallery__slide:focus-within img {
    transform: scale(1.045);
}

.rv-events__highlights figcaption,
.rv-gallery__slide figcaption {
    position: absolute;
    z-index: 1;
    right: 22px;
    bottom: 18px;
    left: 22px;
    color: #ffffff;
    font-weight: 800;
    line-height: 1.8;
}

.rv-gallery {
    position: relative;
}

.rv-gallery__controls {
    display: flex;
    justify-content: flex-end;
    gap: 9px;
    margin-bottom: 14px;
}

.rv-gallery__controls button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    color: var(--rv-color-primary);
    background: #ffffff;
    border: 1px solid var(--rv-color-border);
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 900;
    transition: color 180ms ease, background-color 180ms ease, transform 180ms ease;
}

.rv-gallery__controls button:hover,
.rv-gallery__controls button:focus-visible {
    color: #ffffff;
    background: var(--rv-color-secondary-dark);
    transform: translateY(-2px);
}

.rv-gallery__viewport {
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    direction: ltr;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
}

.rv-gallery__viewport::-webkit-scrollbar {
    display: none;
}

.rv-gallery__track {
    display: flex;
    gap: 18px;
    direction: ltr;
}

.rv-gallery__slide {
    flex: 0 0 calc((100% - 36px) / 3);
    height: clamp(270px, 24vw, 340px);
    scroll-snap-align: start;
    direction: rtl;
    box-shadow: 0 15px 34px rgba(15, 23, 42, 0.12);
}

.rv-gallery__slide--portrait {
    flex-basis: clamp(220px, 22vw, 270px);
}

/* Workshops photography. */

.rv-wp-hero__visual {
    width: min(100%, 520px);
    aspect-ratio: 16 / 9;
    justify-self: center;
}

.rv-wp-hero__visual img {
    object-position: center;
}

.rv-wp-audience__visual {
    position: relative;
    aspect-ratio: 16 / 8.5;
    margin: 30px 0 0;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 18px;
}

.rv-wp-audience__visual::after {
    position: absolute;
    inset: 45% 0 0;
    background: linear-gradient(transparent, rgba(5, 13, 27, 0.92));
    content: "";
}

.rv-wp-audience__visual img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* The approved audience photograph was delivered upside down. Scope the
 * correction to this single asset so no other workshop image is affected. */
.rv-wp-audience__visual img.rv-image-rotate-180 {
    transform: rotate(180deg);
}

.rv-wp-audience__visual figcaption {
    position: absolute;
    z-index: 1;
    right: 20px;
    bottom: 15px;
    left: 20px;
    color: #ffffff;
    font-size: 0.86rem;
    font-weight: 800;
}

/* Podcast details: listeners know what they are about to hear. */

.rv-podcast-card__details,
.rv-pp-episode__details {
    display: grid;
    gap: 8px;
    padding: 16px 0 0;
    margin: 18px 0 0;
    border-top: 1px solid var(--rv-color-border);
    list-style: none;
}

.rv-podcast-card__details li,
.rv-pp-episode__details li {
    position: relative;
    padding-right: 15px;
    color: var(--rv-color-text-soft);
    font-size: 0.78rem;
    line-height: 1.8;
}

.rv-podcast-card__details li::before,
.rv-pp-episode__details li::before {
    position: absolute;
    top: 0.82em;
    right: 0;
    width: 6px;
    height: 6px;
    background: var(--rv-color-secondary);
    border-radius: 50%;
    content: "";
}

.rv-podcast-card__details strong,
.rv-pp-episode__details strong {
    color: var(--rv-color-primary);
}

.rv-podcast-card__body,
.rv-pp-episode__body {
    height: 100%;
}

@media (max-width: 991px) {
    :root {
        --rv-section-space: 60px;
    }

    .rv-about-hero__grid,
    .rv-home-experience__grid,
    .rv-events__header {
        grid-template-columns: minmax(0, 1fr);
    }

    .rv-about-hero__portrait {
        width: min(100%, 330px);
    }

    .rv-events__header {
        gap: 18px;
    }

    .rv-gallery__slide {
        flex-basis: calc((100% - 18px) / 2);
    }

    .rv-gallery__slide--portrait {
        flex-basis: clamp(220px, 32vw, 270px);
    }
}

@media (max-width: 767px) {
    :root {
        --rv-section-space: 48px;
    }

    .rv-brand__logo img,
    .rv-header--compact .rv-brand__logo img {
        width: 154px;
    }

    .rv-about-hero {
        padding: 48px 0;
    }

    .rv-about-hero__grid {
        gap: 34px;
    }

    .rv-about-hero__portrait {
        width: min(88%, 300px);
    }

    .rv-events__highlights {
        grid-template-columns: minmax(0, 1fr);
    }

    .rv-events__highlight--portrait {
        width: min(78%, 360px);
        justify-self: center;
    }

    .rv-gallery__slide {
        flex-basis: 88%;
        height: 310px;
    }

    .rv-gallery__slide--portrait {
        flex-basis: min(72%, 270px);
    }

    .rv-wp-hero__visual {
        width: min(100%, 520px);
        aspect-ratio: 16 / 9;
    }

    .rv-lighthouse-brand {
        width: min(100%, 330px);
    }
}

@media (prefers-reduced-motion: reduce) {
    .rv-gallery__viewport {
        scroll-behavior: auto;
    }

    .rv-events__highlights img,
    .rv-gallery__slide img {
        transition: none;
    }
}

/* Project Lighthouse framework: one deliberate, local contrast rule.
 * The framework uses a light surface, so every piece of copy is deep navy.
 * The scoped priority prevents Reobiz/Elementor heading styles from making
 * the copy light or transparent without affecting any other site section. */
.rv-lighthouse-page .rv-lp-framework,
.rv-lighthouse-page .rv-lp-framework * {
    color: #0b1324 !important;
    -webkit-text-fill-color: #0b1324 !important;
}

/* Project Lighthouse applications — light cream surface.
 * This is the lower "کاربرد چارچوب" section shown in the visual review. */
.rv-lighthouse-page .rv-lp-use__content h2,
.rv-lighthouse-page .rv-lp-use__content > p:last-child,
.rv-lighthouse-page .rv-lp-use__list li {
    color: #0b1324;
    -webkit-text-fill-color: #0b1324;
}

.rv-lighthouse-page .rv-lp-use .rv-section-kicker,
.rv-lighthouse-page .rv-lp-use__list li > span {
    color: #c47a08;
    -webkit-text-fill-color: #c47a08;
}

.rv-lighthouse-page .rv-lp-use__list li {
    background: rgba(255, 255, 255, 0.76);
    border-color: #dbe4ef;
}


/* Direct social links — no embeds, SDKs, fonts or tracking scripts. */
.rv-social-contact {
    display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0;
}
.rv-social-contact > a {
    display: inline-flex; align-items: center; justify-content: center;
    min-height: 46px; padding: 10px 16px; border: 1px solid #176844;
    border-radius: 8px; font-size: 0.9375rem; font-weight: 700;
    line-height: 1.8; text-align: center; text-decoration: none;
}
.rv-social-contact > .rv-social-contact__whatsapp {
    color: #fff !important; background: #176844;
}
.rv-social-contact > .rv-social-contact__instagram {
    color: #10213a !important; background: #fff; border-color: #bcc6d3;
}
.rv-social-contact > a:hover { filter: brightness(.93); }
.rv-social-contact > a:focus-visible,
.rv-mobile-contact > a:focus-visible { outline: 3px solid #e5a52a; outline-offset: 3px; }
.rv-mobile-contact, .rv-mobile-contact-space { display: none; }
@media (max-width: 767px) {
    .rv-mobile-contact {
        display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
        gap: 8px; position: fixed; bottom: 0; inset-inline: 0; z-index: 990;
        padding: 8px 12px calc(8px + env(safe-area-inset-bottom, 0px));
        background: #fff; border-top: 1px solid #dbe4ef;
        box-shadow: 0 -3px 12px rgba(15,23,42,.08);
    }
    .rv-mobile-contact > a {
        display: flex; align-items: center; justify-content: center;
        min-width: 0; min-height: 46px; padding: 8px;
        border-radius: 7px; background: #176844; color: #fff !important;
        font-size: .9375rem; line-height: 1.8; font-weight: 700;
        text-align: center; text-decoration: none;
    }
    .rv-mobile-contact > a:last-child { background: #10213a; }
    .rv-mobile-contact-space { display: block; height: calc(100px + env(safe-area-inset-bottom, 0px)); }
}
@media print {
    .rv-mobile-contact, .rv-mobile-contact-space { display: none !important; }
}
