* { box-sizing: border-box; }

@font-face {
  font-family: 'NY';
  src: url('fonts/CMMCoda-Proportional.woff2') format('woff2');
  font-display: swap;
}

@font-face {
  font-family: 'NM';
  src: url('fonts/Mono-Regular.woff2') format('woff2');
  font-display: swap;
}

html, body, #text-grid, .ad-entry, .header-col, .header-col a, .ad-clickable-area, .ad-tag, .filter-tag, .scan-control-btn, .control-btn, .clear-search-btn, .clear-filters-btn {
    cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' style='fill:%231bcd00;font-family:serif;font-size:24px'%3E%3Ctext y='24'%3E%E2%87%96%3C/text%3E%3C/svg%3E") 0 10, auto !important;
}

html { height: 100%; margin: 0; padding: 0; scroll-behavior: smooth; }

body {
    background-color: #ffffff;
    color: #0005a2;
    font-family: 'NY', serif;
    letter-spacing: -0.2px;
    margin: 0;
    padding: 0;
    min-height: 100%;
    width: 100%;
    font-feature-settings: "salt" 0;
}

::selection {
    background: #1bcd00;
    color: #ffffff;
}

::-moz-selection {
    background: #1bcd00;
    color: #ffffff;
}


.site-header {
    display: flex;
    position: fixed;
    top: 0; 
    left: 0; 
    right: 0;
    width: 100%;
    height: 25px;
    background-color: #ffffff;
    z-index: 2000;
    font-size: 0.8rem;
    justify-content: space-between;
    color: #1bcd00;
    pointer-events: none; 
}

.header-col { padding: 5px 15px; display: flex; align-items: center; pointer-events: auto; }
.header-col a { padding: 10px;  margin: -10px; text-decoration: none; color: inherit; display: inline-block; }

.header-col a:hover,
.header-col a.active { 
    text-decoration: underline; 
    text-decoration-color: #1bcd00; 
    text-underline-offset: 2px;
    text-decoration-skip-ink: auto;
}

#scan-header-meta { color: #1bcd00; }

#search-bar {
    background: transparent;
    border: none;
    border-bottom: 1px solid transparent;
    color: #1bcd00;
    font-family: 'NY', serif;
    font-size: 0.8rem;
    width: 100px;
    outline: none;
    transition: width 0.3s ease, border-bottom 0.3s ease;
}

#search-bar:focus { width: 200px; border-bottom: 1px solid #1bcd00; }
#search-bar::placeholder { color: #1bcd00; }

.archive-container {
    padding-top: 600px; 
    padding-bottom: 100px;
    width: 100%;
    transition: padding-top 0.2s ease;
}

body.filter-open .archive-container { padding-top: 160px; }

#text-grid { width: 100%; position: relative; display: block; margin: 0 auto; padding: 0 10px; }
.grid-sizer, .ad-entry { width: 24.33%; }
.gutter-sizer { width: 0.88%; }

.ad-entry { margin-bottom: 50px; background: #ffffff; padding: 5px; scroll-margin-top: 160px; }
.ad-meta { font-size: 0.8rem; line-height: 1.3; margin-bottom: 10px; }
.ad-text { font-size: .8rem; line-height: 1.3;  }

.ad-clickable-area:hover .ad-meta,
.ad-clickable-area:hover .ad-text,
.ad-entry.is-active .ad-meta,
.ad-entry.is-active .ad-text { color: #1bcd00; }

.ad-tags-container { 
    margin-top: 14px; 
    display: flex; 
    flex-wrap: wrap; 
    column-gap: 20px; 
    row-gap: 12px; 
}

.ad-tag { 
    font-family: NM; 
    font-size: 0.65rem; 
    text-transform: uppercase; 
    color: #0005a2; 
    line-height: 1; 
    display: inline-block; 
    padding: 6px 10px; 
    margin: -6px -10px; 
}

.ad-tag:hover { color: #1bcd00; }

.image-viewer { position: fixed; z-index: 3000; width: 400px; pointer-events: none; opacity: 0; transition: opacity 0.2s ease; }
.image-viewer img { width: 100%; height: auto; display: block; }

#scan-overlay {
    display: none;
    position: fixed;
    top: 0; 
    left: 0; 
    width: 100vw; 
    height: 100vh;
    z-index: 3500;
    justify-content: center;
    align-items: center;
    background: transparent;
    pointer-events: none; 
}

#scan-overlay.is-visible { 
    display: flex; 
    pointer-events: none; /* Allows clicks to pass through the transparent backdrop to underlying tags */
}

#scan-image,
.scan-controls {
    pointer-events: auto; /* Keeps the scan image and navigation buttons interactive */
}

#scan-image.zoomed {
    scale: 2; 
    
    /* 1. Kill the animation entirely instead of pausing it, preventing freezing at weird angles */
    animation: none; 
    
    /* 2. Force the image perfectly flat so the transform-origin pivot doesn't cause a wobble */
    transform: rotate(0deg); 
    
    /* 3. Strip ALL CSS transitions so the image tracks the mouse instantly without rubber-banding */
    transition: none; 
}

