* {
    box-sizing: border-box;
}

:root {
    --bg-base: #07131a;
    --bg-deep: #0d2430;
    --panel: rgba(9, 26, 34, 0.9);
    --panel-strong: rgba(12, 34, 44, 0.95);
    --panel-soft: rgba(121, 214, 223, 0.08);
    --line: rgba(196, 236, 239, 0.16);
    --line-strong: rgba(244, 196, 76, 0.3);
    --text-main: #f4fbfc;
    --text-soft: #c5dde0;
    --text-muted: #89aab0;
    --accent: #f4c44c;
    --accent-strong: #ff993d;
    --accent-cool: #79d6df;
    --danger: #ff6b5e;
    --success: #7ef0a6;
    --shadow: 0 20px 44px rgba(0, 0, 0, 0.24);
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Trebuchet MS", "Lucida Sans Unicode", sans-serif;
    color: var(--text-main);
    background:
        radial-gradient(circle at 12% 10%, rgba(121, 214, 223, 0.18), transparent 24%),
        radial-gradient(circle at 84% 10%, rgba(244, 196, 76, 0.12), transparent 20%),
        linear-gradient(180deg, #061219 0%, #0a202a 42%, #123643 100%);
    overflow-x: hidden;
}

.layout {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 240px;
    padding: 18px 16px;
    border-right: 1px solid var(--line);
    background: linear-gradient(180deg, rgba(10, 27, 35, 0.98), rgba(7, 18, 24, 0.98));
}

.brand-area,
.hero-section,
.header,
.mobile-provider-section,
.search-box,
.search-results,
.featured,
.game-grid,
.pattern-modal-box,
.wd-toast {
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.brand-area,
.hero-section,
.header,
.mobile-provider-section,
.search-box,
.search-results,
.featured,
.game-grid {
    background: linear-gradient(180deg, rgba(12, 31, 40, 0.94), rgba(8, 21, 28, 0.96));
}

.brand-area {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 18px;
    padding: 18px 14px;
    border-radius: 20px;
    overflow: hidden;
}

.brand-area::before {
    content: "";
    position: absolute;
    width: 170px;
    height: 170px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(244, 196, 76, 0.18), transparent 70%);
}

.brand-area > a,
.mobile-top-auth {
    position: relative;
    z-index: 1;
}

.brand-logo {
    width: 160px;
    max-width: 100%;
    display: block;
    filter: drop-shadow(0 8px 24px rgba(244, 196, 76, 0.24));
}

.sidebar-title,
.section-title,
.hero-kicker,
.hero-tag,
.hero-provider-label,
.mobile-provider-hint,
.pg-label,
.pattern-spin,
.pattern-dc {
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.sidebar-title {
    margin-bottom: 10px;
    font-size: 11px;
    font-weight: 800;
    color: var(--accent);
}

#providerList {
    display: block;
}

.provider-item {
    margin-bottom: 8px;
    padding: 11px 12px;
    border-radius: 14px;
    border: 1px solid transparent;
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-soft);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.provider-item:hover {
    transform: translateX(3px);
    background: rgba(121, 214, 223, 0.08);
    border-color: rgba(121, 214, 223, 0.18);
}

.provider-item:focus-visible {
    outline: 2px solid rgba(244, 196, 76, 0.9);
    outline-offset: 2px;
}

.provider-item.active {
    background: linear-gradient(90deg, #ffe08a 0%, #f4c44c 45%, #ff993d 100%);
    color: #182229;
    border-color: transparent;
}

.wrapper {
    flex: 1;
    min-width: 0;
    max-width: 1320px;
    margin: 0 auto;
    padding: 24px 28px 34px;
}

.hero-section {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.18fr) minmax(320px, 420px);
    align-items: stretch;
    gap: 20px;
    padding: 24px;
    border-radius: 22px;
    overflow: hidden;
}

.hero-section::before {
    content: "";
    position: absolute;
    inset: -44px auto auto -44px;
    width: 190px;
    height: 190px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(121, 214, 223, 0.16), transparent 72%);
}

.hero-section::after {
    content: "";
    position: absolute;
    inset: auto -64px -92px auto;
    width: 240px;
    height: 240px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(244, 196, 76, 0.16), transparent 70%);
}

.hero-left,
.hero-right {
    position: relative;
    z-index: 1;
}

.hero-left {
    min-width: 0;
}

.hero-kicker,
.hero-tag,
.hero-provider-label,
.mobile-provider-hint,
.pg-label,
.pattern-spin,
.pattern-dc {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
}

.hero-kicker {
    padding: 7px 13px;
    font-size: 10px;
    color: var(--accent-cool);
    background: rgba(121, 214, 223, 0.1);
    border: 1px solid rgba(121, 214, 223, 0.18);
}

.hero-left h1,
.logo,
.section-title {
    background: linear-gradient(90deg, #fff0ae, #f4c44c, #ff993d);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-left h1 {
    margin: 16px 0 0;
    font-family: "Arial Black", "Impact", sans-serif;
    font-size: clamp(30px, 4vw, 44px);
    line-height: 1.02;
}

.hero-left p {
    max-width: 620px;
    margin: 10px 0 0;
    color: var(--text-soft);
    font-size: 14px;
    line-height: 1.7;
}

.hero-provider-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
}

.hero-provider-label {
    padding: 7px 12px;
    font-size: 10px;
    color: var(--accent-cool);
    background: rgba(121, 214, 223, 0.1);
    border: 1px solid rgba(121, 214, 223, 0.18);
}

#providerTitle {
    font-size: clamp(18px, 2vw, 24px);
    font-weight: 900;
    letter-spacing: 0.05em;
    color: #fff4bf;
}

.hero-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.hero-summary-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-top: 18px;
}

.hero-summary-item {
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid rgba(196, 236, 239, 0.12);
    background: rgba(255, 255, 255, 0.04);
}

