/* Lobby-specific CSS */

.lobby-grid {
    display: grid;
    grid-template-columns: 1.7fr 1.3fr;
    gap: 20px;
    height: calc(100vh - 100px);
    margin-top: 0;
    transition: grid-template-columns 0.3s ease, gap 0.3s ease;
}

#mobile-panel-main {
    grid-column: 1;
    grid-row: 1;
}

#mobile-panel-solo {
    grid-column: 1;
    background: var(--bg-panel);
    border-radius: 12px;
    padding: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid var(--input-border);
}

#mobile-panel-rooms {
    grid-column: 2;
}

/* Hide mobile navigation buttons on desktop */
.mobile-nav-btn {
    display: none;
}

/* Widescreen balanced columns and expanded Active Rooms panel */
@media (min-width: 1440px) {
    .lobby-grid {
        grid-template-columns: 1.6fr 1.2fr; /* Stretch active rooms horizontally */
        gap: 24px;
    }
}
@media (min-width: 1680px) {
    .lobby-grid {
        grid-template-columns: 1.5fr 1.3fr; /* Give even more room to the active rooms panel on ultra-wide */
        gap: 32px;
    }
}
@media (min-width: 1920px) {
    .lobby-grid {
        grid-template-columns: 1.4fr 1.4fr; /* Perfectly balanced panels on ultra-wide screens */
        gap: 40px;
    }
}

.game-types-panel {
    background: var(--bg-panel);
    border-radius: 12px;
    padding: 20px;
    overflow-y: auto;
    backdrop-filter: blur(10px);
    max-height: 100%;
}

.game-section {
    margin-bottom: 30px;
}

.game-title {
    font-size: 1.0rem;
    font-weight: 700;
    margin-bottom: 8px;
    text-align: center;
    color: var(--text-primary);
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.game-matrix {
    display: grid;
    gap: 8px;
}

.matrix-header,
.matrix-row {
    display: grid;
    grid-template-columns: 60px repeat(4, 1fr);
    gap: 8px;
    align-items: center;
}

.matrix-3d .matrix-header,
.matrix-3d .matrix-row {
    grid-template-columns: 60px 1fr;
}

.corner-cell {
    width: 60px;
    height: 35px;
}

.dim-label,
.time-label {
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    color: var(--text-primary);
    padding: 8px;
    border-radius: 6px;
    text-align: center;
    font-weight: 600;
    font-size: 0.9rem;
}

.game-btn {
    padding: 10px;
    border: 1px solid var(--input-border);
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    color: #fff;
    /* Static white for colorful buttons is fine usually, but check contrast */
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.game-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(var(--text-primary-rgb), 0.2), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.game-btn:hover::before {
    opacity: 1;
}

.acc-btn {
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    box-shadow: 0 4px 15px rgba(37, 117, 252, 0.3);
}

.fcfs-btn {
    background: linear-gradient(135deg, #ff0844 0%, #ffb199 100%);
    box-shadow: 0 4px 15px rgba(255, 8, 68, 0.3);
}

.split-btn {
    background: linear-gradient(135deg, #00c6ff 0%, #0072ff 100%);
    box-shadow: 0 4px 15px rgba(0, 114, 255, 0.3);
}

.game-btn:hover {
    transform: translateY(-3px) scale(1.02);
    border-color: var(--accent-color);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
    z-index: 1;
}

.game-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.active-rooms-panel {
    background: var(--bg-panel);
    border-radius: 12px;
    padding: 20px;
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-height: 100%;
    min-height: 0;
}

.active-rooms-panel h3 {
    font-size: 1.5rem;
    text-align: center;
    margin: 0;
}

.rating-filter-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    width: 100%;
}

#rating-filter {
    grid-column: span 2;
    width: 100%;
    padding: 12px 8px;
    background: var(--input-bg);
    border: 2px solid var(--input-border);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.85rem;
}

#rating-filter::placeholder {
    color: var(--muted-text);
}

#rating-filter:focus {
    outline: none;
    border-color: var(--accent-color);
    background: var(--input-bg);
    filter: brightness(1.2);
}

#find-rating-btn {
    grid-column: span 1;
    width: 100%;
    padding: 12px 8px;
    background: linear-gradient(135deg, var(--accent-color, #ff0844) 0%, #ffb199 100%);
    border: none;
    border-radius: 8px;
    color: #fff;
    font-weight: 700;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.15);
    white-space: nowrap;
}

#find-rating-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(255, 8, 68, 0.35);
    filter: brightness(1.1);
}

#find-rating-btn:active {
    transform: translateY(0);
}

