/* --- NAVBAR & LOGO --- */
.site-header-wrapper {
    position: absolute;
    top: 100px;
    left: 0;
    width: 100%;
    height: 120px;
    z-index: 10;

    animation: fade-in-down 0.5s ease-out 0.4s backwards;
}

.site-logo {
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 30;
    text-align: center;
    text-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);
    overflow: visible;
    width: 800px;
    max-width: calc(100% - 40px);
    box-sizing: border-box;
    --bar-width: 1px;
    --logo-clip: 0px;
    --fade-width: 24px;
}
.site-logo a {
    text-decoration: none;
    color: #333;
    display: inline-flex;
    align-items: center;
    text-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);
    position: relative;
    justify-content: center;
}
.site-logo .logo-text-large { padding-right: 4px; margin-right: 4px; margin-bottom: 3px; }
.site-logo .logo-text-small { padding-left: 8px; margin-left: 4px; margin-bottom: 3px; }

.site-logo .logo-inner {
    display: inline-block;
    font-family: Arial, sans-serif;
    white-space: nowrap;
    position: relative;
    z-index: 2;
}

.site-logo .logo-text-large .logo-inner {
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -1px;
    transform: translateX(100%);
    color: transparent;
    -webkit-text-fill-color: transparent;
    animation: logo-slide-large 500ms cubic-bezier(0.25, 0.46, 0.45, 0.94) 600ms forwards;
}

.site-logo .logo-text-large .logo-inner::after {
    content: attr(data-text);
    position: absolute;
    left: 0;
    top: 0;
    z-index: 3;
    white-space: nowrap;
    /*
    color: #0f0f0f;
    -webkit-text-fill-color: #0f0f0f;
    */
    background: linear-gradient(to bottom, #000000 0%, #000000 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent; /* Fallback */

    font-weight: 800;
    font-size: 28px;
    font-family: Arial, sans-serif;
    line-height: 1;
    display: inline-block;
    pointer-events: none;
    text-shadow: 0 6px 10px rgba(255, 255, 255, 0.5);
    animation: shadow-flicker 0.06s linear infinite;
}

.site-logo .logo-text-small .logo-inner::after {
    content: attr(data-text);
    position: absolute;
    left: 0;
    top: 0;
    z-index: 3;
    white-space: nowrap;
    color: #666;
    -webkit-text-fill-color: #666;
    font-family: Arial, sans-serif;
    line-height: 1;
    display: inline-block;
    pointer-events: none;
    animation: shadow-flicker 0.06s linear infinite;
}

.site-logo .logo-inner::before {
    content: attr(data-text);
    position: absolute;
    left: 0;
    top: 0;
    z-index: 1;
    color: rgba(0,0,0,0.65);
    white-space: nowrap;
    pointer-events: none;
    transform: translateY(3px);
    filter: blur(4px);
    opacity: 0.85;
    animation: flicker-shadow 0.12s linear infinite;
}

.site-logo .logo-inner {
    color: transparent !important;
    -webkit-text-fill-color: transparent !important;
    text-shadow: none !important;
}

.site-logo .logo-text-small .logo-inner {
    font-size: 16px;
    font-weight: 400;
    transform: translateX(-100%);
    animation: logo-slide-small 500ms cubic-bezier(0.25, 0.46, 0.45, 0.94) 600ms forwards;
}

.site-logo a::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: var(--bar-width);
    height: 48px;
    background: rgba(0,0,0,0.2);
    border-radius: 1px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.06);
    z-index: 40;
    pointer-events: none;
}

.site-logo a > * {
    position: relative;
    z-index: 20;
}

.site-logo .logo-text-large,
.site-logo .logo-text-small {
    display: inline-block;
    overflow-x: hidden;
    overflow-y: hidden;
    white-space: nowrap;
    vertical-align: bottom;
    box-sizing: border-box;
    max-width: calc(50% - (var(--bar-width) / 2) - var(--logo-clip));
    -webkit-mask-size: 100% 100%; 
    mask-size: 100% 100%; 
    -webkit-mask-repeat: no-repeat; 
    mask-repeat: no-repeat;
}
.site-logo .logo-text-large { text-align: right; }
.site-logo .logo-text-small { text-align: left; }

