.inst-hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: calc(100vh - var(--nav-h));
    min-height: calc(100svh - var(--nav-h));
    overflow: hidden;
    isolation: isolate;
    background: var(--bg);
}

.inst-hero__art {
    position: absolute;
    top: 0;
    bottom: 0;
    right: 0;
    left: auto;
    width: min(66%, 140vh, 1600px);
    z-index: 1;
    pointer-events: none;
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 12%, #000 88%, transparent 100%);
    mask-image: linear-gradient(to bottom, transparent 0%, #000 12%, #000 88%, transparent 100%);
    animation: instArtIn 1.2s ease-out both;
}

.inst-hero__art-x {
    position: absolute;
    inset: 0;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.35) 12%, #000 26%, #000 100%);
    mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.35) 12%, #000 26%, #000 100%);
}

.inst-hero__art-inner {
    position: absolute;
    inset: 0;
    opacity: 0.85;
    transform-origin: 60% 50%;
    -webkit-mask-image: radial-gradient(circle at 58% 50%, #000 30%, rgba(0, 0, 0, 0.55) 50%, transparent 72%);
    mask-image: radial-gradient(circle at 58% 50%, #000 30%, rgba(0, 0, 0, 0.55) 50%, transparent 72%);
    animation: instDrift 42s ease-in-out 1.2s infinite alternate;
}

.inst-hero__art svg {
    width: 100%;
    height: 100%;
    display: block;
}

    .inst-hero__art svg * {
        vector-effect: non-scaling-stroke;
    }

.inst-hero__copy {
    position: relative;
    z-index: 2;
    width: min(1120px, 58vw);
    min-width: 0;
    padding: clamp(96px, 13vh, 176px) clamp(24px, 6vw, 120px);
    text-align: left;
}

    .inst-hero__copy::before {
        content: "";
        position: absolute;
        z-index: -1;
        inset: -16% -26%;
        pointer-events: none;
        background: radial-gradient(ellipse at 36% 50%, rgba(11, 15, 26, 0.95) 0%, rgba(11, 15, 26, 0.7) 46%, rgba(11, 15, 26, 0) 74%);
    }

.inst-hero__eyebrow {
    display: inline-flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0 0 26px;
    padding: 9px 16px;
    border: 1px solid rgba(55, 201, 165, 0.28);
    border-radius: var(--radius-md);
    background: rgba(55, 201, 165, 0.07);
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--accent-teal);
    animation: instRise 0.6s var(--ease-out) 0.05s both, instEyebrowGlow 3.6s ease-in-out 0.6s infinite;
}

.inst-hero__pulse {
    flex: none;
    width: 8px;
    height: 8px;
    margin-top: 0.42em;
    border-radius: 50%;
    background: var(--accent-teal);
    box-shadow: 0 0 10px rgba(55, 201, 165, 0.7);
    animation: instPulse 3.6s ease-in-out infinite;
}

.inst-hero__eyebrow-text {
    display: block;
    min-width: 0;
    line-height: 1.5;
    padding-top: 1px;
}

@media (max-width: 440px) {
    .inst-hero__eyebrow {
        font-size: 0.57rem;
    }
}

.inst-hero__title {
    margin: 0 0 28px;
    padding: 0 0 0.12em;
    font-size: clamp(2.125rem, 4.6vw, 5.5rem);
    font-weight: 800;
    line-height: 1.06;
    letter-spacing: -0.02em;
    background: var(--grad-hero-text);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: instRise 0.6s var(--ease-out) 0.15s both;
}

.inst-hero__line {
    display: block;
    white-space: nowrap;
}

.inst-hero__lead {
    margin: 0;
    max-width: 640px;
    font-size: clamp(1.0625rem, 0.95rem + 0.45vw, 1.375rem);
    line-height: var(--leading-relaxed);
    color: var(--text-muted);
    animation: instRise 0.6s var(--ease-out) 0.28s both;
}

.inst-hero__cue {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: clamp(40px, 6vh, 72px);
    color: var(--text-faint);
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    letter-spacing: 0.22em;
    text-transform: uppercase;
    text-decoration: none;
    transition: color 0.3s ease;
    animation: instRise 0.6s var(--ease-out) 0.4s both;
}

    .inst-hero__cue:hover {
        color: var(--text-muted);
    }

    .inst-hero__cue svg {
        width: 14px;
        height: 14px;
        animation: instCueBob 2.4s ease-in-out infinite;
    }

.inst-pulse {
    animation: instPulse 3.6s ease-in-out infinite;
}

.inst-pulse-alt {
    animation-delay: 1.8s;
}

.inst-dash {
    animation: instDash 60s linear infinite;
}

@keyframes instRise {
    from {
        opacity: 0;
        transform: translateY(22px);
    }

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

@keyframes instArtIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes instDrift {
    from {
        transform: scale(1);
    }

    to {
        transform: scale(1.035);
    }
}

@keyframes instCueBob {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(4px);
    }
}

@keyframes instPulse {
    0%, 100% {
        opacity: 0.45;
    }

    50% {
        opacity: 1;
    }
}

@keyframes instDash {
    to {
        stroke-dashoffset: -240;
    }
}

@keyframes instEyebrowGlow {
    0%, 100% {
        border-color: rgba(55, 201, 165, 0.22);
        text-shadow: 0 0 0 rgba(55, 201, 165, 0);
    }

    50% {
        border-color: rgba(55, 201, 165, 0.5);
        text-shadow: 0 0 14px rgba(55, 201, 165, 0.45);
    }
}

/*
 * Light theme overrides. The art layer uses theme-neutral strokes;
 * only the copy scrim and eyebrow tint need remapping.
 */
[data-theme="light"] .inst-hero__copy::before {
    background: radial-gradient(ellipse at 36% 50%, rgba(244, 246, 250, 0.95) 0%, rgba(244, 246, 250, 0.7) 46%, rgba(244, 246, 250, 0) 74%);
}

[data-theme="light"] .inst-hero__eyebrow {
    border-color: rgba(15, 118, 110, 0.28);
    background: rgba(15, 118, 110, 0.07);
}

@keyframes instEyebrowGlowLight {
    0%, 100% {
        border-color: rgba(15, 118, 110, 0.22);
        text-shadow: 0 0 0 rgba(15, 118, 110, 0);
    }

    50% {
        border-color: rgba(15, 118, 110, 0.5);
        text-shadow: 0 0 14px rgba(15, 118, 110, 0.35);
    }
}

[data-theme="light"] .inst-hero__eyebrow {
    animation: instRise 0.6s var(--ease-out) 0.05s both, instEyebrowGlowLight 3.6s ease-in-out 0.6s infinite;
}

[data-theme="light"] .inst-hero__pulse {
    box-shadow: 0 0 10px rgba(15, 118, 110, 0.5);
}

@media (max-width: 1500px) {
    .inst-hero__art-x {
        -webkit-mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.3) 14%, #000 32%, #000 100%);
        mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.3) 14%, #000 32%, #000 100%);
    }
}

