﻿/* ── css/navbar-bottom.css ── */
/* Single-island Dynamic Island navbar */

body { padding-bottom: 92px; }
#smooth-scroll-content { padding-bottom: 92px; }

/* ═══════════════════════════════════════
   ISLAND — the single morphing object
═══════════════════════════════════════ */
#bnav-island {
    position: fixed;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1001;
    overflow: hidden;
    background: rgba(11, 11, 11, 0.95);
    border: 1px solid rgba(255,255,255,0.09);
    box-shadow:
        0 0 0 1px rgba(0,0,0,0.55),
        0 8px 32px rgba(0,0,0,0.72),
        0 2px 8px  rgba(0,0,0,0.45),
        inset 0 1px 0 rgba(255,255,255,0.06);

    /* ── Closed state ── */
    width: 192px;
    height: 48px;
    border-radius: 100px;

    /* ── Opening transition: spring bounce ── */
    transition:
        width         0.58s cubic-bezier(0.34, 1.18, 0.64, 1),
        height        0.60s cubic-bezier(0.34, 1.18, 0.64, 1) 0.015s,
        border-radius 0.54s cubic-bezier(0.34, 1.10, 0.64, 1) 0.030s,
        box-shadow    0.30s ease;
}

/* ── Open state dimensions ── */
#bnav-island.open {
    width: min(420px, calc(100vw - 40px));
    height: 420px;
    border-radius: 18px;
    box-shadow:
        0 0 0 1px rgba(0,0,0,0.55),
        0 -6px 48px rgba(0,0,0,0.55),
        0 2px 8px  rgba(0,0,0,0.45),
        inset 0 1px 0 rgba(255,255,255,0.06);
}

/* ── Closing: faster + delayed so content disappears first ── */
#bnav-island.closing {
    transition:
        width         0.40s cubic-bezier(0.40, 0, 0.20, 1) 0.16s,
        height        0.40s cubic-bezier(0.40, 0, 0.20, 1) 0.10s,
        border-radius 0.38s cubic-bezier(0.40, 0, 0.20, 1) 0.16s,
        box-shadow    0.30s ease;
}

/* ═══════════════════════════════════════
   TRIGGER — physically moves from pill-right to panel-bottom-center
═══════════════════════════════════════ */
#bnav-trigger {
    position: absolute;
    z-index: 10;
    bottom: 6px;
    right: 6px;
    width: 36px;
    height: 36px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.09);
    border-radius: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4.5px;
    cursor: pointer;
    padding: 0;
    transition:
        bottom       0.56s cubic-bezier(0.34, 1.15, 0.64, 1),
        right        0.56s cubic-bezier(0.34, 1.15, 0.64, 1),
        background   0.20s ease,
        border-color 0.20s ease;
}
#bnav-trigger:hover {
    background: rgba(255,255,255,0.13);
    border-color: rgba(255,255,255,0.22);
}

/* Move to bottom-center of open island */
#bnav-island.open #bnav-trigger {
    bottom: 22px;
    right: calc(50% - 18px);
}

/* Closing: trigger returns to pill corner, delayed */
#bnav-island.closing #bnav-trigger {
    transition:
        bottom       0.38s cubic-bezier(0.40, 0, 0.20, 1) 0.14s,
        right        0.38s cubic-bezier(0.40, 0, 0.20, 1) 0.14s,
        background   0.20s ease,
        border-color 0.20s ease;
}

/* Hamburger lines → × */
#bnav-trigger span {
    display: block;
    width: 14px;
    height: 1.5px;
    background: rgba(255,255,255,0.88);
    border-radius: 2px;
    transform-origin: center;
    transition:
        transform 0.38s cubic-bezier(0.34, 1.18, 0.64, 1),
        opacity   0.22s ease;
}
#bnav-island.open #bnav-trigger span:nth-child(1) { transform: translateY(6px)  rotate(45deg); }
#bnav-island.open #bnav-trigger span:nth-child(2) { opacity: 0; transform: scaleX(0); }
#bnav-island.open #bnav-trigger span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ═══════════════════════════════════════
   PILL FACE (icon + label) — visible when closed
═══════════════════════════════════════ */
#bnav-pill-face {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 48px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 50px 6px 6px; /* right-pad: room for trigger */
    pointer-events: auto;
    opacity: 1;
    transition: opacity 0.18s ease;
}
#bnav-island.open #bnav-pill-face {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.14s ease;
}
/* Pill reappears after shape mostly collapsed */
#bnav-island.closing #bnav-pill-face {
    transition: opacity 0.22s ease 0.30s;
}

/* Logo circle */
.bnav-icon {
    width: 36px; height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.07);
    border: 1px solid rgba(255,255,255,0.09);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0; overflow: hidden;
    text-decoration: none;
    cursor: pointer;
}
.bnav-icon img {
    width: 20px; height: 20px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}