#my-rating-btn {
    grid-column: span 1;
    width: 100%;
    padding: 12px 8px;
    background: linear-gradient(135deg, #2575fc 0%, #6a11cb 100%);
    border: none;
    border-radius: 8px;
    color: #fff;
    font-weight: 700;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.15);
    white-space: nowrap;
}

#my-rating-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(37, 117, 252, 0.35);
    filter: brightness(1.1);
}

#my-rating-btn:active {
    transform: translateY(0);
}

/* Widescreen desktop/laptop side-by-side override */
@media (min-width: 901px) {
    .rating-filter-container {
        display: flex;
        gap: 8px;
    }
    #rating-filter {
        flex: 1;
        grid-column: auto;
        min-width: 185px;
        padding: 12px;
        font-size: 1rem;
    }
    #find-rating-btn {
        grid-column: auto;
        width: auto;
        padding: 12px 15px;
        font-size: 0.95rem;
    }
    #my-rating-btn {
        grid-column: auto;
        width: auto;
        padding: 12px 15px;
        font-size: 0.95rem;
    }
}


#selected-game-info {
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--text-primary);
}

#rooms-list {
    flex: 1;
    background: rgba(0, 0, 0, 0.15);
    border: 1px solid var(--input-border);
    border-radius: 8px;
    padding: 15px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

#rooms-list .placeholder {
    text-align: center;
    color: var(--muted-text);
    font-style: italic;
    margin-top: 20px;
}

#rooms-list .placeholder-icon {
    display: block;
    width: 200px;
    max-width: 80%;
    height: auto;
    margin: 30px auto;
    border-radius: 50%;
    overflow: hidden;
}