@media (max-width: 1100px) {
    .inst-hero__art {
        width: min(74%, 140vh, 1600px);
    }
}

@media (max-width: 768px) {
    .inst-hero {
        align-items: flex-start;
    }

    .inst-hero__art {
        top: 0;
        bottom: auto;
        left: 0;
        right: 0;
        width: 100%;
        height: max(30vh, 220px);
        -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 55%, transparent 100%);
        mask-image: linear-gradient(to bottom, #000 0%, #000 55%, transparent 100%);
    }

    .inst-hero__art-x {
        -webkit-mask-image: none;
        mask-image: none;
    }

    .inst-hero__art-inner {
        opacity: 0.5;
        transform-origin: 50% 30%;
        -webkit-mask-image: radial-gradient(circle at 50% 30%, #000 22%, rgba(0, 0, 0, 0.5) 42%, transparent 68%);
        mask-image: radial-gradient(circle at 50% 30%, #000 22%, rgba(0, 0, 0, 0.5) 42%, transparent 68%);
    }

    .inst-hero__copy {
        width: 100%;
        padding: max(32vh, 240px) 20px 72px;
    }

    .inst-hero__eyebrow {
        letter-spacing: 0.14em;
        margin-bottom: 18px;
    }

    .inst-hero__title {
        font-size: clamp(1.75rem, 8.5vw, 2.25rem);
        margin-bottom: 18px;
    }

    .inst-hero__lead {
        max-width: none;
        font-size: var(--text-base);
    }

    .inst-hero__cue {
        margin-top: 36px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .inst-hero__eyebrow, .inst-hero__title, .inst-hero__lead, .inst-hero__cue,
    .inst-hero__cue svg, .inst-hero__art, .inst-hero__art-inner,
    .inst-pulse, .inst-dash, .inst-hero__pulse {
        animation: none !important;
    }

    .inst-hero__eyebrow {
        border-color: rgba(55, 201, 165, 0.35);
    }

    [data-theme="light"] .inst-hero__eyebrow {
        border-color: rgba(15, 118, 110, 0.35);
    }
}
