/* ═══════════════════════════════════════════════════════
   barber.css — Ryson Hair Studio Barber Pages
   Shared stylesheet for safiy.php, izzul.php, aiman.php
═══════════════════════════════════════════════════════ */

/* ── Reset & Base ──────────────────────────────────────── */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --black:        #000000;
    --white:        #FFFFFF;
    --off-white:    #F8F7F5;
    --gray-light:   #F2F1EF;
    --gray-medium:  #D8D6D2;
    --gray-dark:    #4A4845;
    --gray-muted:   #888580;
    --transition:   all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-strong:0 12px 48px rgba(0, 0, 0, 0.18);
}

html { scroll-behavior: smooth; }

body {
    font-family: 'Montserrat', sans-serif;
    color: var(--black);
    background-color: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
}

/* ── Navbar ────────────────────────────────────────────── */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    background-color: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.08);
    z-index: 1000;
    transition: var(--transition);
}
.navbar.scrolled { box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1); }

.nav-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    height: 64px;
}

.logo-img { height: 32px; width: auto; }

.nav-back {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--black);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    transition: var(--transition);
    white-space: nowrap;
}
.nav-back:hover { color: var(--gray-muted); }
.nav-back svg { transition: transform 0.3s ease; flex-shrink: 0; }
.nav-back:hover svg { transform: translateX(-4px); }

.btn-book-nav {
    background-color: var(--black);
    color: var(--white);
    padding: 0.5rem 1.2rem;
    border-radius: 2px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    transition: var(--transition);
    white-space: nowrap;
}
.btn-book-nav:hover { background-color: var(--gray-dark); }

/* ── Hero / Profile ────────────────────────────────────── */
.barber-hero {
    min-height: 100vh;
    display: flex;
    align-items: flex-end;
    position: relative;
    overflow: hidden;
    padding-top: 64px; /* navbar height */
}

/* Parallax background — JS handles transform on desktop,
   background-attachment:fixed on desktop only             */
.barber-hero-bg {
    position: absolute;
    inset: -20% 0;          /* extra height top/bottom for parallax travel */
    background-image: var(--hero-bg, url('/img/bgryson.jpg'));
    background-size: cover;
    background-position: center top;
    background-attachment: scroll; /* overridden to fixed on ≥960px via media query */
    will-change: transform;
    z-index: 0;
}

.barber-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.30) 0%,
        rgba(0, 0, 0, 0.18) 25%,
        rgba(0, 0, 0, 0.62) 60%,
        rgba(0, 0, 0, 0.92) 100%
    );
    z-index: 1;
}

.barber-hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 0 0 5rem;
}

.barber-hero-inner {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 4rem;
    align-items: flex-end;
}

/* Portrait */
.barber-portrait-wrap { position: relative; }

.barber-portrait {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    object-position: top center;
    border-radius: 3px;
    border: 2px solid rgba(255, 255, 255, 0.12);
    display: block;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
}

.barber-portrait-label {
    position: absolute;
    bottom: -1px; left: 0; right: 0;
    background: rgba(0, 0, 0, 0.70);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 0.75rem 1.2rem;
    border-radius: 0 0 3px 3px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.barber-portrait-label span {
    font-size: 0.6rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
}

/* Info */
.barber-info { padding-bottom: 0.5rem; }

.barber-studio-tag {
    display: inline-block;
    font-size: 0.63rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.45);
    margin-bottom: 1rem;
}

.barber-name {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 6.5rem;
    font-weight: 400;
    color: var(--white);
    line-height: 0.88;
    letter-spacing: 0.03em;
    margin-bottom: 1.5rem;
    text-shadow: 0 4px 40px rgba(0, 0, 0, 0.4);
}

.barber-role {
    font-size: 0.7rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 1.6rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}
.barber-role::before {
    content: '';
    width: 28px;
    height: 1.5px;
    background: rgba(255, 255, 255, 0.35);
    flex-shrink: 0;
}

.barber-intro {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.65);
    font-weight: 300;
    line-height: 1.85;
    max-width: 520px;
    margin-bottom: 2.2rem;
}

.barber-specialties {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 2.2rem;
}
.specialty-tag {
    padding: 0.35rem 0.9rem;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 2px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.68rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-weight: 500;
}

.barber-cta-group { display: flex; gap: 1rem; flex-wrap: wrap; }

.btn-hero-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.9rem 2rem;
    background-color: var(--white);
    color: var(--black);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.73rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    border-radius: 2px;
    transition: var(--transition);
    border: 1.5px solid var(--white);
}
.btn-hero-primary:hover { background-color: transparent; color: var(--white); }
.btn-hero-primary svg { transition: transform 0.3s ease; flex-shrink: 0; }
.btn-hero-primary:hover svg { transform: translateX(4px); }