#scan-image {
    max-width: 85vw;
    max-height: 80vh;
    pointer-events: auto;
    box-shadow: 0 0 40px rgba(27, 205, 0, 0.7);
    animation: subtleTilt 10s ease-in-out infinite;
    transform-origin: center center;
    /* Removed transform-origin from the transition */
    transition: scale 0.4s ease; 
}

.scan-controls {
    position: absolute;
    bottom: 40px;
    display: flex;
    gap: 15px;
    z-index: 3600;
    pointer-events: auto;
}

.scan-control-btn {
    background-color: #1bcd00 !important;
    color: #ffffff !important;
    border: 1px solid #1bcd00 !important;
    padding: 10px 18px !important;
    box-shadow: 0 0 12px rgba(27, 205, 0, 0.4);
    font-family: 'NY';
    font-size: 1rem;
    animation: gentleTilt 3s ease-in-out infinite;
    transform-origin: center;
    line-height: 1;
    will-change: transform;
}


.scan-control-btn.arrow-btn {
    font-family: 'NY';
    font-size: 1.5rem;
    padding: 2px 15px 4px 15px;
}

.scan-control-btn:nth-child(even) { animation-delay: -1.5s; }
.scan-control-btn:disabled { opacity: 0.3; pointer-events: none; animation: none; }

.scan-control-btn:hover,
.scan-control-btn:active {
    background-color: #ffffff !important;
    color: #1bcd00 !important;
    border: 1px solid #1bcd00 !important;
}

.filter-menu {
    display: none; 
    position: fixed;
    top: 25px; /* Extended from top to cover the main grid */
    bottom: 25px; 
    left: 0;
    width: 100%;
    z-index: 1500;
    font-size: 0.8rem;
    color: #1bcd00;
    padding: 15px 40px 15px 40px;
    flex-direction: column; 
    align-items: center; 
    justify-content: flex-end; /* Keeps the filter tags positioned at the bottom */
  background: radial-gradient(
        ellipse 65% 55% at bottom center,
        rgba(255, 255, 255, 0.98) 0%,
        rgba(255, 255, 255, 0.85) 35%,
        rgba(255, 255, 255, 0) 100%
    );}

.entry-counter {
    position: fixed;
    top: 50px;
    left: 0;
    right: 0;
    margin: 0 auto;
    width: max-content; /* Ensures the boundaries snap strictly to the text length */
    background-color: #1bcd00;
    color: #ffffff;
    border: 1px solid #1bcd00;
    padding: 4px 10px;
    box-shadow: 0 0 12px rgba(27, 205, 0, 0.4);
    animation: gentleTilt 3s ease-in-out infinite;
    transform-origin: center;
    font-family: inherit;
    font-size: inherit;
    line-height: normal;
    box-sizing: border-box;
    pointer-events: none;
    user-select: none;
    z-index: 1501;
}

.filter-menu.is-visible { 
    display: flex; 
    pointer-events: auto; /* Activates the gradient container as a solid click shield */
}

.filter-group { 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    flex-wrap: wrap;
    pointer-events: auto; 
    margin: 5px 0; 
    transition: max-height 0.4s ease, margin 0.4s ease, opacity 0.4s ease;
    max-height: 500px; 
    opacity: 1;
    overflow: hidden;
}

.category-label { 
    text-decoration: underline; 
     text-underline-offset: 2px;
    text-decoration-skip-ink: auto;
    display: inline-block;
    background-color: transparent;
    color: inherit;
    padding: 0;
    text-shadow: none;
    margin: 5px; 
}

.filter-group .category-label ~ .category-label { margin-left: 40px; }