.bnav-icon-letter {
    font-family: 'Cormorant Garamond', serif;
    font-size: 18px; font-weight: 600;
    color: #fff; letter-spacing: -0.5px; line-height: 1;
}
#bnav-pill-label {
    font-family: 'Montserrat', sans-serif;
    font-size: 10px; font-weight: 700;
    letter-spacing: 3px; color: rgba(255,255,255,0.82);
    text-transform: uppercase;
    white-space: nowrap;
    flex: 1;
    text-align: center;
    pointer-events: none;
}

/* ═══════════════════════════════════════
   PANEL FACE — clipped when closed, revealed on open
═══════════════════════════════════════ */
#bnav-panel-face {
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 420px; /* matches island open height */
    padding: 34px 36px 60px;
    display: flex;
    flex-direction: column;
    pointer-events: none;
}
#bnav-island.open #bnav-panel-face {
    pointer-events: auto;
}

/* All content children: start invisible + shifted down */
.bnav-menu-label,
#bnav-nav-links a,
.bnav-divider,
#bnav-meta {
    opacity: 0;
    transform: translateY(10px);
    transition:
        opacity   0.28s ease,
        transform 0.42s cubic-bezier(0.34, 1.10, 0.64, 1);
}

/* Staggered entrance — begins after shape settles (~0.34s) */
#bnav-island.open .bnav-menu-label                  { opacity:1; transform:none; transition-delay: 0.34s; }
#bnav-island.open #bnav-nav-links a:nth-child(1)    { opacity:1; transform:none; transition-delay: 0.39s; }
#bnav-island.open #bnav-nav-links a:nth-child(2)    { opacity:1; transform:none; transition-delay: 0.44s; }
#bnav-island.open #bnav-nav-links a:nth-child(3)    { opacity:1; transform:none; transition-delay: 0.49s; }
#bnav-island.open #bnav-nav-links a:nth-child(4)    { opacity:1; transform:none; transition-delay: 0.54s; }
#bnav-island.open .bnav-divider                     { opacity:1; transform:none; transition-delay: 0.57s; }
#bnav-island.open #bnav-meta                        { opacity:1; transform:none; transition-delay: 0.61s; }

/* After fully open: enable hover micro-interactions, clear stagger delays */
#bnav-island.open-done #bnav-nav-links a {
    transition-delay: 0s !important;
}
#bnav-island.open-done #bnav-nav-links a:hover {
    color: #fff;
    transform: translateX(7px) !important;
    transition: color 0.15s ease, transform 0.30s cubic-bezier(0.34,1.1,0.64,1) !important;
}

/* ── Panel content styles ── */
.bnav-menu-label {
    font-family: 'Montserrat', sans-serif;
    font-size: 8px; letter-spacing: 4px;
    color: rgba(255,255,255,0.28);
    text-transform: uppercase; font-weight: 600;
    margin-bottom: 14px;
}
#bnav-nav-links {
    display: flex;
    flex-direction: column;
    flex: 1;
    margin-bottom: 24px;
}
#bnav-nav-links a {
    font-family: 'Cormorant Garamond', serif;
    font-size: clamp(34px, 6vw, 46px);
    font-weight: 400;
    color: rgba(255,255,255,0.85);
    text-decoration: none;
    line-height: 1.10;
    letter-spacing: -0.8px;
    display: block;
}
#bnav-nav-links a.bnav-active { color: rgba(253, 253, 253, 0.2); }

.bnav-divider {
    height: 1px;
    background: rgba(255,255,255,0.08);
    margin-bottom: 22px;
}
#bnav-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}
.bnav-meta-info { display: flex; flex-direction: column; gap: 5px; }
.bnav-meta-info a {
    font-family: 'Montserrat', sans-serif;
    font-size: 10px; color: rgba(255,255,255,0.85);
    text-decoration: none; letter-spacing: 0.2px;
    transition: color 0.2s;
}
.bnav-meta-info a:hover { color: rgba(255,255,255,0.70); }

#bnav-cta {
    font-family: 'Montserrat', sans-serif;
    font-size: 9px; font-weight: 700;
    letter-spacing: 2.5px; text-transform: uppercase;
    color: #fff;
    background: rgba(255,255,255,0.07);
    border: 1px solid rgba(255,255,255,0.14);
    text-decoration: none;
    padding: 10px 16px;
    display: inline-flex; align-items: center; gap: 7px;
    border-radius: 3px; white-space: nowrap;
    transition: background 0.2s, border-color 0.2s;
}

#bnav-cta:hover {
    background: rgba(255,255,255,0.14);
    border-color: rgba(255,255,255,0.28);
}

/* ═══════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════ */
@media (max-width: 600px) {
    #bnav-island { bottom: 18px; }
    #bnav-island.open { height: 400px; }
    #bnav-panel-face { height: 400px; padding: 28px 22px 76px; }
    #bnav-nav-links { flex: none; margin-bottom: 16px; }
    #bnav-nav-links a { font-size: 32px; }
    .bnav-divider { margin-bottom: 16px; }
    #bnav-meta { flex-direction: column; align-items: flex-start; gap: 12px; }
    #bnav-cta { width: 100%; justify-content: center; }
}
