/* ═══════════════════════════════════════════════════════════════════════════
   ESRE MEDIA - Premium Minimalist Design System
   Brand: #000C39 (Deep Navy) + White ONLY
   Inspired by Apple, Airbnb, and top agency aesthetics
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─────────────────────────────────────────────────────────────────────────────
   Design Tokens
   ───────────────────────────────────────────────────────────────────────────── */
:root {
    --navy: #000C39;
    --white: #ffffff;
    --off-white: #fafbfc;
    --light-gray: #f5f6f8;
    --border: #e8eaef;
    --text-secondary: #4a5568;

    --font-display: 'Outfit', system-ui, sans-serif;
    --font-body: 'Inter', system-ui, sans-serif;

    --max-width: 1140px;
    --nav-height: 72px;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Reset
   ───────────────────────────────────────────────────────────────────────────── */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: var(--font-body);
    font-size: 17px;
    line-height: 1.65;
    color: var(--navy);
    background: var(--white);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Typography
   ───────────────────────────────────────────────────────────────────────────── */
h1,
h2,
h3,
h4 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.15;
    color: var(--navy);
    letter-spacing: -0.02em;
}

h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
}

h3 {
    font-size: 1.5rem;
}

h4 {
    font-size: 1.125rem;
}

p {
    margin-bottom: 1rem;
}

p:last-child {
    margin-bottom: 0;
}

.lead {
    font-size: 1.25rem;
    line-height: 1.6;
    color: var(--text-secondary);
}

/* ─────────────────────────────────────────────────────────────────────────────
   Layout
   ───────────────────────────────────────────────────────────────────────────── */
.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: 120px 0;
}

.section--navy {
    background: var(--navy);
    color: var(--white);
}

.section--navy h2,
.section--navy h3,
.section--navy h4 {
    color: var(--white);
}

.section--navy .lead {
    color: rgba(255, 255, 255, 0.75);
}

.section--gray {
    background: var(--light-gray);
}

/* ─────────────────────────────────────────────────────────────────────────────
   Navigation
   ───────────────────────────────────────────────────────────────────────────── */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    background: var(--white);
    border-bottom: 1px solid var(--border);
    z-index: 1000;
    display: flex;
    align-items: center;
}

.nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav__logo {
    height: 40px;
}

.nav__menu {
    display: flex;
    align-items: center;
    gap: 48px;
}

.nav__links {
    display: flex;
    gap: 32px;
}

.nav__link {
    font-size: 15px;
    font-weight: 500;
    color: var(--navy);
    opacity: 0.7;
    transition: opacity 0.2s;
}

.nav__link:hover,
.nav__link--active {
    opacity: 1;
}

.nav__toggle {
    display: none;
    width: 24px;
    height: 24px;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
}

.nav__toggle span {
    width: 100%;
    height: 2px;
    background: var(--navy);
    transition: 0.2s;
}

@media (max-width: 768px) {
    .nav__toggle {
        display: flex;
        z-index: 1001;
    }

    .nav__menu {
        position: fixed;
        inset: 0;
        background: var(--navy);
        flex-direction: column;
        justify-content: center;
        gap: 32px;
        transform: translateX(100%);
        transition: 0.3s ease;
    }

    .nav__menu--open {
        transform: translateX(0);
    }

    .nav__links {
        flex-direction: column;
        align-items: center;
    }

    .nav__link {
        font-size: 1.75rem;
        color: var(--white);
        opacity: 1;
    }

    .nav__link:hover {
        opacity: 0.8;
    }

    /* Style the button in mobile nav */
    .nav__menu .btn {
        background: var(--white);
        color: var(--navy);
        padding: 16px 32px;
        font-size: 1rem;
        margin-top: 16px;
    }

    .nav__toggle--open span {
        background: var(--white);
    }

    .nav__toggle--open span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .nav__toggle--open span:nth-child(2) {
        opacity: 0;
    }

    .nav__toggle--open span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    /* Mobile hero adjustments */
    .hero {
        min-height: auto;
        padding: calc(var(--nav-height) + 40px) 24px 60px;
    }

    .hero--page {
        min-height: auto;
        padding: calc(var(--nav-height) + 60px) 24px 60px;
    }

    .hero__logo {
        max-width: 240px;
        margin-bottom: 32px;
    }

    /* Mobile section adjustments */
    .section {
        padding: 80px 0;
    }

    .section-header {
        margin-bottom: 48px;
    }
}