.site-logo .logo-text-large {
    -webkit-mask-image: linear-gradient(to right, rgba(0,0,0,1) 0%, rgba(0,0,0,1) calc(100% - var(--fade-width)), rgba(0,0,0,0) 100%);
    mask-image: linear-gradient(to right, rgba(0,0,0,1) 0%, rgba(0,0,0,1) calc(100% - var(--fade-width)), rgba(0,0,0,0) 100%);
}
.site-logo .logo-text-small {
    -webkit-mask-image: linear-gradient(to left, rgba(0,0,0,1) 0%, rgba(0,0,0,1) calc(100% - var(--fade-width)), rgba(0,0,0,0) 100%);
    mask-image: linear-gradient(to left, rgba(0,0,0,1) 0%, rgba(0,0,0,1) calc(100% - var(--fade-width)), rgba(0,0,0,0) 100%);
}

@keyframes logo-slide-large {
    from { transform: translateX(100%); }
    to   { transform: translateX(0); }
}
@keyframes logo-slide-small {
    from { transform: translateX(-100%); }
    to   { transform: translateX(0); }
}
@keyframes flicker-shadow {
    0%   { opacity: 0.9; filter: blur(4px); transform: translateY(3px); }
    50%  { opacity: 0.45; filter: blur(3px); transform: translateY(2px); }
    100% { opacity: 0.9; filter: blur(4px); transform: translateY(3px); }
}
@keyframes shadow-flicker {
    0%   { text-shadow: 0 6px 10px rgba(0,0,0,0.55); }
    50%  { text-shadow: 0 3px 5px rgba(0,0,0,0.28); }
    100% { text-shadow: 0 6px 10px rgba(0,0,0,0.55); }
}

/* --- NAVBAR TIERS & CONTAINER --- */
.nav-tiers {
    position: relative;
    top: 70px;
    z-index: 20;
}

.nav-content-container {
    width: 800px;
    max-width: calc(100% - 40px);
    box-sizing: border-box;
    margin: 0 auto;
    height: 100%;
    background: #ffffff;
    position: relative;
    box-shadow: 0 -1px 0 #bababa inset;
    
    /* --- VARIABLES --- */
    --v-depth: 40px;
    --v-half: 40px;
    --nav-fade-width: 50px;
    --nav-center-gap: 20px;
    --nav-edge-spacing: 50px;

    padding: 5px var(--nav-edge-spacing);

    /* --- FADE MASK --- */
    -webkit-mask-image: linear-gradient(to right,
        rgba(0,0,0,0) 0%,
        rgba(0,0,0,1) var(--nav-fade-width),
        rgba(0,0,0,1) calc(100% - var(--nav-fade-width)),
        rgba(0,0,0,0) 100%
    );
    mask-image: linear-gradient(to right,
        rgba(0,0,0,0) 0%,
        rgba(0,0,0,1) var(--nav-fade-width),
        rgba(0,0,0,1) calc(100% - var(--nav-fade-width)),
        rgba(0,0,0,0) 100%
    );

    /* --- LAYOUT --- */
    display: flex;
    justify-content: center;
    align-items: center;

    /* --- V-NOTCH CLIP-PATH --- */
    clip-path: polygon(
        0% 0%,
        calc(50% - var(--v-half)) 0%,
        50% var(--v-depth),
        calc(50% + var(--v-half)) 0%,
        100% 0%,
        100% 100%,
        0% 100%
    );

}

nav.nav-main-tier {
    height: 45px;
    position: relative;
}

/* --- BUTTON STYLES --- */
nav.nav-main-tier a {
    color: #333;
    text-decoration: none;
    text-transform: uppercase;
    font-family: sans-serif;
    font-size: 12px;
    font-weight: bold;
    
    --button-height: 34px; 
    --border-width: 1px; /* The border thickness */

    display: inline-flex; 
    align-items: center;
    justify-content: center;
    min-width: clamp(70px, 12vw, 110px);
    height: var(--button-height);
    
    padding-left: clamp(6px, 1.5vw, 10px);
    padding-right: clamp(6px, 1.5vw, 10px);
    
    box-sizing: border-box;
    white-space: nowrap;
    
    position: relative;
    background: transparent;
    border: none;
    transition: none;
    border-radius: 0;
}

/* This ::after is the BORDER layer */
nav.nav-main-tier a::after {
    content: '';
    position: absolute;
    inset: 0; /* Sits at the edges */
    z-index: 1; /* Sits behind the background */
    
    /* This is the border color */
    background: #ccc; 
    
    border-radius: 0;
    transition: all 0.18s ease-in-out;
}