.filter-tag { 
    background-color: #ffffff;
    color: #1bcd00;
    border: 1px solid #1bcd00;
    padding: 4px 10px;
    box-shadow: 0 0 12px rgba(27, 205, 0, 0.4); 
    display: inline-block;
    animation: gentleTilt 3s ease-in-out infinite;
    transform-origin: center;
    margin: 5px; 
    max-width: 300px; 
    white-space: nowrap;
    overflow: hidden;
    box-sizing: border-box; 
    opacity: 1;
    will-change: transform;
    transition: background-color 0.1s ease, color 0.1s ease, max-width 0.2s cubic-bezier(0.4, 0, 0.2, 1), padding 0.2s cubic-bezier(0.4, 0, 0.2, 1), margin 0.2s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.1s ease, border-width 0.2s ease;
}

.filter-tag.is-hidden {
    max-width: 0;
    padding-left: 0;
    padding-right: 0;
    margin-left: 0;
    margin-right: 0;
    border-width: 0;
    opacity: 0;
    pointer-events: none;
}

.filter-tag:nth-child(even) { animation-delay: -1.5s; }
.filter-tag:hover { text-decoration: underline;  text-underline-offset: 2px;
    text-decoration-skip-ink: auto; }
.filter-tag.active { text-decoration: none; background-color: #1bcd00; color: #ffffff; }

.clear-filters-btn {
    position: absolute;
    right: 40px; 
    bottom: 20px; 
    pointer-events: auto;
    background-color: #1bcd00;
    color: #ffffff;
    border: 1px solid #1bcd00;
    padding: 4px 10px; 
    box-shadow: 0 0 12px rgba(27, 205, 0, 0.4);
    display: none; 
    animation: gentleTilt 3s ease-in-out infinite;
    animation-delay: -0.75s; 
    transform-origin: center;
    font-family: inherit;
    font-size: inherit;
    line-height: normal;       
    box-sizing: border-box;    
    height: auto;
    vertical-align: middle;
}

.clear-filters-btn:hover { text-decoration: underline; text-underline-offset: 3px; }

.timeline-footer {
    display: flex;
    position: fixed;
    bottom: 0; 
    left: 0; 
    right: 0;
    width: 100%;
    height: 25px;
    background-color: #ffffff;
    z-index: 2000;
    font-size: 0.8rem;
    justify-content: space-between; 
    color: #1bcd00;
}
.footer-col { padding: 0 15px; display: flex; align-items: center; }
.footer-col a { text-decoration: none; color: inherit; padding: 10px; margin: -10px;}
.footer-col a:hover { text-decoration: underline; }

.site-header, .timeline-footer { z-index: 2000; pointer-events: auto; }

.rotating-text-wrapper {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 177px;
    height: 177px;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
    z-index: 500;
}

.rotating-text-wrapper svg {
    animation: rotateClockwise 10s linear infinite;
    transform-origin: center center;
    overflow: visible;
}

.rotating-text-wrapper text {
    font-family: 'NY';
    font-size: .8rem;
    fill: #1bcd00;
}

.control-btn {
    background: none;
    border: none;
    color: #1bcd00;
    font-family: 'NY';
    font-size: .8rem;
    padding: 20px; 
    margin: -10px;   
    line-height: 1;
}

.control-btn:hover { color: #0005a2; }

.about-overlay {
    display: none;
    position: fixed;
    top: 25px; 
    bottom: 25px;
    left: 0;
    width: 100vw;
    height: calc(100vh - 50px);
    background-color: #ffffff;
    z-index: 2500;
    padding: 80px 60px;
    overflow-y: auto;
}

.about-content { display: flex; width: 100%; }
.about-text-column { flex: 0 0 50%; padding-right: 60px; }
.about-empty-column { flex: 0 0 50%; }

.about-controls {
    position: fixed;
    top: 35px;
    right: 25px;
    z-index: 2600;
}

.search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.clear-search-btn {
    background: none;
    border: none;
    color: #1bcd00;
    font-family: 'NY', serif;
    font-size: 0.8rem;
    position: absolute;
    right: 5px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.clear-search-btn.visible {
    opacity: 1;
    pointer-events: auto;
}

/* Swaps the custom cursor colour to blue when overlying green elements */
.filter-tag.active, 
.clear-filters-btn,
.scan-control-btn:hover, 
.ad-clickable-area:hover, 
.ad-clickable-area:hover *,
.ad-tag:hover, 
.header-col a:hover, 
.header-col a.active,
#scan-overlay {
    cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' style='fill:%230005a2;font-family:serif;font-size:24px'%3E%3Ctext y='24'%3E%E2%87%96%3C/text%3E%3C/svg%3E") 0 10, auto !important;
}

.active-indicator-btn {
    position: fixed;
    right: 40px; 
    bottom: 45px; 
    pointer-events: auto;
    background-color: #1bcd00;
    color: #ffffff;
    border: 1px solid #1bcd00;
    padding: 4px 10px; 
    box-shadow: 0 0 12px rgba(27, 205, 0, 0.4);
    display: none; 
    animation: gentleTilt 3s ease-in-out infinite;
    animation-delay: -0.75s; 
    transform-origin: center;
    font-family: inherit;
    font-size: .8rem;
    line-height: normal;       
    box-sizing: border-box;    
    height: auto;
    vertical-align: middle;
    z-index: 1400; /* Placed cleanly behind the visible menu but above the grid stack */
}

.active-indicator-btn:hover { 
    text-decoration: underline; 
    text-underline-offset: 3px; 
}

/* Ensure custom active cursor colors adapt seamlessly to the new indicator element */
.active-indicator-btn:hover {
    cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' style='fill:%230005a2;font-family:serif;font-size:24px'%3E%3Ctext y='24'%3E%E2%87%96%3C/text%3E%3C/svg%3E") 0 10, auto !important;
}

#scroll-progress {
    position: absolute;
    top: 0;
    left: 0;
    height: 1.5px;
    background-color: #1bcd00;
    width: 0%;
    z-index: 2001;
    pointer-events: none;
    will-change: width;
}

.search-highlight {
    background-color: #1bcd00;
    color: #ffffff;
}

.search-counter {
    position: fixed;
    top: 50px;
    left: 0;
    right: 0;
    margin: 0 auto;
    width: max-content; /* Ensures the boundaries snap strictly to the text length */
    background-color: #1bcd00;
    color: #ffffff;
    border: 1px solid #1bcd00;
    padding: 4px 10px;
    box-shadow: 0 0 12px rgba(27, 205, 0, 0.4);
    animation: gentleTilt 3s ease-in-out infinite;
    transform-origin: center;
    font-family: inherit;
    font-size: inherit;
    line-height: normal;
    box-sizing: border-box;
    pointer-events: none;
    user-select: none;
    white-space: nowrap;
    z-index: 1501;
}
.about-page-container {
    padding-top: 80px;
    padding-left: 10px !important;
    padding-right: 10px !important;
    padding-bottom: 100px;
    box-sizing: border-box;
    width: 100%;
}

.about-content {
    display: flex;
    width: 100% !important;
    margin: 0 10px 0 10px !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    gap: 1.77%;
}

.about-text-column,
.about-legal-column {
    flex: 0 0 49.11%;
    padding: 0 !important;
    margin: 0 !important;
    box-sizing: border-box !important;
}

.legal-footer-split {
    display: flex;
    gap: 1.77%;
    margin-top: 20px;
}

.legal-subcol {
    flex: 1;
}

.ad-text a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 2px;
    text-decoration-skip-ink: auto;
}

