/* Extra phone layout. Page CSS already restyles <=1100px; this stops the
   full-page poster from sitting under the copy, which Safari scales differently. */

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

/* Phone-only crop of the home poster. Hidden on desktop, where the full poster stays on .site-main. */
.home-hero-art {
    display: none;
}

@media (max-width: 1100px) {
    html,
    body {
        overflow-x: hidden;
        max-width: 100%;
    }

    .site-header {
        padding-top: env(safe-area-inset-top);
    }

    .site-main {
        height: auto !important;
        min-height: 0 !important;
        margin-top: 0 !important;
        background-image: none !important;
        background-color: #1a0c2e;
        overflow: visible;
    }

    .home-hero {
        height: auto !important;
        padding: 0 0 18px !important;
        background-color: #2a1248;
    }

    .home-hero::before,
    .about-intro::before,
    .policy-overview::before,
    .terms-overview::before {
        content: "";
        display: block;
        width: 100%;
        max-height: 420px;
        flex: none;
        pointer-events: none;
    }

    .home-hero::before {
        content: none;
        display: none;
    }

    .home-hero .home-hero-art {
        display: block;
        width: 100%;
        line-height: 0;
    }

    .home-hero .home-hero-art img {
        width: 100%;
        height: auto;
        display: block;
    }

    .about-intro::before,
    .policy-overview::before,
    .terms-overview::before {
        aspect-ratio: 1920 / 900;
        background: url("../img/gw13.png") no-repeat top center;
        background-size: 100% auto;
    }

    .home-hero-button-wrap {
        padding: 12px 16px 0;
    }

    .home-hero-button {
        width: min(280px, 86vw);
        max-width: 100%;
        height: 72px;
    }

    .home-hero-button-text {
        font-size: 20px;
    }

    .home-hero-title {
        font-size: 16px;
        line-height: 1.35;
        text-align: center;
        padding: 8px 16px 0;
    }

    .about-intro,
    .policy-overview,
    .terms-overview {
        height: auto !important;
        padding-top: 0 !important;
        padding-bottom: 16px;
    }

    .about-intro-inner,
    .policy-overview-inner,
    .terms-overview-inner,
    .header-inner,
    .footer-inner {
        width: 100% !important;
        max-width: 100%;
        padding-left: 14px;
        padding-right: 14px;
        box-sizing: border-box;
    }

    .about-intro-content {
        font-size: 15px;
        line-height: 1.65;
        text-indent: 0;
        padding: 8px 4px 12px;
    }

    .about-intro-content p {
        margin: 0 0 14px;
    }

    .join-image-wrap img,
    .img-gw14,
    .img666 {
        max-width: 100%;
        height: auto;
    }

    .carousel {
        width: 100%;
        max-width: 520px;
        margin: 0 auto;
    }

    .policy-card,
    .terms-card {
        border-radius: 12px;
        overflow: hidden;
    }

    .policy-body,
    .terms-body,
    .policy-content,
    .terms-content,
    .policy-content-panel,
    .terms-content-panel {
        min-width: 0;
        max-width: 100%;
        height: auto;
    }

    .policy-body iframe,
    .terms-body iframe,
    .policy-content iframe,
    .terms-content iframe {
        display: block;
        width: 1px;
        min-width: 100%;
        max-width: 100%;
        height: 420px !important;
        border: 0;
    }

    .site-footer {
        padding-bottom: calc(20px + env(safe-area-inset-bottom));
    }

    .footer-contact-text,
    .footer-age-text,
    .footer-link {
        overflow-wrap: anywhere;
    }

    .footer-link {
        text-decoration: none;
    }
}

@media (max-width: 480px) {
    .policy-body iframe,
    .terms-body iframe,
    .policy-content iframe,
    .terms-content iframe {
        height: 360px !important;
    }

    .home-hero-button-text {
        font-size: 18px;
    }
}
