/* =========================================================
   zhyllanfyllah — centered old-web layout
   canvas 1500 design px, site 1240 px, 1rem = 16 design px
   whole site scales uniformly with viewport width
   ========================================================= */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    font-size: calc(100vw / 1500 * 16);
    scroll-behavior: smooth;
    overflow-x: hidden;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

html,
body,
body *,
body *::before,
body *::after {
    cursor:
        url("../assets/cursor.png") 0 47,
        auto !important;
}

body {
    margin: 0;
    background: #c7c4be url("../assets/bg.jpg") center center / cover no-repeat fixed;
    /*color: #4a423d; */
    font-family: "Segoe Print", "Segoe UI", "Trebuchet MS", system-ui, sans-serif;
    font-size: 1.0625rem;
    line-height: 1.8;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

img {
    display: block;
    max-width: 100%;
}
a {
    color: inherit;
}
p {
    margin: 0 0 1rem;
}

@font-face {
    font-family: "Old School";
    src: url("../assets/fonts/oldschool-and-classy-normal.woff") format("woff");
    font-weight: 400;
    font-display: swap;
}

@font-face {
    font-family: "Segoe Print";
    src: url("../assets/fonts/segoepr.woff") format("woff");
    font-weight: 400;
    font-display: swap;
}

::selection {
    background: #d2cde6;
    color: #332c2b;
}

/* centered wrapper, grey stays visible on the left and right */

.site {
    width: 70rem; /* 1120px */
    margin: 0rem auto 5.5rem;
}

/* ---------------- header photo + layer 3 strip ---------------- */

.top {
    position: relative;
    z-index: 0;
    height: 36.03125rem; /* 576.5px */
    overflow: hidden;
    background: #d8d2c8;
}

.top picture,
.top__photo {
    width: 100%;
    height: 100%;
}

.top picture {
    display: block;
}
.top__photo {
    object-fit: cover;
    object-position: center;
}

.top__logo {
    position: absolute;
    z-index: 1;
    top: 9.9rem;
    left: 8rem;
    width: 26rem;
    height: auto;
}

.strip {
    position: absolute;
    z-index: 1;
    top: 0;
    left: 0;
    width: 37.65625rem; /* 666.5px */
    height: 4.09355rem; /* 81.5px */
    pointer-events: none;
}

.strip__img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.brand {
    position: absolute;
    z-index: 2;
    top: 0;
    left: 0;
    width: 35.65625rem;
    height: 5.09375rem;
    margin: 0;
    padding: 0 3rem;
    display: flex;
    align-items: center;
    overflow: hidden;
    font-family: "Segoe Print", "Segoe UI", cursive;
    font-size: 1.9rem;
    line-height: 1;
    color: #fffdf8;
    text-shadow: 0 0.0625rem 0.125rem rgba(0, 0, 0, 0.3);
}

.brand a {
    display: flex;
    width: max-content;
    text-decoration: none;
    animation: brand-marquee 16s linear infinite;
}

.brand a span {
    flex: 0 0 auto;
    padding-right: 3rem;
}

@keyframes brand-marquee {
    to {
        transform: translateX(-50%);
    }
}

/* ---------------- columns ---------------- */

.columns {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: stretch;
    margin-top: -4rem;
}

/* ---------------- sidebar (pure CSS) ---------------- */

.sidebar {
    position: relative;
    z-index: 3;
    top: -7rem;
    margin-bottom: -7rem;
    flex: 0 0 25.78125rem; /* 412.5px */
    overflow: hidden;
    color: #fff;
    background: url("../assets/sidebar-left_layer-2.png") center / 100% 100% no-repeat;
}

.sidebar__inner {
    position: relative;
    z-index: 1;
    min-height: 100%;
    display: flex;
    flex-direction: column;
    gap: 1.4rem;
    padding: 4rem 3.5rem 3.5rem;
}

.sidebar {
    font-size: 0.9rem;
    line-height: 1.55;
}

.sidebar__label {
    margin: 0 0 1.1rem;
    font-size: 0.7rem;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: #fff;
}

/* image-only buttons: button.png covers the blue panel, text is white */

.menu {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
}

.menu__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 17.68rem;
    height: 2.8rem;
    margin-block: 0.2rem;
    background: url("../assets/button.png") left center / 100% 100% no-repeat;
    color: #fff; /* white text */
    font-family: "Old School", cursive;
    font-size: 1rem;
    line-height: 1;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    text-decoration: none;
    text-shadow: 0 0.0625rem 0.1875rem rgba(0, 0, 0, 0.28);
    transition: opacity 0.2s ease;
}