.hero-summary-item span {
    display: block;
    color: var(--text-muted);
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero-summary-item strong {
    display: block;
    margin-top: 6px;
    color: #eefbfd;
    font-size: 14px;
    line-height: 1.4;
}

.hero-tag {
    padding: 8px 13px;
    font-size: 10px;
    color: #e8fbfd;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(196, 236, 239, 0.14);
}

.hero-right {
    display: grid;
    align-content: start;
    gap: 12px;
    min-width: 0;
    width: 100%;
}

.hero-card {
    min-width: 0;
    width: 100%;
    padding: 18px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(14, 35, 45, 0.95), rgba(9, 23, 31, 0.96));
    border: 1px solid rgba(196, 236, 239, 0.12);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.hero-card-title {
    margin-bottom: 10px;
    color: var(--text-soft);
    font-size: 12px;
    font-weight: 800;
}

.hero-live-value {
    font-family: "Arial Black", "Impact", sans-serif;
    font-size: clamp(28px, 3vw, 40px);
    line-height: 1;
    color: #fff0ae;
    text-shadow: 0 0 16px rgba(244, 196, 76, 0.18);
}

.hero-live-note {
    margin-top: 8px;
    color: var(--text-soft);
    font-size: 12px;
    line-height: 1.6;
}

.hero-mini-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 12px;
}

.hero-mini-grid span {
    display: flex;
    align-items: center;
    min-height: 42px;
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid rgba(196, 236, 239, 0.1);
    background: rgba(255, 255, 255, 0.04);
    color: #dff5f7;
    font-size: 11px;
    line-height: 1.45;
}

.hero-auth-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.hero-auth-btn,
.mobile-auth-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-weight: 800;
    transition: transform 0.18s ease, filter 0.18s ease, box-shadow 0.18s ease;
}

.hero-auth-btn {
    width: 100%;
    min-height: 40px;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid transparent;
    font-size: 12px;
    letter-spacing: 0.08em;
}

.hero-auth-btn.login,
.search-box button {
    color: #182229;
    background: linear-gradient(90deg, #ffe08a, #ff993d);
    border-color: transparent;
}

.hero-auth-btn.daftar {
    color: #e8fbfd;
    background: linear-gradient(90deg, rgba(121, 214, 223, 0.28), rgba(121, 214, 223, 0.14));
    border-color: rgba(121, 214, 223, 0.2);
}

.hero-auth-btn:hover,
.mobile-auth-btn:hover,
.search-box button:hover {
    transform: translateY(-1px);
    filter: brightness(1.04);
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    margin-top: 14px;
    padding: 18px 22px;
    border-radius: 20px;
}

.insight-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-top: 14px;
}

.insight-card {
    padding: 14px 16px;
    border-radius: 18px;
    border: 1px solid rgba(196, 236, 239, 0.12);
    background: linear-gradient(180deg, rgba(12, 31, 40, 0.9), rgba(8, 21, 28, 0.94));
    box-shadow: var(--shadow);
}

.insight-label {
    display: block;
    margin-bottom: 7px;
    color: var(--accent-cool);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.insight-card strong {
    display: block;
    color: var(--text-main);
    font-size: 14px;
    line-height: 1.5;
}

.logo {
    font-family: "Arial Black", "Impact", sans-serif;
    font-size: clamp(22px, 2.3vw, 30px);
    letter-spacing: 0.03em;
}

.stats {
    display: flex;
    gap: 12px;
    margin-left: auto;
}

.stat-box {
    min-width: 112px;
    padding: 10px 12px;
    border-radius: 14px;
    border: 1px solid rgba(196, 236, 239, 0.12);
    background: rgba(255, 255, 255, 0.04);
}

.stat-box span {
    display: block;
    color: var(--text-muted);
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.stat-box b {
    display: block;
    margin-top: 4px;
    color: var(--text-main);
    font-size: 15px;
}

.countdown-warning {
    color: var(--danger) !important;
}

.section-title {
    margin: 18px 0 10px;
    font-size: 12px;
    font-weight: 800;
}

.section-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.featured-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.featured-control-btn {
    width: 40px;
    height: 40px;
    border-radius: 999px;
    border: 1px solid rgba(196, 236, 239, 0.12);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-main);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.featured-control-btn:hover {
    transform: translateY(-1px);
    border-color: rgba(216, 177, 112, 0.22);
    background: rgba(216, 177, 112, 0.08);
}

.section-subtitle {
    margin: -2px 0 12px;
    color: var(--text-muted);
    font-size: 12px;
    line-height: 1.6;
}

.mobile-provider-section {
    display: none;
    padding: 12px;
    border-radius: 18px;
}

.mobile-provider-hint {
    display: none;
    margin-bottom: 8px;
    padding: 5px 10px;
    font-size: 10px;
    color: #ecfeff;
    background: rgba(121, 214, 223, 0.08);
    border: 1px solid rgba(196, 236, 239, 0.16);
    animation: providerHintPulse 1.6s ease-in-out infinite;
}

.mobile-provider-hint.show {
    display: inline-flex;
}

.provider-mobile-wrap {
    position: relative;
    border-radius: 14px;
}

.provider-mobile-wrap::before {
    content: "";
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 42px;
    background: linear-gradient(90deg, rgba(10, 27, 35, 0), rgba(10, 27, 35, 0.94));
    pointer-events: none;
}

.provider-mobile-wrap::after {
    content: ">>";
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    padding: 4px 6px;
    border-radius: 999px;
    border: 1px solid rgba(196, 236, 239, 0.2);
    background: rgba(7, 24, 32, 0.72);
    color: var(--text-soft);
    font-size: 10px;
    font-weight: 800;
    pointer-events: none;
}

.provider-mobile-wrap.touched::after {
    opacity: 0.15;
}

.provider-mobile-list,
#providerList {
    scrollbar-width: none;
}

.provider-mobile-list::-webkit-scrollbar,
#providerList::-webkit-scrollbar,
.featured::-webkit-scrollbar {
    display: none;
}

.provider-mobile-list {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 2px 44px 6px 4px;
    scroll-padding-inline: 4px 44px;
    scroll-snap-type: x mandatory;
}

.provider-mobile-list .provider-item {
    flex: 0 0 auto;
    white-space: nowrap;
    scroll-snap-align: start;
    margin-bottom: 0;
}

.featured {
    display: flex;
    flex-wrap: nowrap;
    gap: 14px;
    overflow-x: auto;
    padding: 6px 0 2px;
    border-radius: 18px;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    touch-action: pan-x;
}

.featured-hint {
    margin: 6px 2px 0;
    color: rgba(214, 241, 246, 0.58);
    font-size: 10px;
}

.featured .grid-state {
    min-width: 100%;
}

.featured.featured-desktop {
    scroll-snap-type: x proximity;
    cursor: grab;
}

.featured.featured-desktop.is-dragging {
    cursor: grabbing;
    user-select: none;
}

.featured-card {
    flex: 0 0 236px;
    min-width: 236px;
    aspect-ratio: 16 / 9;
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: 18px;
    border: 1px solid rgba(196, 236, 239, 0.16);
    background-size: cover;
    background-position: center;
    background-color: rgba(8, 18, 24, 0.96);
    text-decoration: none;
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.24);
    transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.featured-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(7, 16, 22, 0.04), rgba(7, 16, 22, 0.18) 45%, rgba(7, 16, 22, 0.82)),
        radial-gradient(circle at 18% 18%, rgba(244, 196, 76, 0.12), transparent 30%);
    pointer-events: none;
}