/* Room Item Styling - "Pretty" */
.room-item {
    background: var(--input-bg);
    border-radius: 10px;
    padding: 12px;
    border: 1px solid var(--input-border);
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.room-item:hover {
    background: var(--input-bg);
    border-color: var(--accent-color);
    opacity: 1;
}

.room-header-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.room-status {
    font-size: 0.8rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.room-status.active {
    background: rgba(46, 204, 113, 0.3);
    color: #2ecc71;
    border: 1px solid rgba(46, 204, 113, 0.5);
}

.room-status.waiting {
    background: rgba(241, 196, 15, 0.3);
    color: #f1c40f;
    border: 1px solid rgba(241, 196, 15, 0.5);
}

.room-status.intermission {
    background: rgba(52, 152, 219, 0.3);
    color: #3498db;
    border: 1px solid rgba(52, 152, 219, 0.5);
}

.room-meta {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: flex-end;
    font-size: 0.85rem;
    opacity: 0.9;
}

.room-avg-rating {
    padding: 3px 6px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    white-space: nowrap;
    border: 1px solid rgba(255, 255, 255, 0.03);
    display: inline-block;
}

.rating-req-badge {
    background: rgba(231, 76, 60, 0.2);
    color: #e74c3c;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85em;
    border: 1px solid rgba(231, 76, 60, 0.3);
    white-space: nowrap;
}

.room-players-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.player-tag {
    background: var(--input-bg);
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 0.85rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    border: 1px solid var(--input-border);
}

.join-room-btn {
    width: 100%;
    padding: 8px;
    background: #27ae60;
    color: var(--text-primary);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.2s;
}

.join-room-btn:hover {
    background: #2ecc71;
}

/* Inline Rating Inputs for Create Room */
.create-room-panel {
    background: var(--bg-panel);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
    border: 1px solid var(--input-border);
}

.rating-inputs-row {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.rating-input {
    flex: 1;
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    border-radius: 4px;
    padding: 8px;
    color: var(--text-primary);
    font-size: 14px;
    text-align: center;
}

.rating-input::placeholder {
    color: var(--muted-text);
}

.rating-input:focus {
    outline: none;
    border-color: var(--accent-color);
    background: var(--input-bg);
    filter: brightness(1.2);
}

.confirm-create-room-btn {
    width: 100%;
    background: linear-gradient(135deg, #2ecc71, #27ae60);
    color: var(--text-primary);
    border: none;
    padding: 10px;
    border-radius: 4px;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    font-size: 1em;
}

.confirm-create-room-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(46, 204, 113, 0.3);
}

.confirm-create-room-btn:active {
    transform: translateY(0);
}

/* Contact Page Styling */
.contact-container {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    /* Changed from center to prevent top overlap */
    min-height: calc(100vh - 100px);
    /* Changed from height to min-height */
    padding: 30px 20px;
    /* Added more top padding */
    overflow-y: auto;
}

.contact-card {
    background: var(--bg-panel);
    backdrop-filter: blur(15px);
    border: 1px solid var(--input-border);
    border-radius: 20px;
    padding: 30px 40px;
    /* Reduced vertical padding from 40px to 30px */
    width: 100%;
    max-width: 500px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    animation: fadeInSlideUp 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

@keyframes fadeInSlideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.contact-card h2 {
    font-size: 1.8rem;
    margin-bottom: 5px;
    text-align: center;
    color: var(--text-primary);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.contact-desc {
    text-align: center;
    color: var(--text-70);
    margin-bottom: 20px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    /* Reduced gap from 20px */
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
    /* Reduced from 8px */
}

.form-group label {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--muted-text);
    text-transform: uppercase;
    letter-spacing: 1.2px;
    padding-left: 5px;
    margin-bottom: 2px;
}

.contact-form input,
.contact-form textarea {
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    border-radius: 12px;
    padding: 10px 15px;
    /* Reduced vertical padding from 12px to 10px */
    color: var(--text-primary);
    font-size: 0.95rem;
    /* Slightly smaller font */
    transition: all 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    background: rgba(0, 0, 0, 0.5);
    border-color: rgba(37, 117, 252, 0.5);
    box-shadow: 0 0 15px rgba(37, 117, 252, 0.2);
}

.contact-form input[readonly] {
    background: var(--input-bg);
    opacity: 0.6;
    cursor: not-allowed;
}

.field-hint {
    font-size: 0.7rem;
    color: var(--text-muted-fixed, var(--muted-text));
    padding-left: 5px;
    opacity: 0.85;
}

.submit-contact-btn {
    margin-top: 5px;
    /* Reduced from 10px */
    padding: 12px;
    /* Reduced vertical padding from 15px to 12px */
    background: linear-gradient(135deg, #2575fc 0%, #6a11cb 100%);
    border: none;
    border-radius: 12px;
    color: #fff;
    font-weight: 700;
    font-size: 0.95rem;
    /* Slightly smaller font */
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 10px 20px rgba(37, 117, 252, 0.2);
}

.submit-contact-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(37, 117, 252, 0.4);
    filter: brightness(1.1);
}

.submit-contact-btn:active {
    transform: translateY(-1px);
}

.btn-icon {
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.submit-contact-btn:hover .btn-icon {
    transform: translateX(5px) translateY(-5px) rotate(-15deg);
}

.contact-status {
    text-align: center;
    font-size: 0.9rem;
    min-height: 20px;
}

.contact-status.success {
    color: #2ecc71;
}

.contact-status.error {
    color: #e74c3c;
}

/* SF Participant Pills */
.player-pill {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    margin-right: 4px;
    background: rgba(var(--text-primary-rgb), 0.1);
    border: 1px solid rgba(var(--text-primary-rgb), 0.05);
}

.player-pill.pending {
    opacity: 0.6;
    font-style: italic;
    background: rgba(241, 196, 15, 0.1);
    color: #f1c40f;
}

.player-pill.accepted {
    background: rgba(46, 204, 113, 0.1);
    color: #2ecc71;
}

/* Invites Badge */
/* Invites Badge */
.sf-subtab-btn,
.sf-tab-btn {
    position: relative;
}

.sf-subtab-btn .badge,
.sf-tab-btn .badge {
    background: var(--accent-color);
    color: var(--btn-text, #000);
    /* Use theme-aware button text color */
    font-size: 0.7rem;
    padding: 1px 6px;
    border-radius: 10px;
    font-weight: 800;
    margin-left: 5px;
    pointer-events: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
}

/* Ensure badges are highly visible in dark themes by making them white/light if needed */
/* This targets the default theme (no class) and all dark-mode classes */
body:not([class*="theme-white"]):not([class*="theme-light-"]):not(.theme-yellow):not(.theme-pink):not(.theme-orange):not(.theme-gray):not(.theme-light-brown) .badge {
    background: #ffffff !important;
    color: #000000 !important;
}

/* Specific theme overrides */
body.theme-white .badge,
body[class*="theme-light-"] .badge,
body.theme-yellow .badge,
body.theme-pink .badge,
body.theme-orange .badge,
body.theme-gray .badge,
body.theme-light-brown .badge {
    background: #333333 !important;
    color: #ffffff !important;
}

/* Specific Overrides for White/Light Themes on Contact Page Readability */
body[class*="theme-white"] .contact-desc,
body[class*="theme-light-"] .contact-desc,
body.theme-yellow .contact-desc,
body.theme-pink .contact-desc,
body.theme-orange .contact-desc,
body.theme-light-brown .contact-desc {
    color: #444 !important;
}

body[class*="theme-white"] .form-group label,
body[class*="theme-light-"] .form-group label,
body.theme-yellow .form-group label,
body.theme-pink .form-group label,
body.theme-orange .form-group label,
body.theme-light-brown .form-group label {
    color: #333 !important;
    opacity: 1 !important;
}

body[class*="theme-white"] .field-hint,
body[class*="theme-light-"] .field-hint,
body.theme-yellow .field-hint,
body.theme-pink .field-hint,
body.theme-orange .field-hint,
body.theme-light-brown .field-hint {
    color: #555 !important;
    opacity: 1 !important;
}

.invite-panel {
    border-left: 4px solid var(--accent-color);
    background: rgba(var(--accent-rgb), 0.05);
}
/* Store Page Styling */
#tool-store {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
}

.store-tabs {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 30px 0;
}

.store-tab {
    padding: 10px 25px;
    background: rgba(var(--text-primary-rgb), 0.1);
    border: 1px solid rgba(var(--text-primary-rgb), 0.2);
    border-radius: 20px;
    color: var(--text-primary);
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
}

.store-tab.active {
    background: var(--accent-color);
    color: #fff;
    border-color: var(--accent-color);
    box-shadow: 0 4px 15px rgba(233, 69, 96, 0.3);
}

.store-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 20px;
}

.store-item {
    background: var(--bg-panel);
    border: 1px solid var(--input-border);
    border-radius: 24px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.store-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.store-item-image {
    width: 100%;
    height: 250px;
    overflow: hidden;
    background: #000;
}

.store-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.store-item:hover .store-item-image img {
    transform: scale(1.05);
}

.store-item-info {
    padding: 25px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    flex-grow: 1;
}

.store-item-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}

.store-item-header h3 {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 800;
}

.store-item-price {
    font-size: 1.2rem;
    font-weight: 900;
    color: var(--accent-color);
}

.store-item-desc {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.5;
    opacity: 0.8;
}

.store-item-features {
    padding: 0;
    margin: 0;
    list-style: none;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.store-item-features li {
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 6px;
    opacity: 0.9;
}

.store-item-features li::before {
    content: '✓';
    color: #2ecc71;
    font-weight: 900;
}

.buy-now-btn {
    margin-top: auto;
    display: block;
    text-align: center;
    padding: 15px;
    background: linear-gradient(135deg, #FF9900 0%, #FFCC00 100%);
    color: #111 !important;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: filter 0.2s;
}

.buy-now-btn:hover {
    filter: brightness(1.1);
}

/* Tablet & Mobile Layout for Lobby Grid */
@media (max-width: 900px) {
    .lobby-grid {
        display: flex !important;
        flex-direction: row !important;
        overflow-x: auto !important;
        scroll-snap-type: x mandatory !important;
        -webkit-overflow-scrolling: touch !important;
        scroll-behavior: smooth !important;
        gap: 0 !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    .game-types-panel,
    .active-rooms-panel,
    .solo-friends-panel {
        flex: 0 0 100% !important;
        width: 100% !important;
        scroll-snap-align: center !important;
        scroll-snap-stop: always !important; /* Prevent skipping panels on fast swipe */
        max-height: none !important;
        padding: 12px !important;
        box-sizing: border-box !important;
        overflow-y: auto !important;
    }

    .mobile-nav-btn {
        display: block !important;
        width: 100%;
        padding: 15px;
        margin-bottom: 15px;
        background: rgba(var(--text-primary-rgb), 0.05);
        border: 1px solid var(--input-border);
        color: var(--text-primary);
        font-weight: 800;
        border-radius: 12px;
        text-transform: uppercase;
        cursor: pointer;
    }

    /* Snug styling for game config matrices on mobile screen */
    .matrix-header,
    .matrix-row {
        grid-template-columns: 45px repeat(4, 1fr) !important;
        gap: 4px !important;
    }

    .corner-cell,
    .dim-label,
    .time-label {
        width: auto !important;
        padding: 4px !important;
        font-size: 0.72rem !important;
        border-radius: 4px !important;
        text-align: center !important;
    }

    .game-btn {
        padding: 5px 2px !important;
        font-size: 0.65rem !important;
        border-radius: 6px !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        word-break: break-word !important;
        line-height: 1.15 !important;
        text-align: center !important;
        display: inline-flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        min-height: 46px !important;
        box-sizing: border-box !important;
    }

    /* Style the room player pills beautifully to wrap snuggly on mobile screens */
    .room-players-row {
        gap: 4px !important;
    }

    .room-player-pill {
        display: inline-flex !important;
        align-items: center !important;
        background: rgba(255, 255, 255, 0.05) !important;
        border: 1px solid rgba(255, 255, 255, 0.1) !important;
        padding: 3px 6px !important;
        border-radius: 5px !important;
        font-size: 0.75rem !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        word-break: break-all !important;
    }

    #rooms-list .placeholder-icon {
        width: 200px !important;
        max-width: 75% !important;
        margin: 20px auto !important;
        filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.15));
        border-radius: 50%;
        animation: pulseLogo 3s infinite ease-in-out;
    }

    /* Constrain the Create Room rating inputs to fit snuggly and avoid iOS auto-zoom */
    .create-room-panel {
        padding: 10px !important;
        margin-bottom: 15px !important;
    }

    .rating-inputs-row {
        gap: 6px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .rating-input {
        width: 100% !important;
        min-width: 0 !important;
        font-size: 16px !important; /* Prevent iOS browser auto-zoom layout stretching */
        padding: 8px 4px !important;
        box-sizing: border-box !important;
    }
}

@keyframes pulseLogo {
    0%, 100% {
        transform: scale(1);
        filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.1));
    }
    50% {
        transform: scale(1.04);
        filter: drop-shadow(0 0 25px rgba(255, 255, 255, 0.25));
    }
}

/* PC Widescreen Horizontal Store Item Card Overrides */
@media (min-width: 900px) {
    .store-grid {
        grid-template-columns: 1fr !important;
        gap: 35px !important;
    }

    .store-item {
        flex-direction: row !important;
        align-items: stretch !important;
        min-height: 280px !important;
        max-height: 340px !important;
    }

    .store-item-image {
        width: 340px !important;
        min-width: 340px !important;
        height: 100% !important;
    }

    .store-item-info {
        flex: 1 !important;
        padding: 30px !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
        gap: 15px !important;
        overflow-y: auto !important; /* Enable inner text scrolling if content overflows max-height */
    }

    /* Premium styled scrollbars for the Store text panels */
    .store-item-info::-webkit-scrollbar {
        width: 6px;
    }

    .store-item-info::-webkit-scrollbar-track {
        background: rgba(0, 0, 0, 0.15);
        border-radius: 10px;
    }

    .store-item-info::-webkit-scrollbar-thumb {
        background: rgba(var(--text-primary-rgb), 0.15);
        border-radius: 10px;
        transition: background 0.3s ease;
    }

    .store-item-info::-webkit-scrollbar-thumb:hover {
        background: var(--accent-color, #ff007f);
    }

    .store-item-features {
        grid-template-columns: repeat(4, 1fr) !important; /* Spread features horizontally across 4 columns */
        gap: 12px !important;
}

/* Journey message styling with responsive typography */
.lobby-journey-message {
    text-align: center;
    margin: 5px auto 25px auto;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--accent-color);
    letter-spacing: 1.5px;
    text-shadow: 0 0 10px rgba(255, 0, 127, 0.25);
    width: 100%;
    box-sizing: border-box;
    text-transform: uppercase;
    white-space: nowrap;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
}

@media (max-width: 900px) {
    .lobby-journey-message {
        font-size: 0.8rem;
        letter-spacing: 0.8px;
        margin: 15px auto 20px auto;
        padding: 12px 16px;
        background: rgba(255, 0, 127, 0.06);
        border: 1px solid rgba(255, 0, 127, 0.15);
        border-radius: 8px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
        display: block;
        width: 92%;
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 480px) {
    .lobby-journey-message {
        font-size: 0.65rem;
        letter-spacing: 0.5px;
        margin: 15px auto 25px auto;
        padding: 14px 16px;
        background: rgba(255, 0, 127, 0.08);
        border: 1px solid rgba(255, 0, 127, 0.2);
        border-radius: 10px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
        display: block;
        width: 90%;
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 480px) {
    .rating-filter-container {
        gap: 4px !important;
    }
    #rating-filter {
        padding: 10px 6px !important;
        font-size: 0.8rem !important;
    }
    #rating-filter::placeholder {
        font-size: 0.7rem !important;
    }
    #find-rating-btn, #my-rating-btn {
        padding: 10px 6px !important;
        font-size: 0.72rem !important;
    }
}

@media (max-width: 900px) {
    #tool-store {
        padding: 10px !important;
    }
    .store-tabs {
        width: 100% !important;
        max-width: 350px !important;
        gap: 4px !important;
        padding: 4px !important;
        box-sizing: border-box !important;
        border-radius: 30px !important;
        margin: 20px auto !important;
    }
    .store-tab {
        flex: 1 !important;
        padding: 6px 2px !important;
        font-size: 0.72rem !important;
        border-radius: 20px !important;
        text-align: center !important;
        white-space: nowrap !important;
    }
}