.ad-text a:hover {
    text-decoration: underline;
    color: #1bcd00;
}

.mobile-archive-title {
    display: none;
}

.about-page .about-content {
    padding: 0 10px !important;
    box-sizing: border-box !important;
}

/* Responsive Scaling synchronized with Main Grid Breakpoints */
@media (max-width: 1300px) {
    .about-content { gap: 1%; }
}

@media (max-width: 1000px) {
    .about-content { gap: 2%; }
}

@media (max-width: 600px) {
    .about-content {
        flex-direction: column;
        gap: 50px;
    }
    
    .about-text-column,
    .about-legal-column {
        flex: 0 0 100%;
    }

    .legal-footer-split {
        flex-direction: row; /* Keeps quick info sub-columns side-by-side */
        gap: 4%;
    }
}


@keyframes rotateClockwise {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes gentleTilt {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-3deg); }
    75% { transform: rotate(3deg); }
}

@keyframes subtleTilt {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-1.5deg); }
    75% { transform: rotate(1.5deg); }
}

@media (max-width: 1300px) { .grid-sizer, .ad-entry { width: 32.66%; } .gutter-sizer { width: 1%; } }
@media (max-width: 1000px) { .grid-sizer, .ad-entry { width: 49%; } .gutter-sizer { width: 2%; } }
@media (max-width: 600px) { .grid-sizer, .ad-entry { width: 100%; } .gutter-sizer { width: 0%; } }