.featured-card:hover {
    transform: translateY(-4px);
    border-color: rgba(244, 196, 76, 0.36);
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.3);
}

.featured-card:focus-visible {
    outline: 2px solid rgba(244, 196, 76, 0.9);
    outline-offset: 3px;
}

.featured-card.is-linked {
    box-shadow: 0 0 0 2px rgba(244, 196, 76, 0.24), 0 16px 30px rgba(0, 0, 0, 0.3);
}

.featured-overlay {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    display: grid;
    gap: 8px;
    padding: 10px 12px 12px;
    background: linear-gradient(to top, rgba(7, 10, 13, 0.92), rgba(7, 10, 13, 0.18));
    color: var(--text-soft);
    font-size: 11px;
}

.featured-meta,
.featured-body {
    display: flex;
    align-items: center;
    gap: 8px;
}

.featured-body {
    justify-content: flex-start;
}

.featured-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(111, 206, 255, 0.16);
    border: 1px solid rgba(111, 206, 255, 0.26);
    color: #effcff;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.featured-name {
    flex: 1;
    min-width: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.28;
    color: #f5f7fa;
}

.game-search {
    margin-top: 10px;
}

.search-box {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 10px;
    border-radius: 18px;
}

.search-box input {
    flex: 1;
    padding: 11px 12px;
    border-radius: 12px;
    border: 1px solid rgba(196, 236, 239, 0.14);
    background: rgba(4, 12, 16, 0.82);
    color: var(--text-main);
    font-size: 12px;
    outline: none;
}

.search-box input::placeholder {
    color: rgba(214, 241, 246, 0.6);
}

.search-box button {
    flex: 0 0 auto;
    padding: 10px 16px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
}

.search-meta {
    margin: 8px 2px;
    color: rgba(214, 241, 246, 0.72);
    font-size: 11px;
}

.search-results,
.game-grid {
    display: grid;
    gap: 14px;
    padding: 14px;
    border-radius: 18px;
}

.search-results {
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    min-height: 120px;
}

.game-grid {
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    min-height: 200px;
}

.search-empty,
.game-grid:empty::before {
    padding: 26px;
    text-align: center;
    color: rgba(214, 241, 246, 0.6);
    font-size: 12px;
}

.search-empty strong,
.grid-state strong {
    display: block;
    margin-bottom: 6px;
    color: var(--text-main);
    font-size: 14px;
}

.search-empty span,
.grid-state span {
    display: block;
}

.grid-state {
    grid-column: 1 / -1;
    padding: 28px 20px;
    text-align: center;
    color: rgba(214, 241, 246, 0.72);
    font-size: 12px;
    line-height: 1.7;
}

.game-grid.is-loading,
.search-results.is-loading {
    position: relative;
}

.game-grid.is-loading::before,
.search-results.is-loading::before {
    content: "Memuat data provider...";
    display: block;
    grid-column: 1 / -1;
    padding: 28px 20px;
    text-align: center;
    color: rgba(214, 241, 246, 0.7);
    font-size: 12px;
}

.game-grid:empty::before {
    content: "Game belum tersedia";
    display: block;
}

.grid-card {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    border-radius: 16px;
    border: 1px solid rgba(196, 236, 239, 0.14);
    background: linear-gradient(180deg, rgba(14, 35, 45, 0.95), rgba(9, 23, 31, 0.96));
    animation: fadeUp 0.45s ease forwards;
    transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.grid-card::before {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: 17px;
    padding: 1px;
    background: linear-gradient(140deg, rgba(244, 196, 76, 0.55), rgba(255, 153, 61, 0.35), rgba(126, 240, 166, 0.22));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
}

.grid-card::after {
    content: "";
    position: absolute;
    top: -18%;
    left: -58%;
    width: 42%;
    height: 140%;
    transform: skewX(-18deg);
    background: linear-gradient(110deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0));
    opacity: 0.65;
    pointer-events: none;
    animation: glassSweep 5s ease-in-out infinite;
}

.grid-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 28px rgba(0, 0, 0, 0.32);
    border-color: rgba(244, 196, 76, 0.24);
}

.grid-card.is-spotlight {
    border-color: rgba(244, 196, 76, 0.58);
    box-shadow: 0 0 0 2px rgba(244, 196, 76, 0.18), 0 18px 30px rgba(0, 0, 0, 0.34);
}

.grid-card:hover::before {
    opacity: 1;
}

.grid-inner {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    background:
        radial-gradient(circle at 50% 26%, rgba(244, 196, 76, 0.16), transparent 34%),
        linear-gradient(180deg, rgba(11, 27, 36, 0.98), rgba(6, 16, 22, 0.98));
}

.grid-card img,
.search-card img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: contain;
    display: block;
    padding: 10px;
    filter: contrast(1.04) saturate(1.06) drop-shadow(0 14px 24px rgba(0, 0, 0, 0.24));
    image-rendering: auto;
    backface-visibility: hidden;
    transition: transform 0.35s ease;
}

.grid-card:hover img {
    transform: scale(1.035);
}

.grid-inner::before {
    content: "";
    position: absolute;
    inset: 10px 10px auto;
    height: calc(100% - 66px);
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.01));
    pointer-events: none;
}

.grid-info {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    padding: 10px 12px;
    border-top: 1px solid rgba(196, 236, 239, 0.08);
    color: var(--text-soft);
    font-size: 11px;
    min-width: 0;
}