/* This ::before is the BACKGROUND layer */
nav.nav-main-tier a::before {
    content: '';
    position: absolute;
    
    /* This makes it 1px smaller on all sides */
    inset: var(--border-width); 
    
    z-index: 2; /* Sits on top of the border layer */
    
    border-radius: 0; 
    background: linear-gradient(to bottom, #ffffff, #f0f0f0);
    transition: all 0.18s ease-in-out;
}

/* This <span> holds the text on top */
nav.nav-main-tier a span {
    position: relative;
    z-index: 3; /* Sits on top of everything */
}

/* --- BUTTON HOVER --- */
nav.nav-main-tier a:hover {
    color: #333;
}

/* Change the BACKGROUND on hover */
nav.nav-main-tier a:hover::before {
	/* We replace the simple 'background' property with 
    stacked 'background-image' layers and 'background-size'
    */
    
    /* --- NEW STYLES --- */
    
    /* Stacked background images. Order matters: top layer is first. */
	background-image:
		/* 1. Scan lines (top layer) */
		repeating-linear-gradient(
			to bottom,
			transparent,
			transparent 2px,
			rgba(160, 160, 160, 0.12) 2px, /* Slightly darker for the pink */
			rgba(189, 189, 189, 0.12) 3px
		),
		/* 2. Vignette (middle layer) */
		radial-gradient(
			ellipse at center,
			transparent 50%,
			rgba(0, 0, 0, 0.15) 100% /* Slightly darker */
		),
		/* 3. Pink gradient (bottom layer) */
		linear-gradient(to bottom, #fccddb, #fdeaf0);

    /* Define size for each background image */
	background-size:
		100% 3px,  /* Size for scan lines */
		100% 100%, /* Size for vignette */
		100% 100%; /* Size for pink gradient */

    /* Apply the flicker animation (defined in style.css) */
	animation: crt-flicker 0.04s steps(2, end) infinite;
}

/* Change the BORDER on hover */
nav.nav-main-tier a:hover::after {
    /* Use a darker pink so it's visible! */
    background: #e69ab0; 
}

/* --- BUTTON LAYOUT GROUPS --- */
.nav-links-left,
.nav-links-right {
    display: flex;
    gap: 5px;
    align-items: center;
    flex: 0 0 auto;
}

.nav-links-left {
    margin-right: calc(var(--nav-center-gap) / 2);
}

.nav-links-right {
   margin-left: calc(var(--nav-center-gap) / 2);
}

/* --- ANGLED BUTTONS (V-NOTCH) --- */

/* Apply clip-path to BOTH ::before (background) and ::after (border) */
.nav-links-left a:last-child::before,
.nav-links-left a:last-child::after {
    clip-path: polygon(
        0% 0%,
        calc(100% - var(--button-height)) 0%,
        100% 100%,
        0% 100%
    );
}

.nav-links-right a:first-child::before,
.nav-links-right a:first-child::after {
    clip-path: polygon(
        var(--button-height) 0%,
        100% 0%,
        100% 100%,
        0% 100%
    );
}

/* Add extra padding to the <a> layout box to "extend" it */
.nav-links-left a:last-child {
    padding-right: calc(clamp(6px, 1.5vw, 10px) + (var(--button-height) / 2));
}

.nav-links-right a:first-child {
    padding-left: calc(clamp(6px, 1.5vw, 10px) + (var(--button-height) / 2));
}

body.no-animation .site-header-wrapper {
    animation: none;
}

body.no-animation .site-logo .logo-text-large .logo-inner,
body.no-animation .site-logo .logo-text-small .logo-inner {
    animation: none;
    transform: translateX(0);
}

/* --- RESPONSIVE --- */
@media (max-width: 600px) {
    .nav-content-container {
        padding: 0 12px;
        --v-half: 30px;
        --v-depth: 30px;
    }

    nav.nav-main-tier a {
        min-width: 60px;
        padding-left: 6px;
        padding-right: 6px;
        font-size: 11px;
    }

    /* Reset angled padding on small screens */
    .nav-links-left a:last-child {
        padding-right: 6px;
    }
    .nav-links-right a:first-child {
        padding-left: 6px;
    }
}

@keyframes fade-in-down {
    0% {
        opacity: 0;
        /* Start 10px *up* and slightly smaller */
        transform: scale(0.98) translateY(-10px);
    }
    100% {
        opacity: 1;
        /* End at normal position and size */
        transform: scale(1) translateY(0);
    }
}