@media (max-width: 600px) {
    /* Prevent horizontal overflow and ensure uniform margins */
    html, body {
        overflow-x: hidden;
        width: 100%;
        margin: 0;
        padding: 0;
        box-sizing: border-box;
    }
    body.filter-open {
        background-color: #1bcd00 !important;
        overflow: hidden !important;
        height: 100vh !important;
    }

    #active-filters-indicator {
        display: none !important;
    }

    /* 2. Hide mobile scroll slider, badge, and overlay items when filter is open */
    body.filter-open #mobile-year-slider,
    body.filter-open #mobile-scroll-year-badge,
    body.filter-open .mobile-year-overlay-item {
        display: none !important;
    }

    .site-header .header-col {
        padding: 0 !important;
    }

    

    /* Set all text to 0.9rem */
    body,
    .ad-entry,
    .ad-meta,
    .ad-text,
    .site-header,
    .footer-col,
    .mobile-filter-footer button,
    .mobile-scroll-year-badge,
    .mobile-year-overlay-item,
    .about-page-container,
    .about-text-column,
    .about-legal-column,
    .ad-text,
    #search-bar,
    .header-col a,
    .header-col {
        font-size: 0.9rem !important;
    }

    /* Reduce size of tags underneath each entry */
    .ad-tag {
        font-size: 0.75rem !important;
        padding: 2px 5px !important;
        margin: -2px -5px !important;
    }
    .ad-tags-container {
        column-gap: 20px !important;
        row-gap: 6px !important;
    }

    /* Main grid & container margins matched precisely to legal text (10px) */
    .archive-container,
    .about-page-container {
        padding-left: 10px !important;
        padding-right: 10px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    .archive-container {
        padding-top: 10px !important;
        padding-bottom: 70px !important;
    }
    #text-grid {
        width: 100% !important;
        padding: 0 !important;
        margin: 0 !important;
        box-sizing: border-box !important;
    }
    /* Remove entry padding so text aligns flush with 10px container margin */
    .ad-entry {
        width: 100% !important;
        margin: 0 0 70px 0 !important;
        padding: 0 !important;
        background: transparent !important;
        box-sizing: border-box !important;
    }

    /* Scrap old timeline */
    .timeline-footer { display: none !important; }

    /* Footer menu width and padding configuration */
    .site-header {
        top: auto !important;
        bottom: 0 !important;
        height: 40px !important;
        background-color: #ffffff !important;
        border-top: none !important;
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        padding: 0 10px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    /* Precise 3-column distribution for Filter, Suchen, and About on the main page */
    .site-header #nav-filter {
        display: flex !important;
        flex: 1;
        justify-content: flex-start !important;
        padding: 0 !important;
    }
    
    .site-header #nav-search {
        display: flex !important;
        flex: 1;
        justify-content: center !important;
        padding: 0 !important;
    }
    
    .site-header #nav-about {
        display: flex !important;
        flex: 1;
        justify-content: flex-end !important;
        padding: 0 !important;
    }

    #search-bar { width: 70px !important; text-align: center; }
    #search-bar:focus { width: 110px !important; }

    /* Hide ONLY the main archive title column if present, leaving navigation structure intact */
    .site-header > .header-col:has(a[href="#"]),
    #scan-header-meta {
        display: none !important;
    }

    /* Remove underline from active/About button */
    .header-col a.active {
        text-decoration: none !important;
    }

    /* Add 50vh margin between page title and first ad entry */
    .mobile-archive-title {
        display: block !important;
        font-family: 'NY', serif;
        color: #1bcd00 ;
        padding: 2vh 0 45vh 0 !important;
        line-height: 1.3;
        font-size: 1.2rem !important;
        text-align: center;
        /* -webkit-text-stroke: 1px #1bcd00; */
    }
    .mobile-archive-title a {
        text-decoration: none;
        color: inherit;
    }

    /* Scrap second current-year indicator */
    .mobile-floating-year {
        display: none !important;
    }

    /* Scroll wheel: smaller by default, grows when interacted with */
    .mobile-year-slider {
        display: block !important;
        position: fixed !important;
        right: 6px !important;
        width: 10px !important;
        height: 35px !important;
        background-color: #1bcd00 !important;
        border: 1px solid #ffffff !important;
        border-radius: 5px !important;
        z-index: 3500;
        opacity: 0;
        transition: width 0.2s ease, height 0.2s ease, opacity 0.2s ease;
        cursor: pointer;
        transform: translateY(-50%);
    }
    .mobile-year-slider.visible {
        opacity: 1;
    }
    .mobile-year-slider.active-slider {
        width: 18px !important;
        height: 70px !important;
        border-radius: 9px !important;
    }

    /* Current-year indicator sticky next to scroll wheel (pushed above static entries) */
    .mobile-scroll-year-badge {
        display: block !important;
        position: fixed !important;
        right: 28px !important;
        transform: translateY(-50%) !important;
        background-color: #1bcd00 !important;
        color: #ffffff !important;
        border: 1px solid #ffffff !important;
        padding: 2px 8px;
        font-size: 0.9rem !important;
        z-index: 4500 !important;
        opacity: 0;
        pointer-events: auto;
        transition: opacity 0.2s ease;
    }
    .mobile-scroll-year-badge.visible { opacity: 1; }

    /* Static vertical timeline entries */
    .mobile-year-overlay-item {
        position: fixed !important;
        right: 28px !important;
        transform: translateY(-50%) !important;
        background: transparent !important;
        color: #1bcd00 !important;
        padding: 2px 8px;
        font-size: 0.9rem !important;
        border: none !important;
        white-space: nowrap;
        pointer-events: none;
        z-index: 3600 !important;
    }

    /* Enable and style scan overlay on mobile with 10px margins and 1% tilt */
   #scan-overlay {
        display: none;
        position: fixed;
        inset: 0;
        width: 100vw;
        height: 100vh;
        z-index: 3500;
        justify-content: center;
        align-items: center;
        background: transparent !important;
        box-sizing: border-box;
        padding: 10px !important;
        pointer-events: none;
    }

    #scan-overlay.is-visible {
        display: flex !important;
        pointer-events: auto !important;
    }

    /* No tilt, reduced size slightly, no shadow */
    #scan-image {
        max-width: calc(100vw - 40px) !important;
        max-height: calc(100vh - 160px) !important;
        width: auto !important;
        height: auto !important;
        object-fit: contain;
        box-shadow: none !important;
        transform: none !important;
        animation: none !important;
        transition: transform 0.2s ease;
    }

    /* Moved buttons up */
    .scan-controls {
        position: fixed !important;
        bottom: 75px !important;
        left: 0 !important;
        right: 0 !important;
        display: flex !important;
        justify-content: center !important;
        gap: 15px !important;
        z-index: 3600 !important;
        pointer-events: auto !important;
    }