.btn-hero-ghost {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.9rem 2rem;
    background-color: transparent;
    color: var(--white);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.73rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    border-radius: 2px;
    transition: var(--transition);
    border: 1.5px solid rgba(255, 255, 255, 0.35);
}
.btn-hero-ghost:hover {
    background-color: var(--white);
    color: var(--black);
    border-color: var(--white);
}

/* ── Stats Bar ─────────────────────────────────────────── */
.stats-bar {
    background-color: var(--black);
    border-top: 1px solid rgba(255, 255, 255, 0.07);
}
.stats-inner {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
}
.stat-item {
    padding: 2rem 1.5rem;
    text-align: center;
    border-right: 1px solid rgba(255, 255, 255, 0.07);
}
.stat-item:last-child { border-right: none; }
.stat-number {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 2.8rem;
    color: var(--white);
    letter-spacing: 0.04em;
    line-height: 1;
    margin-bottom: 0.35rem;
}
.stat-label {
    font-size: 0.62rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.35);
    font-weight: 500;
}

/* ── Section Globals ───────────────────────────────────── */
.section-header { text-align: center; margin-bottom: 4rem; }

.section-label {
    display: block;
    font-size: 0.65rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: var(--gray-muted);
    margin-bottom: 0.7rem;
}
.section-label.light { color: rgba(255, 255, 255, 0.45); }

.section-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 3.2rem;
    font-weight: 400;
    letter-spacing: 0.06em;
    margin-bottom: 1rem;
    line-height: 1;
}
.section-title.light { color: var(--white); }

.title-underline {
    width: 44px;
    height: 1.5px;
    background-color: var(--black);
    margin: 0 auto 1rem;
}
.title-underline.light { background-color: rgba(255, 255, 255, 0.4); }

.section-subtitle {
    font-size: 0.88rem;
    color: var(--gray-muted);
    font-weight: 400;
}
.section-subtitle.light { color: rgba(255, 255, 255, 0.5); }

/* ── Specialities ──────────────────────────────────────── */
.specialities { padding: 6rem 0; background-color: var(--off-white); }

.spec-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    border: 1.5px solid var(--gray-medium);
    border-radius: 4px;
    overflow: hidden;
    background-color: var(--gray-medium);
    gap: 1.5px;
}
.spec-card {
    background-color: var(--white);
    padding: 2.8rem 2.2rem;
    transition: var(--transition);
    position: relative;
}
.spec-card:hover {
    background-color: var(--off-white);
    transform: translateY(-4px);
    box-shadow: var(--shadow-strong);
    z-index: 2;
}
.spec-num {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 3rem;
    color: var(--gray-medium);
    line-height: 1;
    margin-bottom: 0.8rem;
    letter-spacing: 0.04em;
}
.spec-card h3 {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 0.7rem;
}
.spec-card p {
    font-size: 0.84rem;
    color: var(--gray-dark);
    font-weight: 300;
    line-height: 1.75;
}

/* ── Work Gallery ──────────────────────────────────────── */
.work-gallery { padding: 6rem 0; background-color: var(--white); }

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}
.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 3px;
    aspect-ratio: 3 / 4;
    background-color: var(--gray-light);
    cursor: pointer;
}
.gallery-item--wide {
    grid-column: span 2;
    aspect-ratio: 16 / 9;
}
.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
.gallery-item:hover img { transform: scale(1.05); }
.gallery-caption {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 1rem 1.2rem 0.8rem;
    background: linear-gradient(to top, rgba(0,0,0,0.65) 0%, transparent 100%);
    color: var(--white);
    font-size: 0.68rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-weight: 500;
    opacity: 0;
    transform: translateY(6px);
    transition: var(--transition);
}
.gallery-item:hover .gallery-caption { opacity: 1; transform: translateY(0); }

/* ── Booking ───────────────────────────────────────────── */
.booking {
    background-color: var(--black);
    position: relative;
    overflow: hidden;
    padding: 6rem 0;
}
.booking-bg {
    position: absolute; inset: 0;
    background-image:
        repeating-linear-gradient(90deg, transparent, transparent 79px, rgba(255,255,255,0.018) 79px, rgba(255,255,255,0.018) 80px),
        repeating-linear-gradient(0deg,  transparent, transparent 79px, rgba(255,255,255,0.018) 79px, rgba(255,255,255,0.018) 80px);
    pointer-events: none;
}
.booking-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5rem;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.qr-block { display: flex; flex-direction: column; align-items: center; gap: 1rem; }