.grid-info span:first-child {
    min-width: 0;
    flex: 1 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rtp {
    flex: 0 0 auto;
    font-size: 13px;
    font-weight: 800;
}

.rtp-low {
    color: #ff7e72;
}

.rtp-mid {
    color: #ffd166;
}

.rtp-high,
.high-rtp {
    color: var(--success);
    font-weight: 800;
}

.search-card .grid-info {
    padding: 8px 10px;
}

.search-info {
    align-items: flex-start;
}

.search-left {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.search-note {
    color: rgba(175, 224, 230, 0.88);
    font-size: 10px;
}

.pattern-clickable {
    cursor: pointer;
}

.pattern-clickable .grid-inner {
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.pattern-clickable:hover .grid-inner {
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.28);
}

.grid-cta {
    position: absolute;
    left: 10px;
    right: 10px;
    bottom: 58px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 34px;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid rgba(244, 196, 76, 0.22);
    background: linear-gradient(180deg, rgba(7, 20, 28, 0.86), rgba(10, 29, 39, 0.92));
    color: #eefbfd;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    box-shadow: 0 10px 18px rgba(0, 0, 0, 0.24);
    pointer-events: none;
    opacity: 0.94;
    animation: pulseCta 1.9s ease-in-out infinite;
}

.grid-cta span {
    color: #182229;
    padding: 4px 8px;
    border-radius: 999px;
    background: linear-gradient(180deg, #f0d9ae 0%, #d8b170 100%);
}

.pattern-clickable:hover .grid-cta,
.grid-card.is-spotlight .grid-cta,
.search-card:hover .grid-cta {
    background: linear-gradient(180deg, rgba(9, 24, 33, 0.94), rgba(13, 35, 45, 0.96));
    border-color: rgba(244, 196, 76, 0.38);
}

@keyframes pulseCta {
    0%, 100% {
        transform: translateY(0);
        box-shadow: 0 10px 18px rgba(0, 0, 0, 0.24);
    }
    50% {
        transform: translateY(-2px);
        box-shadow: 0 14px 24px rgba(0, 0, 0, 0.32);
    }
}

.pattern-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 14px;
    z-index: 9999;
    background: rgba(2, 6, 23, 0.72);
    backdrop-filter: blur(7px);
}

.pattern-modal.show {
    display: flex;
}

.pattern-modal-box {
    width: min(540px, 100%);
    padding: 16px 14px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(14, 35, 45, 0.96), rgba(8, 22, 30, 0.96));
    color: var(--text-main);
}

.pattern-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    border: 1px solid rgba(196, 236, 239, 0.18);
    border-radius: 10px;
    background: rgba(121, 214, 223, 0.12);
    color: var(--text-main);
    font-family: Arial, "Segoe UI", sans-serif;
    font-size: 20px;
    font-weight: 800;
    cursor: pointer;
}

.pattern-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
}

.pattern-provider {
    margin-bottom: 6px;
    color: var(--accent-cool);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.pattern-title {
    font-size: 18px;
    font-weight: 800;
    color: var(--text-main);
}

.pattern-copy-btn {
    flex: 0 0 auto;
    min-height: 38px;
    padding: 0 14px;
    border: 1px solid rgba(196, 236, 239, 0.16);
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(121, 214, 223, 0.24), rgba(121, 214, 223, 0.14));
    color: #eefbfd;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.18s ease, filter 0.18s ease, background 0.18s ease;
}

.pattern-copy-btn:hover {
    transform: translateY(-1px);
    filter: brightness(1.05);
}

