body.home-page {
    font-family: 'Sora', 'Segoe UI', sans-serif;
    background: linear-gradient(135deg, #051937 0%, #0e3a5f 38%, #1a6f8c 67%, #f97316 130%);
    color: #ecfeff;
}

body.home-page::before {
    display: none;
}

.home-page .container.ff-home-container {
    max-width: 1320px;
    padding-top: 1.25rem;
}

.ff-bg {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: -1;
    overflow: hidden;
}

.ff-grid-overlay {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
    background-size: 48px 48px;
    opacity: 0.15;
}

.ff-orb {
    position: absolute;
    border-radius: 999px;
    filter: blur(18px);
    opacity: 0.55;
}

.ff-orb-a {
    width: 360px;
    height: 360px;
    top: -80px;
    left: -80px;
    background: radial-gradient(circle, #22d3ee 0%, transparent 72%);
    animation: ffDriftA 11s ease-in-out infinite alternate;
}

.ff-orb-b {
    width: 400px;
    height: 400px;
    right: -90px;
    bottom: -90px;
    background: radial-gradient(circle, #fb923c 0%, transparent 72%);
    animation: ffDriftB 13s ease-in-out infinite alternate;
}

@keyframes ffDriftA {
    from {
        transform: translate(-12px, -4px);
    }

    to {
        transform: translate(28px, 24px);
    }
}

@keyframes ffDriftB {
    from {
        transform: translate(-24px, 12px);
    }

    to {
        transform: translate(18px, -18px);
    }
}

.ff-profile-bar {
    border: 1px solid rgba(236, 253, 245, 0.25);
    background: linear-gradient(120deg, rgba(15, 34, 55, 0.74), rgba(4, 21, 37, 0.68));
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
}

.ff-top-actions {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}

.profile-title-pill {
    display: inline-block;
    margin-left: 0.6rem;
    padding: 0.16rem 0.52rem;
    border-radius: 999px;
    border: 1px solid rgba(34, 211, 238, 0.6);
    background: rgba(34, 211, 238, 0.18);
    color: #cffafe;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.ff-profile-bar .username {
    display: block;
}

.ff-profile-bar .stats-badge {
    margin-top: 0.35rem;
}

.ff-top-btn {
    border: 0;
    border-radius: 999px;
    padding: 0.62rem 1.1rem;
    font-family: 'Rajdhani', 'Sora', sans-serif;
    font-size: 1rem;
    letter-spacing: 0.02em;
    color: #f8fafc;
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.ff-top-btn-friends {
    background: linear-gradient(120deg, #0ea5e9, #0f766e);
    box-shadow: 0 10px 25px rgba(6, 182, 212, 0.35);
}

.ff-top-btn-shop {
    background: linear-gradient(120deg, #fb923c, #ea580c);
    box-shadow: 0 10px 25px rgba(251, 146, 60, 0.38);
}

.ff-top-btn:hover {
    transform: translateY(-2px);
}

.avatar.frame-neon-hex {
    box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.6), 0 0 18px rgba(34, 211, 238, 0.45);
}

.avatar.frame-royal-gold {
    box-shadow: 0 0 0 3px rgba(251, 191, 36, 0.72), 0 0 18px rgba(251, 191, 36, 0.45);
}

.avatar.frame-frost {
    box-shadow: 0 0 0 3px rgba(186, 230, 253, 0.7), 0 0 18px rgba(191, 219, 254, 0.5);
}

.avatar.frame-lava {
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.75), 0 0 18px rgba(249, 115, 22, 0.48);
}

.avatar.frame-galaxy {
    box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.7), 0 0 18px rgba(167, 139, 250, 0.5);
}

.ff-hero {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 1.4rem;
    align-items: stretch;
    margin-bottom: 1.8rem;
}

.ff-hero-copy,
.ff-hero-metrics {
    border-radius: 22px;
    border: 1px solid rgba(186, 230, 253, 0.28);
    background: linear-gradient(120deg, rgba(6, 23, 39, 0.78), rgba(17, 37, 58, 0.72));
    box-shadow: 0 22px 55px rgba(3, 7, 18, 0.32);
}

.ff-hero-copy {
    padding: 2rem;
}

.ff-logo {
    width: min(280px, 80%);
    margin-bottom: 0.65rem;
}

.ff-kicker {
    display: inline-block;
    font-family: 'Rajdhani', 'Sora', sans-serif;
    color: #67e8f9;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 0.9rem;
    margin-bottom: 0.8rem;
}

.ff-hero-copy h1 {
    font-size: clamp(1.8rem, 3vw, 3rem);
    line-height: 1.1;
    margin-bottom: 0.8rem;
    color: #f8fafc;
}

.ff-hero-copy .tagline {
    color: #d1fae5;
    max-width: 52ch;
    margin-bottom: 1.4rem;
    font-size: 1.05rem;
}

.ff-hero-cta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.ff-cta-main {
    background: linear-gradient(120deg, #06b6d4, #2563eb);
    box-shadow: 0 12px 28px rgba(14, 116, 144, 0.4);
}

.ff-cta-alt {
    border-radius: 999px;
    border: 1px solid rgba(167, 243, 208, 0.45);
    padding: 0.9rem 1.3rem;
    background: rgba(255, 255, 255, 0.07);
    color: #ecfeff;
    font-family: 'Rajdhani', 'Sora', sans-serif;
    font-weight: 700;
    cursor: pointer;
}

.ff-hero-metrics {
    padding: 1.4rem;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    justify-content: center;
}

.ff-metric {
    border-radius: 16px;
    padding: 1rem 1.1rem;
    border: 1px solid rgba(165, 243, 252, 0.3);
    background: rgba(12, 28, 43, 0.72);
}

.ff-metric-label {
    display: block;
    font-size: 0.82rem;
    color: #67e8f9;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.35rem;
}

.ff-metric-value {
    font-size: 2rem;
    font-weight: 800;
    line-height: 1;
    color: #f8fafc;
}

.ff-lobby {
    border: 1px solid rgba(167, 243, 208, 0.28);
    background: linear-gradient(135deg, rgba(14, 36, 57, 0.82), rgba(8, 26, 45, 0.73));
}

.home-page .lobby-header h2 {
    font-family: 'Rajdhani', 'Sora', sans-serif;
    letter-spacing: 0.04em;
}

.home-page .online-user {
    background: rgba(15, 34, 54, 0.86);
    border: 1px solid rgba(125, 211, 252, 0.28);
}

.home-page .online-user:hover {
    background: rgba(20, 48, 72, 0.92);
}

.home-page .user-name {
    color: #f0fdfa;
}

.home-page .invite-btn {
    background: linear-gradient(120deg, #0891b2, #2563eb);
    border-radius: 999px;
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.32);
}

.ff-lobby-donate {
    margin-top: 0.75rem;
    border-top: 1px solid rgba(125, 211, 252, 0.24);
    padding-top: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.85rem;
}

.ff-lobby-donate p {
    margin: 0;
    color: #bfdbfe;
    font-size: 0.88rem;
}

.home-page .ff-lobby-donate .ff-donate-btn {
    appearance: none;
    -webkit-appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    text-decoration: none;
    white-space: nowrap;
    line-height: 1.1;
    min-height: 44px;
    min-width: 118px;
    border: 0;
    border-radius: 999px;
    padding: 0.58rem 1rem;
    background: linear-gradient(120deg, #ec4899, #f97316);
    color: white;
    font-family: 'Rajdhani', 'Sora', sans-serif;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    text-transform: none;
    cursor: pointer;
    box-shadow: 0 8px 22px rgba(236, 72, 153, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.home-page .ff-lobby-donate .ff-donate-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(236, 72, 153, 0.42);
}

.ff-controls {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 0.8rem;
    margin-bottom: 1.35rem;
    padding: 1rem;
    border-radius: 18px;
    border: 1px solid rgba(125, 211, 252, 0.3);
    background: linear-gradient(145deg, rgba(5, 22, 38, 0.8), rgba(9, 30, 47, 0.72));
}

.ff-controls label {
    display: block;
    margin-bottom: 0.3rem;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #a5f3fc;
    font-weight: 700;
}

.ff-controls input,
.ff-controls select {
    width: 100%;
    border-radius: 12px;
    border: 1px solid rgba(148, 220, 253, 0.4);
    background: rgba(12, 28, 44, 0.9);
    color: #ecfeff;
    padding: 0.7rem 0.78rem;
    font-family: 'Sora', sans-serif;
}

.ff-controls input::placeholder {
    color: rgba(207, 250, 254, 0.65);
}

.ff-controls input:focus,
.ff-controls select:focus {
    outline: none;
    border-color: #22d3ee;
    box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.2);
}

.ff-room-launcher {
    margin-bottom: 1.35rem;
    padding: 1rem;
    border-radius: 18px;
    border: 1px solid rgba(94, 234, 212, 0.35);
    background: linear-gradient(145deg, rgba(7, 32, 40, 0.84), rgba(9, 38, 54, 0.74));
}

.ff-room-launcher h2 {
    margin: 0 0 0.25rem;
    font-family: 'Rajdhani', 'Sora', sans-serif;
    letter-spacing: 0.03em;
    color: #99f6e4;
}

.ff-room-launcher p {
    margin: 0 0 0.9rem;
    color: #ccfbf1;
    font-size: 0.92rem;
}

.ff-room-launcher-controls {
    display: grid;
    grid-template-columns: 1.2fr 1.8fr auto;
    gap: 0.8rem;
    align-items: end;
}

.ff-room-launcher-controls label {
    display: block;
    margin-bottom: 0.3rem;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #a7f3d0;
    font-weight: 700;
}

.ff-room-launcher-controls input,
.ff-room-launcher-controls select {
    width: 100%;
    border-radius: 12px;
    border: 1px solid rgba(110, 231, 183, 0.45);
    background: rgba(9, 30, 37, 0.88);
    color: #ecfeff;
    padding: 0.7rem 0.78rem;
    font-family: 'Sora', sans-serif;
}

.ff-room-launcher-controls input:focus,
.ff-room-launcher-controls select:focus {
    outline: none;
    border-color: #2dd4bf;
    box-shadow: 0 0 0 3px rgba(45, 212, 191, 0.2);
}

.ff-room-join-btn {
    min-width: 138px;
    height: 44px;
    border-radius: 12px;
    margin: 0;
    background: linear-gradient(120deg, #14b8a6, #0ea5e9);
}

.ff-room-status {
    min-height: 1.2rem;
    margin-top: 0.6rem;
    color: #a7f3d0;
    font-size: 0.86rem;
}

.ff-game-grid {
    gap: 1rem;
    grid-template-columns: repeat(auto-fit, minmax(265px, 1fr));
}

.ff-game-card {
    border-radius: 20px;
    padding: 1.4rem;
    text-align: left;
    border: 1px solid rgba(165, 243, 252, 0.24);
    background: linear-gradient(150deg, rgba(7, 26, 42, 0.8), rgba(13, 43, 64, 0.72));
    position: relative;
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.ff-game-card:nth-child(odd) {
    background: linear-gradient(150deg, rgba(8, 25, 41, 0.84), rgba(46, 68, 91, 0.66));
}

.ff-game-card:hover {
    transform: translateY(-8px);
    border-color: rgba(103, 232, 249, 0.6);
    box-shadow: 0 20px 32px rgba(4, 14, 24, 0.45);
}

.ff-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    gap: 0.5rem;
}

.ff-card-badge,
.ff-card-mode {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding: 0.2rem 0.6rem;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.ff-card-badge {
    background: rgba(34, 211, 238, 0.2);
    color: #67e8f9;
    border: 1px solid rgba(165, 243, 252, 0.38);
}

.ff-card-mode {
    background: rgba(251, 146, 60, 0.18);
    color: #fdba74;
    border: 1px solid rgba(251, 191, 36, 0.34);
}

.ff-game-card .game-icon {
    margin: 0;
    font-size: 2.8rem;
}

.ff-game-card h2 {
    margin: 0.35rem 0 0.5rem;
    font-size: 1.35rem;
    line-height: 1.2;
}

.ff-game-card p {
    font-size: 0.95rem;
    min-height: 56px;
    color: #dbeafe;
    margin-bottom: 1rem;
}

.ff-game-card .play-btn {
    width: 100%;
    margin: 0;
    border-radius: 12px;
    padding: 0.8rem 1rem;
    text-transform: none;
    letter-spacing: 0.02em;
    font-family: 'Rajdhani', 'Sora', sans-serif;
    font-size: 1rem;
    background: linear-gradient(120deg, #06b6d4, #1d4ed8);
    box-shadow: 0 10px 24px rgba(29, 78, 216, 0.34);
}

.ff-game-card .game-info {
    margin-top: 1rem;
    padding-top: 0.85rem;
    border-top: 1px solid rgba(165, 243, 252, 0.22);
}

.ff-game-card .game-info span {
    color: #a5f3fc;
    font-size: 0.82rem;
}

.ff-feature-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.8rem;
    margin-top: 0.8rem;
}

.ff-feature-item {
    border-radius: 16px;
    border: 1px solid rgba(167, 243, 208, 0.28);
    background: rgba(7, 26, 42, 0.68);
    padding: 1rem 1.1rem;
}

.ff-feature-item h3 {
    margin-bottom: 0.4rem;
    color: #5eead4;
    font-size: 1rem;
}

.ff-feature-item p {
    color: #d1fae5;
    font-size: 0.92rem;
}

.ff-home-footer {
    margin-top: 1.2rem;
    padding-top: 1.2rem;
    border-top: 1px solid rgba(165, 243, 252, 0.2);
}

.ff-home-footer p {
    color: #bae6fd;
}

.ff-empty-state {
    grid-column: 1 / -1;
    border: 1px dashed rgba(125, 211, 252, 0.55);
    border-radius: 16px;
    background: rgba(8, 24, 40, 0.6);
    padding: 1.4rem;
    text-align: center;
    color: #dbeafe;
}

@media (max-width: 1024px) {
    .ff-hero {
        grid-template-columns: 1fr;
    }

    .ff-controls {
        grid-template-columns: 1fr 1fr;
    }

    .ff-room-launcher-controls {
        grid-template-columns: 1fr 1fr;
    }

    .ff-room-join-btn {
        grid-column: 1 / -1;
        width: 100%;
    }

    .ff-feature-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .home-page .container.ff-home-container {
        padding: 1rem;
    }

    .ff-profile-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 0.8rem;
        padding: 0.9rem;
    }

    .ff-top-actions {
        justify-content: space-between;
    }

    .ff-top-btn {
        flex: 1;
        font-size: 0.9rem;
        padding: 0.55rem 0.7rem;
    }

    .ff-hero-copy {
        padding: 1.35rem;
    }

    .ff-controls {
        grid-template-columns: 1fr;
    }

    .ff-room-launcher-controls {
        grid-template-columns: 1fr;
    }

    .ff-lobby-donate {
        flex-direction: column;
        align-items: stretch;
    }

    .home-page .ff-lobby-donate .ff-donate-btn {
        width: 100%;
    }

    .ff-game-card p {
        min-height: auto;
    }
}