.qr-frame {
    position: relative;
    padding: 1.2rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.03);
}
.qr-corner { position: absolute; width: 18px; height: 18px; }
.qr-corner--tl { top:-1px; left:-1px; border-top:2px solid var(--white); border-left:2px solid var(--white); }
.qr-corner--tr { top:-1px; right:-1px; border-top:2px solid var(--white); border-right:2px solid var(--white); }
.qr-corner--bl { bottom:-1px; left:-1px; border-bottom:2px solid var(--white); border-left:2px solid var(--white); }
.qr-corner--br { bottom:-1px; right:-1px; border-bottom:2px solid var(--white); border-right:2px solid var(--white); }

.qr-img { display: block; width: 200px; height: 200px; border-radius: 2px; }
.qr-label { color: var(--white); font-size: 0.7rem; letter-spacing: 0.22em; text-transform: uppercase; font-weight: 500; }
.qr-url { color: rgba(255,255,255,0.3); font-size: 0.66rem; letter-spacing: 0.04em; }

.booking-divider {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    color: rgba(255,255,255,0.2);
    font-size: 0.7rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}
.booking-divider::before,
.booking-divider::after {
    content: '';
    width: 1px;
    height: 55px;
    background: linear-gradient(to bottom, transparent, rgba(255,255,255,0.15), transparent);
}

.booking-cta { max-width: 360px; }
.booking-cta-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 3.2rem;
    font-weight: 400;
    color: var(--white);
    line-height: 1.05;
    margin-bottom: 1.1rem;
    letter-spacing: 0.04em;
}
.booking-cta-title em { font-style: italic; }
.booking-cta-desc {
    color: rgba(255,255,255,0.45);
    font-size: 0.84rem;
    line-height: 1.75;
    font-weight: 300;
    margin-bottom: 1.8rem;
}
.btn-booking-main {
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    padding: 1rem 2.2rem;
    background-color: var(--white);
    color: var(--black);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.73rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    border-radius: 2px;
    transition: var(--transition);
    border: 1.5px solid var(--white);
    margin-bottom: 1rem;
}
.btn-booking-main:hover { background-color: transparent; color: var(--white); }
.btn-booking-main svg { transition: transform 0.3s ease; flex-shrink: 0; }
.btn-booking-main:hover svg { transform: translateX(5px); }
.booking-note {
    color: rgba(255,255,255,0.22);
    font-size: 0.66rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

/* ── Location ──────────────────────────────────────────── */
.location { padding: 6rem 0; background-color: var(--white); }

.location-content {
    display: grid;
    grid-template-columns: 1fr 1.6fr;
    gap: 4rem;
    align-items: start;
}
.location-info { display: flex; flex-direction: column; }
.info-item { padding: 2rem 0; border-bottom: 1px solid var(--gray-medium); }
.info-item:first-child { padding-top: 0; }
.info-item:last-child { border-bottom: none; }
.info-item h3 {
    font-size: 0.68rem;
    margin-bottom: 0.55rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--gray-muted);
}
.info-item p {
    color: var(--gray-dark);
    line-height: 1.85;
    font-size: 0.86rem;
    font-weight: 300;
}
.location-map {
    background-color: var(--gray-light);
    border-radius: 3px;
    overflow: hidden;
    height: 420px;
}

/* ── Footer ────────────────────────────────────────────── */
.footer { background-color: var(--black); color: var(--white); padding: 4rem 0 2rem; }
.footer-content {
    text-align: center;
    margin-bottom: 3rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid rgba(255,255,255,0.07);
}
.footer-logo { height: 32px; width: auto; margin-bottom: 1.2rem; filter: invert(1); opacity: 0.88; }
.footer-text {
    margin-bottom: 1.8rem;
    font-size: 0.7rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.35);
}
.footer-social { display: flex; justify-content: center; gap: 1.2rem; }
.social-link {
    color: rgba(255,255,255,0.45);
    text-decoration: none;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 50%;
}
.social-link:hover { color: var(--white); border-color: rgba(255,255,255,0.4); transform: translateY(-3px); }
.footer-bottom { text-align: center; font-size: 0.75rem; color: rgba(255,255,255,0.3); letter-spacing: 0.04em; }

/* ── Animations ────────────────────────────────────────── */
@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-20px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeInLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to   { opacity: 1; transform: translateX(0); }
}

/* ═══════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════ */

/* ── Large desktop ≥ 1280px ────────────────────────────── */
@media (min-width: 1280px) {
    .barber-hero-inner { grid-template-columns: 340px 1fr; gap: 5rem; }
    .barber-name { font-size: 7.5rem; }

    /* True CSS parallax on large screens */
    .barber-hero-bg {
        background-attachment: fixed;
        inset: 0;
    }
}

/* ── Desktop 960px – 1279px ────────────────────────────── */
@media (min-width: 960px) and (max-width: 1279px) {
    .barber-hero-bg {
        background-attachment: fixed;
        inset: 0;
    }
}