.pattern-copy-btn.copied {
    background: linear-gradient(90deg, #ffe08a, #ff993d);
    color: #182229;
    border-color: transparent;
}

.pattern-rtp {
    margin: 8px 0 12px;
    font-size: 32px;
    font-weight: 900;
    color: #d8f4f7;
}

.pattern-rows {
    margin: 8px 0 12px;
    padding: 10px;
    border: 1px solid rgba(196, 236, 239, 0.16);
    border-radius: 14px;
    background: rgba(121, 214, 223, 0.08);
}

.pattern-row {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    padding: 7px 8px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
}

.pattern-row + .pattern-row {
    margin-top: 6px;
}

.pattern-symbol {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 9px;
    background: rgba(121, 214, 223, 0.16);
    box-shadow: inset 0 0 0 1px rgba(196, 236, 239, 0.26);
    color: #f3f8ff;
    font-size: 18px;
    line-height: 1;
}

.pattern-symbol.ok,
.pattern-symbol.no,
.pg-label,
.pattern-spin,
.pattern-dc {
    background: rgba(121, 214, 223, 0.16);
    box-shadow: inset 0 0 0 1px rgba(196, 236, 239, 0.24);
    color: #f4fbff;
}

.pattern-sep,
.pattern-arrow {
    font-weight: 800;
    color: var(--accent);
    opacity: 0.8;
}

.pg-label,
.pattern-spin,
.pattern-dc {
    padding: 6px 10px;
    font-size: 12px;
    font-weight: 800;
}

.pattern-note {
    color: #e6f8fa;
    font-size: 14px;
    font-weight: 600;
}

.pattern-bet {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(196, 236, 239, 0.16);
    color: #eefbfd;
    font-size: 23px;
    font-weight: 900;
}

.pattern-guide {
    margin-top: 14px;
    padding: 12px;
    border-radius: 14px;
    border: 1px solid rgba(196, 236, 239, 0.12);
    background: rgba(255, 255, 255, 0.04);
}

.pattern-guide-title {
    color: #fff1bc;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.pattern-guide-list {
    margin: 8px 0 0;
    padding-left: 18px;
    color: #e6f8fa;
    font-size: 12px;
    line-height: 1.7;
}

.pattern-guide-list li + li {
    margin-top: 4px;
}

.pattern-foot {
    margin-top: 8px;
    color: rgba(224, 244, 246, 0.78);
    font-size: 11px;
}

.wd-toast-container {
    position: fixed;
    left: 50%;
    bottom: 16px;
    transform: translateX(-50%) translateY(16px);
    opacity: 0;
    pointer-events: none;
    z-index: 1200;
    transition: opacity 0.24s ease, transform 0.24s ease;
}

.wd-toast-container.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.wd-toast {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    max-width: min(92vw, 520px);
    padding: 11px 14px;
    border-radius: 14px;
    background: linear-gradient(180deg, rgba(14, 35, 45, 0.96), rgba(8, 22, 30, 0.96));
    color: var(--text-main);
    font-size: 13px;
    font-weight: 800;
    text-align: center;
}

.wd-toast-bell {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 999px;
    background: rgba(244, 196, 76, 0.18);
    border: 1px solid rgba(244, 196, 76, 0.28);
    font-size: 13px;
}

.wd-toast-text {
    text-align: left;
}

.flash-update {
    animation: flashUpdate 0.8s ease;
}

.reload-glow {
    animation: reloadGlow 1.2s ease;
}

.mobile-top-auth {
    display: none;
}

.feed-status,
.hero-rtp {
    display: none;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes glassSweep {
    0% {
        left: -58%;
        opacity: 0;
    }
    18% {
        opacity: 0.82;
    }
    48% {
        left: 128%;
        opacity: 0;
    }
    100% {
        left: 128%;
        opacity: 0;
    }
}

@keyframes providerHintPulse {
    0%,
    100% {
        transform: translateX(0);
        opacity: 0.95;
    }
    50% {
        transform: translateX(3px);
        opacity: 1;
    }
}

@keyframes flashUpdate {
    0% {
        box-shadow: 0 0 0 rgba(244, 196, 76, 0);
    }
    50% {
        box-shadow: 0 0 0 2px rgba(244, 196, 76, 0.26), var(--shadow);
    }
    100% {
        box-shadow: var(--shadow);
    }
}

@keyframes reloadGlow {
    0% {
        filter: brightness(1);
    }
    50% {
        filter: brightness(1.06);
    }
    100% {
        filter: brightness(1);
    }
}

@media (min-width: 769px) {
    .featured.featured-desktop .featured-card {
        min-width: clamp(220px, 21vw, 280px);
        scroll-snap-align: start;
    }

    .game-grid .grid-card.reveal:nth-child(3n) {
        animation-delay: 0.05s;
    }

    .game-grid .grid-card.reveal:nth-child(3n + 1) {
        animation-delay: 0.1s;
    }

    .game-grid .grid-card.reveal:nth-child(3n + 2) {
        animation-delay: 0.15s;
    }
}

@media (max-width: 768px) {
    html,
    body {
        width: 100%;
        max-width: 100%;
    }

    .layout {
        flex-direction: column;
    }

    .sidebar,
    .wrapper {
        width: calc(100% - 16px);
        margin-left: auto;
        margin-right: auto;
    }

    .sidebar {
        margin-top: 8px;
        padding: 10px;
        border-radius: 18px;
        border: 1px solid var(--line);
        box-shadow: var(--shadow);
    }

    .brand-area {
        justify-content: space-between;
        gap: 8px;
        margin-bottom: 8px;
        padding: 10px 8px;
        border-radius: 16px;
    }

    .brand-area::before {
        display: none;
    }

    .brand-logo {
        width: 134px;
        max-width: 52vw;
    }

    .mobile-top-auth {
        display: flex;
        align-items: center;
        gap: 7px;
        margin-left: auto;
        padding: 2px;
        border-radius: 999px;
        border: 1px solid rgba(196, 236, 239, 0.16);
        background: rgba(255, 255, 255, 0.04);
    }

    .mobile-auth-btn {
        min-width: 68px;
        height: 30px;
        padding: 0 10px;
        border-radius: 999px;
        border: 1px solid transparent;
        font-size: 10px;
        letter-spacing: 0.04em;
        white-space: nowrap;
    }

    .mobile-auth-btn.login {
        color: #182229;
        background: linear-gradient(90deg, #ffe08a, #ff993d);
    }

    .mobile-auth-btn.daftar {
        color: #e8fbfd;
        background: linear-gradient(90deg, rgba(121, 214, 223, 0.28), rgba(121, 214, 223, 0.14));
        border-color: rgba(121, 214, 223, 0.2);
    }

    .sidebar-title,
    .sidebar #providerList {
        display: none !important;
    }

    .wrapper {
        padding: 10px 0 18px;
    }

    .hero-section,
    .header,
    .insight-card,
    .mobile-provider-section,
    .search-box,
    .search-results,
    .featured,
    .game-grid,
    .pattern-modal-box,
    .wd-toast {
        border-radius: 16px;
    }

    .hero-section {
        grid-template-columns: 1fr;
        gap: 12px;
        padding: 18px 14px;
    }

    .hero-left h1 {
        margin-top: 10px;
        font-size: 22px;
    }

    .hero-left p {
        font-size: 12px;
        line-height: 1.65;
    }

    .hero-provider-row,
    .hero-tags {
        gap: 8px;
        margin-top: 12px;
    }

    .hero-summary-strip {
        grid-template-columns: 1fr;
        gap: 8px;
        margin-top: 12px;
    }

    .hero-tag {
        padding: 7px 10px;
        font-size: 9px;
    }

    .hero-right {
        width: 100%;
        min-width: 0;
        gap: 8px;
    }

    .hero-card {
        min-width: 0;
        padding: 14px;
    }

    .hero-auth-card {
        display: none;
    }

    .hero-live-value {
        font-size: 24px;
    }

    .hero-mini-grid {
        grid-template-columns: 1fr;
    }

    .hero-mini-grid span {
        min-height: 0;
        font-size: 10px;
    }

    .header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        margin-top: 8px;
        padding: 14px 12px;
    }

    .insight-strip {
        grid-template-columns: 1fr;
        gap: 8px;
        margin-top: 8px;
    }

    .insight-card {
        padding: 12px;
    }

    .logo {
        font-size: 17px;
    }

    .stats {
        width: 100%;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .stat-box {
        min-width: 0;
        padding: 9px;
        border-radius: 12px;
    }

    .stat-box b {
        font-size: 14px;
    }

    .mobile-provider-section {
        display: block;
        margin-top: 8px;
        padding: 12px;
    }

    .mobile-provider-section .section-title {
        margin-top: 0;
    }

    .section-title-row {
        align-items: flex-start;
    }

    .featured-controls {
        display: none;
    }

    .section-subtitle {
        font-size: 11px;
        margin-bottom: 8px;
    }

    .featured {
        gap: 10px;
        padding: 12px;
    }

    .featured-hint,
    .search-meta {
        font-size: 10px;
    }

    .featured-card {
        min-width: 164px;
        border-radius: 15px;
    }

    .featured-overlay {
        font-size: 10px;
        padding: 8px;
    }

    .featured-meta,
    .featured-body {
        gap: 6px;
    }

    .search-box {
        flex-direction: column;
        align-items: stretch;
    }

    .search-box button {
        width: 100%;
    }

    .search-results {
        grid-template-columns: repeat(2, minmax(136px, 1fr));
        gap: 10px;
        padding: 10px;
    }

    .game-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
        padding: 10px;
    }

    .grid-card:hover {
        transform: none;
        box-shadow: none;
    }

    .grid-card::before {
        opacity: 0.28;
    }

    .grid-info {
        padding: 8px 9px;
        font-size: 10px;
    }

    .rtp {
        font-size: 10px;
    }

    .pattern-modal-box {
        padding: 10px 8px;
    }

    .pattern-title {
        font-size: 16px;
    }

    .pattern-head {
        flex-direction: column;
        gap: 8px;
    }

    .pattern-copy-btn {
        width: 100%;
    }

    .pattern-rtp {
        font-size: 26px;
    }

    .pattern-row {
        gap: 6px;
        padding: 6px;
    }

    .pattern-symbol {
        width: 28px;
        height: 28px;
        font-size: 16px;
    }

    .pg-label,
    .pattern-spin,
    .pattern-dc {
        font-size: 11px;
        padding: 5px 8px;
    }

    .pattern-bet {
        font-size: 20px;
    }

    .pattern-guide {
        padding: 10px;
    }

    .pattern-guide-list {
        font-size: 11px;
    }

    .wd-toast-container {
        bottom: 12px;
    }

    .wd-toast {
        max-width: calc(100vw - 16px);
        padding: 9px 10px;
        font-size: 11px;
        gap: 6px;
    }
}

@media (max-width: 420px) {
    .stats {
        grid-template-columns: 1fr;
    }

    .featured-card {
        min-width: 148px;
    }

    .game-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .grid-info {
        padding: 7px 8px;
        font-size: 9px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
}

/* Unified premium layer */

:root {
    --panel-border-soft: rgba(255, 255, 255, 0.075);
    --panel-border-strong: rgba(216, 177, 112, 0.18);
}

body {
    font-family: "Segoe UI Variable Display", "Aptos", "Trebuchet MS", sans-serif;
    background:
        radial-gradient(circle at 12% 10%, rgba(216, 177, 112, 0.08), transparent 22%),
        radial-gradient(circle at 84% 10%, rgba(255, 255, 255, 0.03), transparent 18%),
        linear-gradient(180deg, #05090c 0%, #0b1318 40%, #111b21 100%);
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.012), transparent 24%, transparent 78%, rgba(216, 177, 112, 0.03)),
        radial-gradient(circle at 12% 10%, rgba(216, 177, 112, 0.08), transparent 20%);
    opacity: 0.9;
}

.sidebar {
    border-right: 1px solid var(--panel-border-soft);
    box-shadow: inset -1px 0 0 rgba(255, 255, 255, 0.02);
}

.brand-area {
    padding: 20px 16px;
    border-radius: 24px;
    background:
        radial-gradient(circle at center, rgba(216, 177, 112, 0.12), transparent 68%),
        linear-gradient(180deg, rgba(19, 26, 31, 0.98), rgba(10, 15, 19, 0.98));
}

.sidebar-title,
.hero-kicker,
.hero-provider-label,
.hero-card-title,
.stat-box span,
.section-subtitle,
.search-meta,
.featured-hint,
.pattern-provider,
.pattern-guide-title {
    letter-spacing: 0.14em;
}

.provider-item {
    margin-bottom: 10px;
    padding: 13px 14px;
    border: 1px solid transparent;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.028), rgba(255, 255, 255, 0.018));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025);
}