.scan-control-btn {
        background-color: #1bcd00 !important;
        color: #ffffff !important;
        border: 1px solid #1bcd00 !important;
        padding: 0 16px !important;
        height: 40px !important;
        min-width: 44px !important;
        font-size: 1.2rem !important;
        animation: none !important;
        transform: none !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        box-sizing: border-box !important;
    }

    .scan-control-btn.arrow-btn {
        font-size: 1.6rem !important;
        padding: 0 18px !important;
    }

    /* Button click-state (color inverse) */
   .scan-control-btn:active {
        background-color: #ffffff !important;
        color: #1bcd00 !important;
        border: 1px solid #1bcd00 !important;
    }

    /* Bespoke mobile rotating text circle (pinned to top-left, smaller, 0.9rem) */
    .rotating-text-wrapper {
        position: fixed !important;
        top: 50% !important;
        left: 50% !important;
        transform: translate(-50%, -50%) !important;
        width: 110px !important;
        height: 110px !important;
        display: flex !important;
        justify-content: flex-start !important;
        align-items: flex-start !important;
        pointer-events: none !important;
        z-index: 100 !important;
    }
    .rotating-text-wrapper svg {
        width: 110px !important;
        height: 110px !important;
    }
    .rotating-text-wrapper text {
        font-size: .96rem !important;
        fill: #1bcd00 !important;
    }

    /* Fullscreen green filter menu container (Mobile Only) */
    .filter-menu.is-visible {
        position: fixed !important;
        inset: 0 !important;
        width: 100vw !important;
        height: 100vh !important;
        background: #1bcd00 !important;
        padding: 40px 20px 90px 20px !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        justify-content: flex-start !important;
        z-index: 4000 !important;
        box-sizing: border-box !important;
    }

    /* Category group container (Mobile Only) */
   .filter-menu.is-visible .filter-group {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: wrap !important;
        justify-content: center !important;
        align-items: center !important;
        width: 100% !important;
        margin-bottom: 0 !important;
        max-height: none !important;
        opacity: 1 !important;
    }

    /* Apply uniform vertical spacing to every category label */
    .filter-menu.is-visible .category-label {
        color: #ffffff !important;
        text-decoration: none !important;
        margin: 16px 0 4px 0 !important;
        display: block !important;
        width: 100% !important;
        text-align: center !important;
        font-weight: bold;
    }

    /* Keep the very first category flush with the top of the menu */
    .filter-menu.is-visible .filter-group:first-of-type .category-label:first-of-type {
        margin-top: 0 !important;
    }

    /* Keep tags sized at 1.2rem with compact inline wrapping (Mobile Only) */
    .filter-menu.is-visible .filter-tag {
        background: transparent !important;
        border: none !important;
        box-shadow: none !important;
        padding: 2px 6px !important;
        margin: 2px 4px !important;
        animation: none !important;
        display: inline-block !important;
        white-space: nowrap !important;
        max-width: none !important;
        opacity: 1 !important;
        color: rgba(255, 255, 255, 0.75) !important;
        font-size: 1.2rem !important;
    }

    .filter-menu.is-visible .filter-tag.active {
        color: #ffffff !important;
        background: transparent !important;
        text-decoration: underline !important;
    }

    .filter-menu.is-visible .filter-tag.is-hidden {
        color: rgba(255, 255, 255, 0.3) !important;
        pointer-events: none !important;
        display: inline-block !important;
    }
    .filter-menu.is-visible .clear-filters-btn,
    .filter-menu.is-visible .entry-counter { display: none !important; }

    .mobile-filter-footer {
        display: flex !important;
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        height: 50px !important;
        background: #1bcd00 !important;
        justify-content: space-between !important;
        align-items: center !important;
        padding: 0 10px !important;
        z-index: 4001 !important;
        border-top: none !important;
        box-sizing: border-box !important;
    }
    .mobile-filter-footer button {
        background: transparent !important;
        border: none !important;
        color: #ffffff !important;
        font-family: inherit;
        cursor: pointer;
        padding: 10px;
        font-size: 0.9rem !important;
    }
    #mobile-filter-close { text-align: left; }
    #mobile-filter-reset { text-align: center; flex: 1; }
    #mobile-filter-apply { text-align: right; }

    /* About page mobile layout adjustments */
    .about-page-container {
        padding-top: 40px !important;
        padding-left: 10px !important;
        padding-right: 10px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    .about-content {
        flex-direction: column !important;
        gap: 30px !important;
        width: 100% !important;
        margin: 0 !important;
    }
    .about-text-column,
    .about-legal-column {
        flex: 0 0 100% !important;
        width: 100% !important;
        padding: 0 !important;
        box-sizing: border-box !important;
    }
    .legal-footer-split {
        flex-direction: row !important;
        gap: 4% !important;
    }
}