/* ── Tablet landscape / small desktop  768px – 959px ───── */
@media (max-width: 959px) {

    /* Disable fixed bg on tablet/mobile — causes rendering bugs on iOS */
    .barber-hero-bg {
        background-attachment: scroll;
        inset: 0;
    }

    .barber-hero-inner {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        text-align: center;
    }

    .barber-portrait-wrap {
        max-width: 280px;
        margin: 0 auto;
    }

    .barber-info { text-align: center; }

    .barber-role {
        justify-content: center;
    }
    .barber-role::before { display: none; }

    .barber-intro {
        margin-left: auto;
        margin-right: auto;
    }

    .barber-specialties { justify-content: center; }
    .barber-cta-group    { justify-content: center; }

    .barber-hero-content { padding-bottom: 4rem; }
    .barber-name         { font-size: 5rem; }

    .location-content { grid-template-columns: 1fr; }
    .location-map     { height: 320px; }

    .booking-content { gap: 3.5rem; flex-direction: column; align-items: center; text-align: center; }
    .booking-cta     { text-align: center; }

    .booking-divider { flex-direction: row; }
    .booking-divider::before,
    .booking-divider::after {
        width: 55px;
        height: 1px;
        background: linear-gradient(to right, transparent, rgba(255,255,255,0.15), transparent);
    }
}

/* ── Tablet portrait  600px – 767px ───────────────────── */
@media (max-width: 767px) {
    .container { padding: 0 20px; }

    /* Hero */
    .barber-hero { padding-top: 64px; }
    .barber-name { font-size: 4rem; }

    .barber-portrait-wrap { max-width: 240px; }

    /* Nav */
    .nav-wrapper { height: 56px; }
    .logo-img    { height: 28px; }
    .nav-back span { display: none; }   /* show only arrow on tight screens */
    .nav-back svg  { width: 18px; height: 18px; }
    .btn-book-nav  { padding: 0.45rem 1rem; font-size: 0.68rem; }

    /* Stats */
    .stats-inner { grid-template-columns: repeat(3, 1fr); }
    .stat-number { font-size: 2.2rem; }
    .stat-label  { font-size: 0.58rem; }

    /* Sections */
    .specialities,
    .work-gallery,
    .booking,
    .location   { padding: 4rem 0; }
    .section-header { margin-bottom: 2.5rem; }
    .section-title  { font-size: 2.6rem; }

    /* Gallery */
    .gallery-grid { grid-template-columns: 1fr 1fr; gap: 0.5rem; }
    .gallery-item--wide { grid-column: span 2; aspect-ratio: 4 / 3; }
    .gallery-item       { aspect-ratio: 1 / 1; }

    /* Location */
    .location-map { height: 280px; }

    /* Footer */
    .footer { padding: 3rem 0 1.5rem; }
    .footer-logo { height: 28px; }
}

/* ── Mobile  ≤ 479px ───────────────────────────────────── */
@media (max-width: 479px) {
    .container { padding: 0 16px; }

    /* Navbar: tighter */
    .navbar { }
    .nav-wrapper { height: 52px; padding: 0; }

    /* Hero — 120px top padding as requested */
    .barber-hero { padding-top: 120px; }
    .barber-hero-content { padding: 0 0 3rem; }

    .barber-portrait-wrap { max-width: 200px; }
    .barber-name  { font-size: 3.2rem; }
    .barber-intro { font-size: 0.88rem; }

    .specialty-tag { font-size: 0.62rem; padding: 0.3rem 0.7rem; }

    .barber-cta-group { flex-direction: column; align-items: center; width: 100%; }
    .btn-hero-primary,
    .btn-hero-ghost { width: 100%; justify-content: center; }

    /* Stats — stack vertically */
    .stats-inner {
        grid-template-columns: 1fr;
    }
    .stat-item {
        border-right: none;
        border-bottom: 1px solid rgba(255,255,255,0.07);
        padding: 1.4rem 1rem;
    }
    .stat-item:last-child { border-bottom: none; }
    .stat-number { font-size: 2.4rem; }

    /* Spec grid — single column */
    .spec-grid { grid-template-columns: 1fr; }

    /* Gallery — single column */
    .gallery-grid { grid-template-columns: 1fr; }
    .gallery-item--wide { grid-column: span 1; aspect-ratio: 4 / 3; }
    .gallery-item { aspect-ratio: 4 / 3; }

    /* Booking */
    .qr-img { width: 170px; height: 170px; }
    .booking-cta-title { font-size: 2.6rem; }
    .btn-booking-main { width: 100%; justify-content: center; }

    /* Location */
    .location-map { height: 240px; }

    /* Section titles */
    .section-title  { font-size: 2.2rem; }
}