.provider-item:hover {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
    border-color: var(--panel-border-strong);
}

.provider-item.active {
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.22);
}

.wrapper {
    max-width: 1360px;
    padding: 22px 30px 34px;
    padding-top: 26px;
}

.hero-section {
    padding: 34px;
    gap: 26px;
    border: 1px solid var(--panel-border-strong);
    background:
        linear-gradient(180deg, rgba(19, 26, 31, 0.98), rgba(10, 15, 19, 1)),
        radial-gradient(circle at top right, rgba(216, 177, 112, 0.08), transparent 36%);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.32);
}

.hero-left h1,
.logo,
.section-title {
    background: linear-gradient(180deg, #f7f3eb 0%, #d8b170 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-left h1 {
    font-family: "Georgia", "Times New Roman", serif;
    max-width: 760px;
    font-size: clamp(34px, 3.9vw, 50px);
    line-height: 1.04;
    letter-spacing: -0.02em;
    text-transform: none;
}

.hero-left p {
    max-width: 660px;
    color: #d9cfbf;
    font-size: 14px;
    line-height: 1.85;
}

.hero-summary-item,
.hero-card,
.header,
.mobile-provider-section,
.search-box,
.search-results,
.featured,
.game-grid,
.pattern-modal-box,
.wd-toast {
    border-color: var(--panel-border-soft);
}

.hero-summary-item {
    padding: 14px 16px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.018)),
        linear-gradient(180deg, rgba(15, 18, 21, 0.98), rgba(11, 14, 17, 0.98));
}

.hero-summary-item strong {
    margin-top: 8px;
    font-size: 15px;
}

.hero-card {
    padding: 20px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.018)),
        linear-gradient(180deg, rgba(15, 18, 21, 0.98), rgba(11, 14, 17, 0.98));
}

.hero-live-value {
    color: #f0dfbc;
}

.hero-live-value,
.pattern-rtp {
    font-family: "Georgia", "Times New Roman", serif;
    text-shadow: none;
}

.header {
    margin-top: 18px;
    padding: 18px 22px;
    background:
        linear-gradient(180deg, rgba(16, 18, 21, 0.94), rgba(10, 12, 15, 0.98)),
        radial-gradient(circle at top left, rgba(216, 177, 112, 0.05), transparent 32%);
}

.logo {
    color: var(--text-main);
    font-family: "Georgia", "Times New Roman", serif;
    font-size: clamp(20px, 1.85vw, 28px);
    letter-spacing: -0.02em;
    white-space: nowrap;
}

.stats {
    gap: 10px;
}

.stat-box {
    min-width: 118px;
    padding: 12px 14px;
    border-radius: 16px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02)),
        linear-gradient(180deg, rgba(15, 18, 21, 0.98), rgba(11, 14, 17, 0.98));
}

.stat-box b {
    margin-top: 6px;
    font-size: 16px;
}

.section-title {
    margin-top: 22px;
    margin-bottom: 8px;
    color: var(--text-main);
    font-family: "Georgia", "Times New Roman", serif;
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.02em;
    text-transform: none;
}

.section-subtitle,
.search-meta,
.featured-hint {
    color: #b2aa9d;
    max-width: 720px;
    font-size: 12px;
    line-height: 1.8;
}