.menu__btn span {
    margin: 0.2rem 0;
}

.menu__btn:hover {
    color: #332c2b;
}

.sidebar__note {
    max-width: 17.5rem;
    margin: 3.5rem 0 0;
    font-size: 0.55rem;
    line-height: 1.85;
    color: rgba(255, 255, 255, 0.82);
}

.sidebar__foot {
    position: relative;
    margin-top: 0;
    padding-top: 2rem;
    font-size: 0.7rem;
    line-height: 1.9;
    letter-spacing: 0.07em;
    color: #fff;
}

.sidebar__foot::before {
    content: "";
    position: absolute;
    top: 0;
    left: -3.5rem;
    width: 12.890625rem;
    height: 1px;
    background: rgba(255, 255, 255, 0.58);
}

.sidebar__foot p {
    margin: 0;
}

/* ---------------- white content box (pure CSS) ---------------- */

.paper {
    position: relative;
    z-index: 1;
    flex: 0 0 70rem;
    width: 70rem;
    margin-left: -25.78125rem;
    min-height: 181.71875rem; /* 2907.5px */
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding: 4rem 7.5rem 3rem 30.78125rem;
    border: 0.125rem solid #332c2b;
    border-left: 0; /* the sidebar hugs this side */
    border-radius: 0 4.0625rem 4.0625rem 0;
    background: #fefefe;
    /* depth sits behind the sheet and shows on the photo it overlaps */
    box-shadow:
        0 -0.5rem 2.5rem rgba(51, 44, 43, 0.28),
        0 1.5rem 3rem rgba(51, 44, 43, 0.18);
}

.count-loli {
    display: block;
    width: min(100%, 20rem);
    height: auto;
    margin: auto auto 0;
}

.coming-soon {
    margin: 3rem 0 0;
    color: #938d93;
    font-family: "Old School", "Segoe Print", cursive;
    font-size: 1.6rem;
    text-align: center;
}

.coming-soon h2 {
    margin: 0;
}

.section {
    scroll-margin-top: 2rem;
}

.section__title {
    margin: 0 0 1.4rem;
    line-height: 0;
}

.section__title img {
    position: relative;
    z-index: 3;
    width: 19.4375rem; /* 311px */
    height: auto;
}

.sidebar .section__title {
    width: calc(100% + 1.5rem);
    margin: 0 0 0.8rem -1.5rem;
}

.sidebar .section__title img {
    width: 19.4375rem;
}

.sidebar .section p {
    margin-bottom: 0.65rem;
}

.sidebar .lead {
    font-size: 1rem;
    line-height: 1.55;
    color: #fff;
}

.lead {
    max-width: 40rem;
    font-size: 1.3rem;
    line-height: 1.75;
    color: #332c2b;
}

.section p {
    max-width: 40rem;
}

.sidebar .links li {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.1rem;
    padding: 0.45rem 0;
}

.sidebar .links--grid {
    grid-template-columns: 1fr;
}
.sidebar .links span {
    font-size: 0.62rem;
    color: #fff;
}
.sidebar .links a {
    font-size: 0.82rem;
    color: #fff;
    overflow-wrap: anywhere;
}
.sidebar .links a:hover {
    color: #fff;
    border-color: #fff;
}
.sidebar .links li {
    border-bottom-color: rgba(255, 255, 255, 0.24);
}

