@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-8px);
    }
}

html {
    height: 100%;
    -webkit-overflow-scrolling: touch;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

html:has(.login-bg) {
    overflow: hidden;
    position: fixed;
    width: 100%;
}

body {
    font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background-color: #f5f5f5;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

body:has(.login-bg) {
    position: fixed;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

body:has(.login-bg) {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-height: -webkit-fill-available;
    background:
        radial-gradient(680px 380px at 18% 35%, rgba(178, 194, 255, 0.55), transparent 70%),
        radial-gradient(520px 300px at 75% 65%, rgba(224, 194, 255, 0.5), transparent 72%),
        linear-gradient(145deg, #b8d4eb 0%, #bfd9ef 36%, #c4caec 100%);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: none;
    touch-action: none;
}

body:has(.login-bg) .login-bg {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    overflow: hidden;
}

body:has(.login-bg) .page-footer {
    flex-shrink: 0;
    background: transparent;
}

.login-container, .purchase-container {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    width: 300px;
    text-align: center;
}

h1 {
    margin-bottom: 20px;
}

.login-tabs {
    display: flex;
    margin-bottom: 20px;
}

.tab {
    flex: 1;
    padding: 10px;
    border: none;
    background: #eee;
    cursor: pointer;
}

.tab.active {
    background: #7b00ff;
    color: white;
}

input {
    width: 100%;
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.code-input {
    display: flex;
}

.code-input input {
    flex: 1;
    margin-right: 10px;
}

.login-btn, .purchase-btn {
    width: 100%;
    padding: 10px;
    background: #7b00ff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.login-btn:hover, .purchase-btn:hover {
    background: #7316ff;
}

.footer {
    margin-top: 20px;
    font-size: 12px;
}

.footer img {
    margin-top: 10px;
    width: 100px;
}

.login-bg {
    min-height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: transparent;
    box-sizing: border-box;
}

.login-panel {
    width: min(100%, 460px);
    max-height: calc(100vh - 32px);
    max-height: calc(-webkit-fill-available - 32px);
    border-radius: 34px;
    padding: 28px 22px 20px;
    background:
        radial-gradient(460px 300px at 0% 62%, rgba(150, 163, 245, 0.46), transparent 74%),
        radial-gradient(440px 260px at 100% 80%, rgba(231, 192, 255, 0.38), transparent 72%),
        linear-gradient(155deg, rgba(193, 222, 243, 0.92), rgba(208, 218, 241, 0.95));
    box-shadow: 0 18px 46px rgba(81, 91, 138, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.4);
    box-sizing: border-box;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    position: relative;
    transform: translateZ(0);
    will-change: transform;
}

.login-panel::-webkit-scrollbar {
    width: 4px;
}

.login-panel::-webkit-scrollbar-track {
    background: transparent;
}

.login-panel::-webkit-scrollbar-thumb {
    background: rgba(113, 92, 255, 0.3);
    border-radius: 2px;
}

.login-panel::-webkit-scrollbar-thumb:hover {
    background: rgba(113, 92, 255, 0.5);
}

.hero-icon {
    display: flex;
    justify-content: center;
}

.hero-icon img {
    width: 90px;
    height: 90px;
    border-radius: 20px;
    object-fit: contain;
    animation: float 3s ease-in-out infinite;
}

.hero-title {
    margin: 12px 0 0;
    text-align: center;
    line-height: 1.2;
    font-size: clamp(32px, 6vw, 56px);
    letter-spacing: 0.01em;
    color: #2a2f3f;
}

.hero-title span {
    color: #715cff;
}

.hero-subtitle {
    margin: 12px 0 24px;
    text-align: center;
    color: #505868;
    font-size: clamp(15px, 3vw, 22px);
}

.field {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    height: 56px;
    border-radius: 999px;
    background: #f2f3f5;
    margin-bottom: 14px;
    padding: 0 18px;
    box-sizing: border-box;
}

.field-icon {
    width: 30px;
    height: 30px;
    text-align: center;
    opacity: 0.64;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.field-icon img {
    width: 22px;
    height: 22px;
    object-fit: contain;
}

.field input {
    flex: 1;
    border: 0;
    outline: none;
    background: transparent;
    font-size: 16px;
    font-size: clamp(16px, 2.8vw, 22px);
    color: #41485a;
    margin: 0;
    padding: 0;
    -webkit-appearance: none;
    appearance: none;
    border-radius: 0;
}

.field input::placeholder {
    color: #9aa0ad;
}

.field input:focus {
    outline: none;
}

.field-code {
    gap: 8px;
}

.ghost-btn {
    border: 0;
    background: transparent;
    color: #7563ff;
    font-size: clamp(13px, 2.6vw, 18px);
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    padding: 4px 8px;
}

.ghost-btn:disabled {
    color: #a9aec2;
    cursor: not-allowed;
}

.login-main-btn {
    margin-top: 16px;
    height: 56px;
    border-radius: 999px;
    background: linear-gradient(90deg, #7d5cff, #6a5ff3);
    font-size: clamp(18px, 4vw, 24px);
    font-weight: 800;
    letter-spacing: 0.02em;
}

.footer-login {
    margin-top: clamp(40px, 8vh, 80px);
    text-align: center;
}

.footer-login p {
    margin-top: 12px;
    font-size: 13px;
    color: #5c6477;
    margin-bottom: 16px;
}

.footer-login .footer-logo {
    max-width: 90px;
    height: auto;
    opacity: 0.75;
    transition: opacity 0.3s ease;
    margin-top: 8px;
}

.footer-login .footer-logo:hover {
    opacity: 1;
}
/* Purchase Page */
body.purchase-page {
    min-height: 100vh;
    margin: 0;
    display: block;
    font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    background: #9263ff;
    color: #202536;
    position: relative;
    overflow-x: hidden;
}

body.purchase-page::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    background-image: url('../../img/bg-2-1.png');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    z-index: -1;
    pointer-events: none;
    opacity: 1;
}

.sub-shell {
    margin: 0 auto;
    padding: 24px 16px 50px;
}

.sub-hero {
    position: relative;
    border-radius: 28px;
    padding: 26px 24px 32px;
    background: transparent;
    overflow: hidden;
}

.sub-hero::before {
    content: none;
}

.sub-topbar {
    display: flex;
    align-items: center;
    gap: 14px;
    position: relative;
    z-index: 2;
}

.logo-link {
    display: inline-block;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.logo-link:hover {
    transform: scale(1.05);
}

.top-logo {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    object-fit: contain;
    flex: 0 0 56px;
}

.sub-topbar h1 {
    margin: 0;
    font-size: clamp(28px, 3vw, 44px);
    font-weight: 800;
    letter-spacing: 0.02em;
    color: #fff;
}

.sub-headline {
    position: relative;
    z-index: 2;
    margin-top: 56px;
}

.sub-headline h2 {
    margin: 0;
    font-size: clamp(40px, 5vw, 64px);
    line-height: 1.08;
    letter-spacing: 0.01em;
    color: #ffffff;
}

.sub-headline p {
    margin: 18px 0 0;
    max-width: 74%;
    font-size: clamp(14px, 1.9vw, 24px);
    line-height: 1.4;
    color: #ffffff;
}

.sub-list {
    margin-top: 20px;
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    position: relative;
}

.sub-list.is-loading {
    min-height: 260px;
}

.package-hint {
    margin: 0;
    padding: 10px 14px;
    border-radius: 12px;
    background: #e3e8f3;
    color: #404a63;
    font-size: 14px;
    line-height: 1.5;
}

.course-card {
    position: relative;
    border-radius: 40px;
    background: rgba(163, 145, 255, 0.85);
    aspect-ratio: 1 / 1;
    overflow: hidden;
    box-shadow: 0 0.0625rem 0.125rem rgba(44, 47, 51, 0.04);
}

.course-card .cover {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}

.course-card .overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(163, 145, 255, 0) 0%, rgba(163, 145, 255, 0.9) 100%);
    pointer-events: none;
}

.card-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
}

.course-card:hover .card-video {
    opacity: 1;
}

.course-card:hover .cover {
    opacity: 0;
}

.course-card.is-unlocked .overlay {
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0.8) 100%);
}

.course-card.is-locked .overlay {
    background: linear-gradient(180deg, rgba(163, 145, 255, 0) 0%, rgba(163, 145, 255, 0.9) 100%);
}

.card-content {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 20px 20px 20px;
    gap: 18px;
    height: 100%;
    box-sizing: border-box;
}

.card-head {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 0;
    padding-right: 0;
}

.product-thumb {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: rgba(245, 242, 255, 0.26);
    backdrop-filter: blur(2px);
    z-index: 10;
    padding: 15px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-thumb-icon {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 4px 10px rgba(30, 30, 60, 0.25));
    animation: float 3s ease-in-out infinite;
}

.card-head h3 {
    margin: 0;
    line-height: 1.1;
    color: #ffffff;
    text-align: left;
    font-size: clamp(30px, 2.4vw, 36px);
}

.card-head p {
    margin: 0;
    color: rgba(255, 255, 255, 0.92);
    font-size: clamp(12px, 1.1vw, 14px);
    text-align: left;
}

.card-info {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 20px;
    padding: 16px 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    width: 100%;
    box-sizing: border-box;
}

.meta-line {
    margin-top: 0;
}

.lesson-count {
    color: #d4fb79;
    font-weight: 700;
}

.tag {
    margin-top: 4px;
    padding: 8px 22px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    color: #5d49c7;
    font-size: clamp(14px, 1.15vw, 18px);
    font-weight: 800;
    white-space: nowrap;
}

.card-tag-fixed {
    position: absolute;
    top: 18px;
    right: 18px;
    z-index: 3;
}

.price-tag {
    position: absolute;
    top: -5px;
    right: 12px;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0;
    padding: 8px 4px;
}

.price-icon {
    width: 56px;
    height: 56px;
    object-fit: contain;
    margin-top: -20px;
}

.price-text {
    color: #ffa200;
    font-weight: 800;
    font-size: clamp(18px, 1.5vw, 22px);
}

.tag.subscribed {
    background: #d4fb79;
    color: #1f7a54;
}

.tag.unsubscribed {
    color: #5d49c7;
}

.card-note {
    width: fit-content;
    min-height: 28px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px 12px;
    color: #ffffff;
    font-size: clamp(11px, 1vw, 14px);
    box-sizing: border-box;
    border: 1px solid rgba(255, 255, 255, 0.2);
    margin: 0;
}

.note-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid #5e45d5;
    color: #5e45d5;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-style: normal;
}

.card-actions {
    position: absolute;
    left: 30px;
    right: 30px;
    bottom: 22px;
    display: flex;
    justify-content: flex-end;
    z-index: 5;
}

.sale {
    padding: 8px 16px;
    border-radius: 999px;
    background: rgba(196, 250, 114, 0.95);
    color: #2b6f3f;
    font-weight: 800;
    font-size: clamp(13px, 1.1vw, 16px);
}

.buy-btn {
    border: 0;
    border-radius: 999px;
    padding: 3px 16px;
    background: linear-gradient(90deg, #7e5cff, #7700ed);
    color: #ffffff;
    font-weight: 700;
    font-size: clamp(12px, 1vw, 14px);
    cursor: pointer;
    width: 100%;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 8px;
    min-height: 28px;
}

.btn-icon-img {
    width: 36px;
    height: 36px;
    object-fit: contain;
    flex-shrink: 0;
}

.buy-btn.unsubscribed {
    background: linear-gradient(90deg, #ff9a3c, #ff6b45);
}

@media (max-width: 992px) {
    .sub-list {
        grid-template-columns: 1fr;
    }

    .sub-headline p {
        max-width: 92%;
    }
}

@media (max-width: 768px) {
    .login-bg {
        padding: 12px;
        align-items: center;
        min-height: 100%;
        height: 100%;
    }

    .login-panel {
        min-height: auto;
        max-height: calc(100vh - 24px);
        max-height: calc(-webkit-fill-available - 24px);
        border-radius: 24px;
        width: 100%;
        padding: 22px 16px 18px;
        box-shadow: none;
        position: relative;
    }
    
    .login-panel:focus-within {
        transform: translateY(0);
    }

    .hero-icon img {
        width: 80px;
        height: 80px;
        border-radius: 18px;
    }

    .hero-title {
        margin: 10px 0 0;
        font-size: clamp(28px, 5.5vw, 48px);
    }

    .hero-subtitle {
        margin: 10px 0 20px;
        font-size: clamp(14px, 2.8vw, 20px);
    }

    .field {
        height: 52px;
        padding: 0 16px;
        margin-bottom: 12px;
    }

    .field input {
        font-size: 16px;
    }

    .login-main-btn {
        height: 52px;
        font-size: clamp(16px, 3.8vw, 22px);
    }

    .footer-login {
        margin-top: clamp(30px, 6vh, 60px);
    }

    .footer-login p {
        font-size: 12px;
        margin-bottom: 12px;
    }

    .footer-login .footer-logo {
        max-width: 80px;
        opacity: 0.85;
    }

    .page-footer {
        padding: 18px;
    }

    .footer-logo {
        max-width: 80px;
        opacity: 0.9;
    }

    .sub-shell {
        padding: 20px 20px 30px;
    }

    .sub-hero {
        border-radius: 0;
        padding: 16px 14px 24px;
    }

    .top-logo {
        width: 48px;
        height: 48px;
        flex-basis: 48px;
    }

    .sub-headline {
        margin-top: 44px;
    }

    .sub-headline p {
        max-width: 95%;
    }

    .course-card {
        border-radius: 40px;
    }

    .card-content {
        padding: 16px 18px 18px;
        gap: 14px;
    }

    .product-thumb {
        width: 70px;
        height: 70px;
        border-radius: 50%;
        top: 15px;
        left: 15px;
        padding: 15px;
    }

    .card-head h3 {
        font-size: clamp(18px, 8vw, 24px);
    }

    .card-head p {
        font-size: clamp(14px, 5vw, 16px);
    }

    .tag {
        font-size: clamp(14px, 4vw, 18px);
    }

    .card-tag-fixed {
        top: 12px;
        right: 12px;
    }

    .price-tag {
        top: 0;
        right: 0px;
        padding: 0px 10px;
        gap: 0px;
    }

    .price-icon {
        width: 44px;
        height: 44px;
        margin-top: -14px;
    }

    .price-text {
        font-size: clamp(14px, 5vw, 18px);
    }

    .sale {
        font-size: clamp(13px, 3.5vw, 16px);
    }

    .card-note {
        min-height: 24px;
        border-radius: 14px;
        font-size: clamp(10px, 3vw, 12px);
        padding: 3px 10px;
        width: fit-content;
        margin: 0;
    }

    .card-info {
        padding: 12px 16px;
        gap: 6px;
    }

    .buy-btn {
        margin-top: 6px;
    }

    .btn-icon-img {
        width: 36px;
        height: 36px;
    }
}

@media (min-width: 769px) {
    .sub-shell {
        max-width: 768px;
    }
}

@media (min-width: 1024px) {
    .login-bg {
        padding: 52px 28px;
    }

    .login-panel {
        width: min(920px, 92vw);
        min-height: auto;
        border-radius: 28px;
        padding: 40px 44px 28px;
        display: grid;
        grid-template-columns: 1.05fr 1fr;
        column-gap: 34px;
        align-items: center;
    }

    .hero-icon,
    .hero-title,
    .hero-subtitle {
        grid-column: 1;
        text-align: left;
    }

    .hero-icon {
        justify-content: flex-start;
    }

    .hero-icon img {
        width: 86px;
        height: 86px;
        border-radius: 20px;
    }

    .hero-title {
        margin-top: 8px;
        font-size: 44px;
        line-height: 1.16;
    }

    .hero-subtitle {
        margin-top: 14px;
        margin-bottom: 0;
        font-size: 18px;
    }

    .field,
    .login-main-btn {
        grid-column: 2;
        width: 100%;
    }

    .field {
        height: 64px;
        padding: 0 18px;
    }

    .login-main-btn {
        margin-top: 8px;
        height: 64px;
        font-size: 22px;
    }

    .footer-login {
        grid-column: 1 / -1;
        margin-top: 24px;
        text-align: left;
    }

    .sub-hero {
        padding: 28px 28px 34px;
    }
}

@media (max-width: 420px) {
    .login-bg {
        padding: 20px;
    }

    .login-panel {
        max-height: calc(100vh - 20px);
        max-height: calc(-webkit-fill-available - 20px);
        padding: 20px 14px 16px;
        border-radius: 20px;
    }

    .hero-title {
        font-size: clamp(26px, 5vw, 44px);
    }

    .hero-subtitle {
        font-size: clamp(13px, 2.6vw, 18px);
    }

    .footer-login {
        margin-top: clamp(24px, 5vh, 50px);
    }

    .footer-login p {
        margin-bottom: 10px;
    }

    .footer-login .footer-logo {
        max-width: 70px;
        opacity: 0.9;
    }

    .field {
        height: 48px;
    }

    .login-main-btn {
        height: 48px;
    }

    .sub-topbar h1 {
        font-size: 34px;
    }

    .sub-headline h2 {
        font-size: 28px;
    }
}
    .card-actions {
        left: 18px;
        right: 18px;
        bottom: 14px;
    }

.pay-modal-mask {
    position: fixed;
    inset: 0;
    background: rgba(11, 16, 35, 0.52);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.pay-modal {
    width: min(92vw, 360px);
    background: #ffffff;
    border-radius: 16px;
    padding: 18px 16px 16px;
    box-shadow: 0 10px 30px rgba(20, 28, 62, 0.24);
    position: relative;
    text-align: center;
}

.pay-close {
    position: absolute;
    top: 8px;
    right: 10px;
    border: 0;
    background: transparent;
    font-size: 24px;
    color: #697089;
    cursor: pointer;
}

.pay-modal h3 {
    margin: 6px 0 12px;
    color: #1f2536;
    font-size: 20px;
}

.pay-qr {
    width: min(74vw, 260px);
    height: min(74vw, 260px);
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid #ebedf3;
}

.pay-modal p {
    margin: 12px 0 0;
    color: #616a83;
    font-size: 14px;
}

.runs-api-loading-mask {
    display: flex;
    align-items: center;
    justify-content: center;
}

.runs-api-loading-mask.is-hidden {
    display: none;
}

.runs-api-loading-mask--fullscreen {
    position: fixed;
    inset: 0;
    background: rgba(13, 20, 45, 0.38);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    z-index: 100000;
}

.runs-api-loading-mask--inline {
    position: absolute;
    inset: 0;
    border-radius: 24px;
    background: rgba(245, 246, 252, 0.72);
    backdrop-filter: blur(1.5px);
    -webkit-backdrop-filter: blur(1.5px);
    z-index: 30;
}

.runs-api-loading-box {
    width: 120px;
    height: 120px;
    border-radius: 20px;
    background: rgba(20, 24, 40, 0.86);
    color: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 12px 34px rgba(18, 26, 52, 0.34);
}

.runs-api-loading-spinner {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 3px solid rgba(255, 255, 255, 0.28);
    border-top-color: #ffffff;
    animation: runs-api-spin 0.8s linear infinite;
}

.runs-api-loading-box p {
    margin: 0;
    font-size: 13px;
    line-height: 1;
}

@keyframes runs-api-spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.runs-toast-container {
    position: fixed;
    top: max(14px, env(safe-area-inset-top));
    left: 50%;
    transform: translateX(-50%);
    width: min(92vw, 520px);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    z-index: 120000;
    pointer-events: none;
}

.runs-toast {
    max-width: 100%;
    padding: 12px 16px;
    border-radius: 12px;
    color: #ffffff;
    font-size: 14px;
    line-height: 1.4;
    box-shadow: 0 10px 26px rgba(15, 20, 42, 0.28);
    transform: translateY(-8px);
    opacity: 0;
    transition: transform 0.2s ease, opacity 0.2s ease;
    pointer-events: auto;
    cursor: pointer;
    word-break: break-word;
    background: rgba(33, 38, 57, 0.96);
}

.runs-toast.is-show {
    transform: translateY(0);
    opacity: 1;
}

.runs-toast--success {
    background: rgba(34, 132, 94, 0.96);
}

.runs-toast--error {
    background: rgba(255, 166, 0, 0.96);
}

.runs-toast--info {
    background: rgba(33, 38, 57, 0.96);
}

.page-footer {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    background: transparent;
    flex-shrink: 0;
    margin-top: auto;
}

body.purchase-page .page-footer {
    position: relative;
    z-index: 1;
}

.footer-logo {
    max-width: 100px;
    height: auto;
    opacity: 0.85;
    transition: opacity 0.3s ease;
}

.footer-logo:hover {
    opacity: 1;
}

@supports (-webkit-touch-callout: none) {
    body:has(.login-bg) {
        min-height: -webkit-fill-available;
    }
    
    .login-panel {
        max-height: calc(-webkit-fill-available - 32px);
    }
    
    @media (max-width: 768px) {
        .login-panel {
            max-height: calc(-webkit-fill-available - 24px);
        }
    }
    
    @media (max-width: 420px) {
        .login-panel {
            max-height: calc(-webkit-fill-available - 20px);
        }
    }
}

@media screen and (max-width: 768px) {
    .field input {
        font-size: 16px;
    }
    
    .ghost-btn {
        font-size: 14px;
    }
    
    body:has(.login-bg) {
        touch-action: pan-y;
    }
    
    .login-panel {
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
    }
    
    body.purchase-page {
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .sub-shell {
        padding-bottom: 80px;
    }
}

@supports (-webkit-touch-callout: none) {
    @media screen and (max-width: 768px) {
        .login-bg {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
        }
        
        .login-panel {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            max-height: calc(100% - 24px);
        }
    }
}