.mobile-provider-section,
.search-box,
.search-results,
.featured,
.game-grid {
    background:
        linear-gradient(180deg, rgba(16, 18, 21, 0.94), rgba(10, 12, 15, 0.98)),
        radial-gradient(circle at top right, rgba(216, 177, 112, 0.035), transparent 30%);
}

.featured,
.search-results,
.game-grid {
    padding: 16px;
}

.featured-card {
    min-width: 252px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 34px rgba(0, 0, 0, 0.28);
}

.featured-card::before {
    background:
        linear-gradient(180deg, rgba(8, 10, 12, 0.08), rgba(8, 10, 12, 0.24) 45%, rgba(8, 10, 12, 0.88)),
        radial-gradient(circle at 18% 18%, rgba(216, 177, 112, 0.14), transparent 30%);
}

.featured-overlay {
    padding: 14px;
}

.featured-badge {
    background: rgba(216, 177, 112, 0.12);
    border-color: rgba(216, 177, 112, 0.26);
    color: #f3e4c4;
}

.featured-name {
    font-size: 15px;
    color: #f7f3eb;
}

.search-box input {
    border-color: rgba(255, 255, 255, 0.08);
    background: rgba(5, 7, 9, 0.86);
    color: #f7f3eb;
}

.search-box button,
.hero-auth-btn.login,
.pattern-copy-btn.copied {
    box-shadow: 0 14px 24px rgba(0, 0, 0, 0.18);
}

.game-grid,
.search-results {
    gap: 16px;
}

.grid-card {
    border-radius: 20px;
    border-color: rgba(255, 255, 255, 0.08);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.015)),
        linear-gradient(180deg, rgba(15, 18, 21, 0.98), rgba(10, 12, 15, 0.98));
    box-shadow: 0 16px 28px rgba(0, 0, 0, 0.18);
}

.grid-card::before {
    background: linear-gradient(140deg, rgba(216, 177, 112, 0.48), rgba(240, 217, 174, 0.22), rgba(255, 255, 255, 0.06));
}

.grid-card::after {
    opacity: 0.22;
}

.grid-inner {
    border-radius: 20px;
    background:
        radial-gradient(circle at 50% 26%, rgba(216, 177, 112, 0.13), transparent 34%),
        linear-gradient(180deg, rgba(15, 18, 21, 0.98), rgba(8, 10, 12, 0.98));
}

.grid-card img,
.search-card img {
    padding: 14px;
    filter: contrast(1.03) saturate(1.04) drop-shadow(0 16px 24px rgba(0, 0, 0, 0.22));
}

.grid-info {
    padding: 12px 14px;
    border-top-color: rgba(255, 255, 255, 0.06);
    color: #d7cfc2;
}

.grid-cta {
    left: 10px;
    right: auto;
    bottom: 70px;
    min-height: 28px;
    padding: 6px 10px;
    gap: 5px;
    border-color: rgba(216, 177, 112, 0.12);
    background: rgba(10, 12, 15, 0.44);
    color: rgba(247, 243, 235, 0.88);
    font-size: 9px;
    letter-spacing: 0.1em;
    backdrop-filter: blur(4px);
    animation: none;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.16);
}

.grid-cta span {
    padding: 3px 6px;
    background: linear-gradient(180deg, #f0d9ae 0%, #d8b170 100%);
}

.pattern-modal {
    background: rgba(5, 7, 9, 0.78);
    backdrop-filter: blur(10px);
}

.pattern-modal-box {
    border-radius: 28px;
    border: 1px solid rgba(216, 177, 112, 0.16);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.36);
}

.pattern-close {
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.08);
}

.pattern-guide,
.pattern-rows {
    background: rgba(255, 255, 255, 0.025);
}

@media (max-width: 768px) {
    .sidebar,
    .wrapper {
        width: calc(100% - 12px);
    }

    .sidebar {
        padding: 8px;
        border-radius: 16px;
    }

    .brand-area {
        padding: 10px;
        border-radius: 16px;
    }

    .brand-logo {
        width: 124px;
    }

    .mobile-auth-btn {
        min-width: 64px;
        height: 28px;
        font-size: 9px;
    }

    .wrapper {
        padding: 8px 0 16px;
    }

    .hero-section {
        padding: 20px 14px;
        gap: 14px;
    }

    .hero-left h1 {
        font-size: 24px;
        line-height: 1.06;
        max-width: 100%;
    }

    .header {
        margin-top: 10px;
    }

    .logo,
    .section-title {
        font-size: 20px;
        line-height: 1.1;
    }

    .hero-left p {
        font-size: 12px;
        line-height: 1.7;
    }

    .hero-kicker,
    .hero-provider-label,
    .hero-card-title,
    .section-subtitle,
    .search-meta,
    .featured-hint {
        font-size: 10px;
    }

    .featured,
    .search-results,
    .game-grid,
    .mobile-provider-section,
    .search-box {
        padding: 12px;
    }

    .featured-card {
        min-width: 172px;
    }

    .featured-overlay {
        padding: 8px;
        font-size: 10px;
    }

    .grid-card,
    .grid-inner {
        border-radius: 18px;
    }

    .search-box input,
    .search-box button {
        min-height: 42px;
    }

    .search-results {
        grid-template-columns: repeat(2, minmax(130px, 1fr));
        gap: 8px;
    }

    .game-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .grid-info {
        padding: 8px 9px;
        font-size: 10px;
    }

    .grid-cta {
        left: 8px;
        bottom: 54px;
        min-height: 24px;
        padding: 4px 8px;
        font-size: 8px;
    }

    .grid-cta span {
        padding: 2px 5px;
    }

    .rtp {
        font-size: 10px;
    }

    .pattern-modal-box {
        padding: 12px 10px;
        border-radius: 18px;
    }
}

@media (max-width: 420px) {
    .hero-left h1 {
        font-size: 20px;
        line-height: 1.08;
    }

    .logo,
    .section-title {
        font-size: 18px;
    }

    .featured-card {
        min-width: 148px;
    }

    .grid-cta {
        bottom: 50px;
    }

    .grid-info {
        padding: 7px 8px;
        font-size: 9px;
    }
}

.ai-advisor-section {
    margin-top: 10px;
}

.ai-advisor-launch {
    margin-top: 14px;
}