/* link lists */

.links {
    list-style: none;
    margin: 0.4rem 0 0;
    padding: 0;
    max-width: 40rem;
}

.links li {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 2rem;
    padding: 0.7rem 0;
    border-bottom: 0.0625rem solid rgba(51, 44, 43, 0.14);
}

.links li:last-child {
    border-bottom: 0;
}

.links span {
    font-size: 0.72rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #938d93;
}

.links a {
    text-decoration: none;
    border-bottom: 0.0625rem solid #d2cde6;
    transition:
        color 0.2s ease,
        border-color 0.2s ease;
}

.links a:hover {
    color: #13537d;
    border-color: #13537d;
}

.links--grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 3.5rem;
    max-width: 42rem;
}

/* webring buttons */

.ring-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
    margin: 1.2rem 0 1.4rem;
}

.sidebar .ring-nav {
    gap: 0.4rem;
    margin: 0.8rem 0;
}

.ring-nav a {
    padding: 0.42rem 1.1rem;
    border: 0.125rem solid #332c2b;
    border-radius: 62.4375rem;
    background: #fefefe;
    font-size: 0.85rem;
    text-decoration: none;
    transition: background 0.2s ease;
}

.sidebar .ring-nav a {
    padding: 0.3rem 0.65rem;
    border-color: rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 0.72rem;
}

.ring-nav a:hover {
    background: #d2cde6;
}
.sidebar .ring-nav a:hover {
    background: rgba(255, 255, 255, 0.22);
}

.webring-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
    gap: 0.6rem;
    margin-top: 0.8rem;
}

.webri-anime {
    width: 100%;
    max-width: 16rem;
    min-width: 0;
    margin: auto auto 0;
    padding: 1.25rem 1.4rem;
    border: 1px dashed rgba(255, 255, 255, 0.78);
    color: #fff;
    font-size: 0.65rem;
    line-height: 1.4;
    text-align: center;
}

.webri-anime__title,
.webri-anime__nav a {
    color: #fff;
    text-decoration: underline;
    text-underline-offset: 0.12em;
}

.webri-anime__title {
    display: block;
    margin-bottom: 0.65rem;
}

.webri-anime .webring-badge {
    display: block;
    width: 88px;
    max-width: 100%;
    margin: 0 auto 0.65rem;
}

.webring-grid > a {
    display: block;
    width: 100%;
    max-width: 12.5rem;
    justify-self: center;
}

.webring-grid > a img {
    width: 100%;
    height: auto;
}

#custom-tooltip {
    position: fixed;
    z-index: 9999;
    max-width: min(17rem, calc(100vw - 1rem));
    padding: 0.35rem 0.65rem;
    border-radius: 8px 0 8px 0;
    background: #332c2b;
    color: #fff;
    font-family: "Segoe Print", "Segoe UI", "Trebuchet MS", system-ui, sans-serif;
    font-size: 0.7rem;
    line-height: 1.4;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(0.2rem);
    transition:
        opacity 0.12s ease,
        transform 0.12s ease,
        visibility 0.12s;
}

#custom-tooltip.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.webri-anime__nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.2rem 0.35rem;
    margin-top: 0.25rem;
    font-size: 0.55rem;
}

/* footer inside the white box */

.footer {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 2rem;
    padding-top: 1.5rem;
    border-top: 0.0625rem solid rgba(51, 44, 43, 0.18);
    font-size: 0.75rem;
    letter-spacing: 0.04em;
    color: #938d93;
}

.footer p {
    margin: 0;
}
.footer a {
    text-decoration: none;
    border-bottom: 0.0625rem solid #d2cde6;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    .menu__btn,
    .links a,
    .ring-nav a {
        transition: none;
    }
    .brand a {
        animation: none;
    }
    .brand a span + span {
        display: none;
    }
}