/* ─────────────────────────────────────────────────────────────────────────────
   Buttons
   ───────────────────────────────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    font-family: var(--font-display);
    font-size: 15px;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.2s;
}

.btn--primary {
    background: var(--navy);
    color: var(--white);
}

.btn--primary:hover {
    background: #0a1a5c;
    transform: translateY(-1px);
}

.btn--secondary {
    background: var(--white);
    color: var(--navy);
}

.btn--secondary:hover {
    background: var(--off-white);
}

.btn--outline {
    background: transparent;
    color: var(--navy);
    border: 2px solid var(--navy);
}

.btn--outline:hover {
    background: var(--navy);
    color: var(--white);
}

.btn--outline-white {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

.btn--outline-white:hover {
    background: var(--white);
    color: var(--navy);
}

.btn--lg {
    padding: 18px 36px;
    font-size: 16px;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Hero
   ───────────────────────────────────────────────────────────────────────────── */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: calc(var(--nav-height) + 60px) 24px 80px;
    background: var(--white);
}

.hero__inner {
    max-width: 800px;
    text-align: center;
}

.hero__logo {
    max-width: 320px;
    margin: 0 auto 48px;
}

.hero__title {
    margin-bottom: 24px;
}

.hero__subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 40px;
    line-height: 1.7;
}

.hero__actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Page hero (smaller, navy) */
.hero--page {
    min-height: 50vh;
    background: var(--navy);
    padding: calc(var(--nav-height) + 80px) 24px 80px;
}

.hero--page .hero__title {
    color: var(--white);
}

.hero--page .hero__subtitle {
    color: rgba(255, 255, 255, 0.8);
}

/* ─────────────────────────────────────────────────────────────────────────────
   Section Header
   ───────────────────────────────────────────────────────────────────────────── */
.section-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 64px;
}

.section-header__label {
    display: inline-block;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--navy);
    margin-bottom: 16px;
}

.section--navy .section-header__label {
    color: rgba(255, 255, 255, 0.6);
}

.section-header__title {
    margin-bottom: 16px;
}

.section-header__desc {
    font-size: 1.125rem;
    color: var(--text-secondary);
}

.section--navy .section-header__desc {
    color: rgba(255, 255, 255, 0.7);
}

/* ─────────────────────────────────────────────────────────────────────────────
   Grid
   ───────────────────────────────────────────────────────────────────────────── */
.grid {
    display: grid;
    gap: 32px;
}

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

.grid--3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid--4 {
    grid-template-columns: repeat(4, 1fr);
}

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

@media (max-width: 768px) {

    .grid--2,
    .grid--3,
    .grid--4 {
        grid-template-columns: 1fr;
    }

    .grid {
        gap: 24px;
    }

    /* Service cards - INLINE layout on mobile */
    .service-card {
        display: flex;
        flex-direction: row;
        align-items: flex-start;
        gap: 16px;
        padding: 20px;
    }

    .service-card__icon {
        flex-shrink: 0;
        margin-bottom: 0;
    }

    .service-card__content {
        flex: 1;
    }

    .service-card__title {
        margin-bottom: 6px;
    }

    .service-card__text {
        font-size: 14px;
    }

    /* Portfolio cards - keep stacked but smaller */
    .portfolio-card {
        padding: 24px 20px;
    }

    .portfolio-card__icon {
        font-size: 2rem;
        margin-bottom: 12px;
    }
}

/* ─────────────────────────────────────────────────────────────────────────────
   Service Cards
   ───────────────────────────────────────────────────────────────────────────── */
.service-card {
    padding: 32px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 12px;
    transition: box-shadow 0.2s, transform 0.2s;
}

.service-card:hover {
    box-shadow: 0 8px 30px rgba(0, 12, 57, 0.08);
    transform: translateY(-2px);
}

.service-card__icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--navy);
    color: var(--white);
    border-radius: 10px;
    font-size: 1.25rem;
    margin-bottom: 20px;
}

.service-card__title {
    margin-bottom: 12px;
}

.service-card__text {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.6;
}