/* About Page: Desktop vs Mobile Header Toggle */
.about-page .mobile-back-link {
    display: none;
}

@media (min-width: 601px) {
    .about-page .about-page-container {
        padding-top: 50px;
    }
}

@media (max-width: 600px) {
    .about-page .desktop-title-link,
    .about-page #nav-filter,
    .about-page #nav-search {
        display: none !important;
    }

    .about-page .mobile-back-link {
        display: inline-block !important;
    }

    .about-page .site-header > .header-col:first-child {
        display: flex !important;
        justify-content: flex-start !important;
    }

    .about-page .site-header #nav-about {
        flex: 0 0 auto !important;
        justify-content: flex-end !important;
    }
}

/* 1. Remove underline from active About link on the About page */
.about-page #nav-about a.active,
.about-page #nav-about a.active:hover {
    text-decoration: none !important;
}

/* 2. Enforce exact 10px left/right margins on About page container */
.about-page .about-page-container {
    padding-left: 10px !important;
    padding-right: 10px !important;
    box-sizing: border-box !important;
}

.about-page .about-content {
    margin: 0 !important;
    padding: 0 !important;
    width: 100% !important;
}

/* 3. Align mobile top spacing with index.html so the big mobile title sits identically */
@media (max-width: 600px) {
    .about-page .about-page-container {
        padding-top: 10px !important;
        padding-bottom: 70px !important;
    }
}