.ai-advisor-trigger {
    width: 100%;
    min-height: 62px;
    padding: 16px 20px;
    border: 1px solid rgba(212, 173, 88, 0.22);
    border-radius: 18px;
    background:
        linear-gradient(180deg, rgba(255, 227, 164, 0.08), rgba(255, 227, 164, 0.03)),
        linear-gradient(180deg, rgba(14, 17, 20, 0.98), rgba(10, 13, 16, 0.98));
    color: #fff1cb;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    cursor: pointer;
    transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.ai-advisor-trigger:hover {
    transform: translateY(-1px);
    border-color: rgba(255, 224, 151, 0.36);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.24);
}

.ai-advisor-trigger.is-ready {
    background:
        linear-gradient(180deg, rgba(99, 219, 147, 0.08), rgba(255, 227, 164, 0.04)),
        linear-gradient(180deg, rgba(14, 17, 20, 0.98), rgba(10, 13, 16, 0.98));
}

.ai-advisor-card {
    margin-top: 14px;
    padding: 18px;
    border-radius: 20px;
    border: 1px solid rgba(212, 173, 88, 0.18);
    background:
        linear-gradient(180deg, rgba(255, 227, 164, 0.05), rgba(255, 227, 164, 0.015)),
        linear-gradient(180deg, rgba(14, 17, 20, 0.98), rgba(10, 13, 16, 0.98));
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
}

.ai-advisor-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.ai-advisor-kicker {
    color: rgba(240, 218, 165, 0.74);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.ai-advisor-game {
    margin-top: 8px;
    color: #fff3cf;
    font-size: clamp(22px, 2.2vw, 30px);
    font-weight: 800;
    line-height: 1.1;
}

.ai-advisor-rtp {
    flex: 0 0 auto;
    padding: 10px 14px;
    border-radius: 999px;
    border: 1px solid rgba(212, 173, 88, 0.22);
    background: rgba(255, 223, 146, 0.08);
    color: #ffe09c;
    font-size: 18px;
    font-weight: 800;
}

.ai-advisor-reason {
    margin: 14px 0 0;
    color: rgba(236, 240, 228, 0.9);
    font-size: 14px;
    line-height: 1.7;
}

.ai-advisor-ranking {
    display: grid;
    gap: 10px;
    margin-top: 16px;
}

.ai-ranking-item {
    display: grid;
    grid-template-columns: auto 1fr auto auto;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    width: 100%;
    text-align: left;
    border-radius: 18px;
    border: 1px solid rgba(212, 173, 88, 0.12);
    background: rgba(255, 255, 255, 0.03);
    cursor: pointer;
    transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
    appearance: none;
    -webkit-appearance: none;
}

.ai-ranking-item.is-loading {
    grid-template-columns: 1fr;
    color: rgba(230, 233, 224, 0.78);
    font-size: 13px;
    cursor: default;
}

.ai-ranking-item:hover {
    transform: translateY(-1px);
    border-color: rgba(255, 224, 151, 0.22);
    background: rgba(255, 255, 255, 0.05);
}

.ai-ranking-order {
    width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 1px solid rgba(212, 173, 88, 0.18);
    background: rgba(255, 226, 164, 0.08);
    color: #ffe7b3;
    font-size: 12px;
    font-weight: 800;
}

.ai-ranking-main {
    min-width: 0;
}

.ai-ranking-name {
    display: block;
    color: #fff1cb;
    font-size: 14px;
    font-weight: 800;
    line-height: 1.3;
}

.ai-ranking-note {
    margin-top: 4px;
    color: rgba(226, 232, 220, 0.72);
    font-size: 12px;
    line-height: 1.45;
}

.ai-ranking-rtp {
    color: #ffe3a1;
    font-size: 13px;
    font-weight: 800;
    white-space: nowrap;
}

.ai-ranking-badge {
    padding: 7px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    white-space: nowrap;
}

.ai-ranking-badge.enter {
    background: rgba(99, 219, 147, 0.12);
    border: 1px solid rgba(99, 219, 147, 0.28);
    color: #9df0ba;
}

.ai-ranking-badge.watch {
    background: rgba(255, 224, 151, 0.1);
    border: 1px solid rgba(255, 224, 151, 0.22);
    color: #ffe5a6;
}

.ai-ranking-badge.skip {
    background: rgba(255, 126, 126, 0.1);
    border: 1px solid rgba(255, 126, 126, 0.18);
    color: #ffb1b1;
}

.ai-advisor-pattern {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.ai-pattern-chip {
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid rgba(212, 173, 88, 0.16);
    background: rgba(255, 255, 255, 0.035);
    color: #f1e5c5;
    font-size: 12px;
    font-weight: 700;
}

.ai-advisor-bet {
    margin-top: 14px;
    color: #ffe3a1;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.ai-advisor-guide {
    margin: 12px 0 0;
    padding-left: 18px;
    color: rgba(227, 235, 224, 0.9);
    font-size: 13px;
    line-height: 1.7;
}

.ai-advisor-guide li + li {
    margin-top: 4px;
}

.ai-advisor-actions {
    margin-top: 16px;
}

.ai-advisor-btn {
    min-width: 180px;
    padding: 13px 18px;
    border: 1px solid rgba(212, 173, 88, 0.28);
    border-radius: 999px;
    background: linear-gradient(180deg, rgba(255, 230, 171, 0.18), rgba(255, 230, 171, 0.08));
    color: #fff2c8;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    cursor: pointer;
    transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.ai-advisor-btn:hover {
    transform: translateY(-1px);
    border-color: rgba(255, 224, 151, 0.4);
    background: linear-gradient(180deg, rgba(255, 230, 171, 0.24), rgba(255, 230, 171, 0.11));
}

@media (max-width: 640px) {
    .ai-ranking-item {
        grid-template-columns: auto 1fr;
    }

    .ai-ranking-rtp,
    .ai-ranking-badge {
        justify-self: start;
    }
}

@media (max-width: 768px) {
    .ai-advisor-card {
        padding: 14px;
    }

    .ai-advisor-head {
        flex-direction: column;
        gap: 10px;
    }

    .ai-advisor-game {
        font-size: 22px;
    }

    .ai-advisor-rtp {
        font-size: 16px;
        padding: 8px 12px;
    }

    .ai-advisor-reason,
    .ai-advisor-guide {
        font-size: 12px;
    }

    .ai-advisor-btn {
        width: 100%;
        min-width: 0;
    }
}