/* Navy variant */
.service-card--navy {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.service-card--navy .service-card__icon {
    background: var(--white);
    color: var(--navy);
}

.service-card--navy .service-card__title {
    color: var(--white);
}

.service-card--navy .service-card__text {
    color: rgba(255, 255, 255, 0.7);
}

/* ─────────────────────────────────────────────────────────────────────────────
   Feature Row
   ───────────────────────────────────────────────────────────────────────────── */
.feature-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.feature-row--reverse {
    direction: rtl;
}

.feature-row--reverse>* {
    direction: ltr;
}

.feature-row__content h2 {
    margin-bottom: 24px;
}

.feature-row__content p {
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.feature-row__visual {
    background: var(--navy);
    border-radius: 16px;
    padding: 48px;
    text-align: center;
    color: var(--white);
}

.feature-row__stat {
    font-family: var(--font-display);
    font-size: 5rem;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 16px;
}

.feature-row__stat-label {
    font-size: 1.25rem;
    opacity: 0.8;
}

@media (max-width: 768px) {
    .feature-row {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .feature-row--reverse {
        direction: ltr;
    }
}

/* ─────────────────────────────────────────────────────────────────────────────
   Portfolio Card
   ───────────────────────────────────────────────────────────────────────────── */
.portfolio-card {
    display: block;
    background: var(--navy);
    border-radius: 12px;
    padding: 48px 32px;
    text-align: center;
    color: var(--white);
    transition: transform 0.2s, box-shadow 0.2s;
}

.portfolio-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 40px rgba(0, 12, 57, 0.2);
}

.portfolio-card__icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.portfolio-card__name {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.portfolio-card__category {
    font-size: 14px;
    opacity: 0.7;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Testimonials
   ───────────────────────────────────────────────────────────────────────────── */
.testimonial {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 32px;
}

.testimonial__icon {
    font-size: 2rem;
    color: var(--border);
    margin-bottom: 16px;
}

.testimonial__text {
    font-size: 1.0625rem;
    font-style: italic;
    margin-bottom: 20px;
    line-height: 1.7;
}

.testimonial__author {
    font-weight: 600;
}

.testimonial__location {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ─────────────────────────────────────────────────────────────────────────────
   CTA Banner
   ───────────────────────────────────────────────────────────────────────────── */
.cta-banner {
    background: var(--navy);
    padding: 80px 24px;
    text-align: center;
}

.cta-banner__inner {
    max-width: 600px;
    margin: 0 auto;
}

.cta-banner__title {
    color: var(--white);
    margin-bottom: 16px;
}

.cta-banner__text {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.125rem;
    margin-bottom: 32px;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Contact
   ───────────────────────────────────────────────────────────────────────────── */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
}

@media (max-width: 768px) {
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 48px;
    }
}

.contact-info__item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 24px;
}

.contact-info__icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--navy);
    color: var(--white);
    border-radius: 10px;
    font-size: 1.125rem;
    flex-shrink: 0;
}

.contact-info__label {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.contact-info__value {
    font-weight: 600;
}

.contact-info__value a:hover {
    text-decoration: underline;
}

/* Form */
.form__group {
    margin-bottom: 20px;
}

.form__label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
}

.form__input,
.form__textarea {
    width: 100%;
    padding: 14px 16px;
    font-family: inherit;
    font-size: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--white);
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form__input:focus,
.form__textarea:focus {
    outline: none;
    border-color: var(--navy);
    box-shadow: 0 0 0 3px rgba(0, 12, 57, 0.1);
}

.form__textarea {
    min-height: 140px;
    resize: vertical;
}

.form__submit {
    width: 100%;
}

.form__message {
    padding: 16px;
    border-radius: 8px;
    margin-top: 20px;
    text-align: center;
}

.form__message--success {
    background: rgba(0, 12, 57, 0.05);
    color: var(--navy);
}

.form__message--error {
    background: rgba(220, 38, 38, 0.1);
    color: #c53030;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Footer
   ───────────────────────────────────────────────────────────────────────────── */
.footer {
    background: var(--navy);
    color: var(--white);
    padding: 64px 0 32px;
}

.footer__grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 48px;
}

@media (max-width: 768px) {
    .footer {
        padding: 48px 0 32px;
        text-align: center;
    }

    .footer__grid {
        display: block;
    }

    /* Hide navigation columns on mobile */
    .footer__grid>div:nth-child(2),
    .footer__grid>div:nth-child(3) {
        display: none;
    }

    .footer__logo {
        margin: 0 auto 16px;
    }

    .footer__desc {
        max-width: 100%;
        margin: 0 auto;
    }
}

.footer__logo {
    height: 36px;
    margin-bottom: 16px;
    filter: brightness(0) invert(1);
}

.footer__desc {
    color: rgba(255, 255, 255, 0.6);
    font-size: 15px;
    max-width: 280px;
}

.footer__title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 20px;
}

.footer__links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer__link {
    color: rgba(255, 255, 255, 0.6);
    font-size: 15px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: color 0.2s;
}

.footer__link:hover {
    color: var(--white);
}

.footer__bottom {
    padding-top: 32px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.5);
}

/* ─────────────────────────────────────────────────────────────────────────────
   Utilities
   ───────────────────────────────────────────────────────────────────────────── */
.text-center {
    text-align: center;
}

.mb-0 {
    margin-bottom: 0;
}

.mb-sm {
    margin-bottom: 8px;
}

.mb-md {
    margin-bottom: 16px;
}

.mb-lg {
    margin-bottom: 32px;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Animations
   ───────────────────────────────────────────────────────────────────────────── */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate {
    opacity: 0;
}

.animate--visible {
    animation: fadeUp 0.5s ease forwards;
}

.animate--delay-1 {
    animation-delay: 0.1s;
}

.animate--delay-2 {
    animation-delay: 0.2s;
}

.animate--delay-3 {
    animation-delay: 0.3s;
}