:root {
    --bg-deep: #0A0A0C;
    --bg-card: #141418;
    --bg-panel: #101014;
    --border-subtle: rgba(255, 255, 255, 0.06);
    --border-glow: rgba(255, 255, 255, 0.12);
    --border-active: rgba(255, 255, 255, 0.2);
    --text-primary: #EDEDF0;
    --text-secondary: #9B9BA1;
    --text-muted: #6B6B72;
    --accent-pokemon: #FFCC03;
    --accent-mtg: #F08A4B;
    --accent-yugioh: #B873F8;
    --accent-onepiece: #3DD9C7;
    --accent-mythic: #FF6B35;
    --accent-rare: #FFD700;
    --accent-uncommon: #A0A0A0;
    --accent-common: #8B7355;
    --accent-success: #2ECC71;
    --accent-wishlist: #3498DB;
    --accent-danger: #E74C3C;
    --glass-bg: rgba(20, 20, 24, 0.7);
    --glass-border: rgba(255, 255, 255, 0.08);
    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.5);
    --shadow-panel: 0 16px 48px rgba(0, 0, 0, 0.7);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --font-display: 'Segoe UI', system-ui, -apple-system, sans-serif;
    --font-mono: 'SF Mono', 'Cascadia Code', 'Consolas', monospace;
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-smooth: 300ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-spring: 400ms cubic-bezier(0.34, 1.56, 0.64, 1);
    --animated-gradient: linear-gradient(135deg, var(--grad-stop-1), var(--grad-stop-2));
    animation: syncColorShift 6s infinite linear;
}

@property --grad-stop-1 {
  syntax: '<color>';
  inherits: true;
  initial-value: #4facfe;
}

@property --grad-stop-2 {
  syntax: '<color>';
  inherits: true;
  initial-value: #00f2fe;
}

@keyframes syncColorShift {
  0% {
    --grad-stop-1: #4facfe;
    --grad-stop-2: #00f2fe;
  }
  33% {
    --grad-stop-1: #43e97b;
    --grad-stop-2: #f8ff00;
  }
  66% {
    --grad-stop-1: #fa709a;
    --grad-stop-2: #fee140;
  }
  100% {
    --grad-stop-1: #4facfe;
    --grad-stop-2: #00f2fe;
  }
}

html, body {
    font-family: "Open Sans", Arial, sans-serif;
    width: 100%;
    height: 100%;
    overflow-x: clip;
}

html {

}

body {
    background: #14171b;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #cacaca;
    font-family: var(--font-display);
}

a {
    color: #212529;
    text-decoration: none;
}

a:hover, a:focus {
    /* color: #23527c; */
    /*text-decoration: underline;*/
}

a:focus {
    /*outline: thin dotted;
    outline: 5px auto -webkit-focus-ring-color;
    outline-offset: -2px;*/
}

.header {
    opacity: 0;
    width: 100%;
    position: fixed;
    text-align: center;
    top: -100px;
    height: 80px;
    z-index: 9;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: transparent;
    transition: all var(--transition-smooth);
}

.header-inner {
    width: 100%;
    height: 80px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    background: #212429;
    padding: 20px 100px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    padding: 8px 14px;
    border-radius: 50px;
    transition: all var(--transition-fast);
    position: relative;
}

.nav-link.portfolio {
    display: flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, rgba(255, 204, 3, 0.1), rgba(240, 138, 75, 0.1));
    border: 1px solid rgba(255, 204, 3, 0.2);
    color: var(--accent-pokemon);
}

.nav-link.active {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.08);
}

.nav-link:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}



.header-menu {
    width: 100%;
    max-width: calc(1400px - 240px) !important;
    margin-left: 200px;
    border-radius: 8px;
    position: fixed;
    margin: 20px;
    padding: 10px;
    margin-left: 220px;
    text-align: center;
    height: 50px;
    z-index: 9;
    /*background: var(--animated-gradient);*/
    /*background: #212429;*/
    -webkit-transition: all 0.3s ease-out;
    -moz-transition: all 0.3s ease-out;
    -o-transition: all 0.3s ease-out;
    transition: all 0.3s ease-out;
}

.search-wrapper {
    position: relative;
    flex: 1;
    max-width: 480px;
}

.search-input-container {
    position: relative;
    border-radius: 50px;
}

/* Thin default border */
.search-input-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 50px;
    border: 1px solid var(--glass-border);
    pointer-events: none;
    z-index: 3;
    transition: opacity var(--transition-smooth);
}

/* Gradient border - positioned outside */
.search-input-container::before {
    content: '';
    position: absolute;
    top: -1px;
    left: -1px;
    right: -1px;
    bottom: -1px;
    border-radius: 50px;
    background: var(--animated-gradient); /* Теперь это CSS-градиент, завязанный на анимацию */
    opacity: 0;
    transition: opacity var(--transition-smooth);
    z-index: 0;
    pointer-events: none;
}

/* Hide thin border and show gradient on focus */
.search-input-container:focus-within::after {
    opacity: 0;
}

.search-input-container:focus-within::before {
    opacity: 1;
}

.search-input {
    width: 100%;
    height: 42px;
    background: var(--glass-bg);
    border: none;
    border-radius: 50px;
    padding: 0 44px 0 18px;
    color: var(--text-primary);
    font-size: 14px;
    font-family: var(--font-display);
    outline: none;
    box-sizing: border-box;
    display: block;
    position: relative;
    z-index: 1;
}

.search-input::placeholder {
    color: var(--text-secondary);
}

.search-btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--animated-gradient); /* Тоже подхватывает общую анимацию */
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-smooth);
    color: #1a1a1a;
    z-index: 2;
}

.logo-wrapper svg {

}

.gradient-fill {
    fill: url(#animatedGrad);
}

.header-menu span {
    color: #888;
    font-size: 14px;
    padding: 0px 10px;
    cursor: pointer;
    border-right: 1px solid #888;
}

.header-menu span:last-child {
    border-right: 0px;
}

.header-menu span.active {
    color: #3B82F6;
}

.filter-panel {
    position: fixed;
    top: 80;
    left: -360px;
    width: 360px;
    /* max-width: 100vw; */
    height: calc(100% - 80px);
    background: var(--bg-panel);
    z-index: 2;
    /* transform: translateX(100%); */
    transition: all var(--transition-smooth);
    display: flex;
    flex-direction: column;
    /* box-shadow: var(--shadow-panel); */
    border-right: 1px solid var(--border-subtle);
}

.filter-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-subtle);
    flex-shrink: 0;
}

.filter-section-content {
    padding-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 600px;
    transition: all var(--transition-smooth);
    overflow: hidden;
}

.filter-section.collapsed .filter-section-content {
    max-height: 0;
}

.filter-panel-body {
    flex: 1;
    overflow-y: auto;
    padding: 8px 0;
    scroll-behavior: smooth;
}

.filter-section {
    border-bottom: 1px solid var(--border-subtle);
    padding: 16px 24px;
}

.filter-panel-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-subtle);
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.tcg-selector {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.tcg-option.selected {
    border-color: var(--accent-pokemon);
    color: var(--text-primary);
    background: rgba(255, 204, 3, 0.08);
}

.filter-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    user-select: none;
    margin-bottom: 2px;
}

.set-checkbox {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    border: 1.5px solid var(--border-glow);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
    font-size: 10px;
    color: transparent;
}

.set-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    max-height: 200px;
    overflow-y: auto;
}

.set-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 13px;
    color: var(--text-secondary);
}

.set-count {
    margin-left: auto;
    font-size: 11px;
    color: var(--text-muted);
}

.set-option.selected .set-checkbox {
    background: var(--animated-gradient);
    border-color: var(--animated-gradient);
    color: #1a1a1a;
}

.price-range-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.price-inputs {
    display: flex;
    gap: 10px;
    align-items: center;
}

.price-input {
    flex: 1;
    height: 38px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-glow);
    border-radius: var(--radius-sm);
    padding: 0 12px;
    color: var(--text-primary);
    font-family: var(--font-mono);
    font-size: 13px;
    outline: none;
    transition: all var(--transition-fast);
}

.price-separator {
    color: var(--text-muted);
    font-weight: 600;
}

.price-range-slider {
    width: 100%;
    -webkit-appearance: none;
    height: 4px;
    border-radius: 2px;
    background: var(--border-glow);
    outline: none;
    cursor: pointer;
}

.price-presets {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.price-preset {
    padding: 4px 10px;
    border-radius: 50px;
    border: 1px solid var(--border-glow);
    background: transparent;
    cursor: pointer;
    font-size: 11px;
    color: var(--text-secondary);
    transition: all var(--transition-fast);
    font-family: var(--font-display);
}

.tcg-option {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: var(--radius-md);
    border: 1.5px solid var(--border-glow);
    background: transparent;
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    font-family: var(--font-display);
    flex: 1;
    min-width: 80px;
    justify-content: center;
}

.rarity-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.rarity-chip {
    padding: 8px 14px;
    border-radius: 50px;
    border: 1.5px solid var(--border-glow);
    background: transparent;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    transition: all var(--transition-fast);
    color: var(--text-secondary);
    font-family: var(--font-display);
}

.condition-grid {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.condition-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 13px;
    color: var(--text-secondary);
}

.condition-dot.graded {
    background: var(--accent-success);
    box-shadow: 0 0 6px var(--accent-success);
}
.condition-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.condition-dot.nm {
    background: #3498DB;
}

.condition-dot.lp {
    background: #F39C12;
}

.condition-dot.mp {
    background: #E67E22;
}

.condition-dot.dmg {
    background: var(--accent-danger);
}

.condition-option.selected .condition-check {
    opacity: 1;
    color: var(--accent-pokemon);
}
.condition-check {
    margin-left: auto;
    font-size: 14px;
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.filter-section-toggle {
    font-size: 12px;
    color: var(--text-muted);
    transition: transform var(--transition-fast);
}

.btn-apply {
    background: var(--animated-gradient);
    color: #1a1a1a;
    box-shadow: 0 4px 20px rgba(255, 204, 3, 0.25);
}
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    border: none;
    transition: all var(--transition-smooth);
    font-family: var(--font-display);
    flex: 1;
}

.preloader-wrapper {
    position: absolute;
    /*z-index: 9;*/
    display: flex;
    height: 100%;
    width: 100%;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #1c1e22, #1f2228);
    background-size: 200% 200%;
    animation: gradientShift 6s ease infinite;
}

.bg_grid {
    position: absolute;
    /*background: #1f2228;*/
    background-image: url(/images/grid.svg);
    /*z-index: 9;*/
    width: 100%;
    height: 100%;
    display: flex;
    height: 100%;
    width: 100%;
    justify-content: center;
    align-items: center;
}

.preloader {
    /*z-index: 9;*/
    opacity: 1;
    position: absolute;
    display: block;
    /* background: #14171b; */
    width: 100%;
    /* border-radius: 0px; */
    border: 0;
    max-height: 300px;
    overflow: hidden;
    height: 100%;
    -webkit-transition: ease-out 1s;
    -o-transition: ease-out 1s;
    transition: ease-out 1s;
    background: linear-gradient(314deg, #1e232a, #14335f, #14171b);
    background-size: 400% 400%;
    animation: gradient 6s ease infinite;
    height: 100vh;
}

@keyframes gradientShift {
    0% {
        background-position: 0% 0%;
    }
    50% {
        background-position: 100% 100%;
    }
    100% {
        background-position: 0% 0%;
    }
}

@keyframes gradient {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.animated-logo {
    width: 100%;
    height: 100%;
    text-align: center;
    position: absolute;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    -webkit-transition: ease-out 0.3s;
    -o-transition: ease-out 0.3s;
    transition: ease-out 0.3s;
}

.animated-logo img {
    height: 180px;
    width: 320px;
    position: relative;
    top: 500px;
    left: 0px;
    -webkit-transition: cubic-bezier(0, 1.59, 0.52, 0.82) 0.5s;
    -o-transition: cubic-bezier(0, 1.59, 0.52, 0.82) 0.5s;
    transition: cubic-bezier(0, 1.59, 0.52, 0.82) 0.5s;
}

.animated-logo:nth-child(4) img {
    opacity: 0;
    top: 0;
    -webkit-transition: cubic-bezier(0.4, 0, 1, 1) 2s;
    -o-transition: cubic-bezier(0.4, 0, 1, 1) 2s;
    transition: cubic-bezier(0.4, 0, 1, 1) 2s;
}

.overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 200;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-smooth);
    backdrop-filter: blur(2px);
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background-color: black;
    opacity: 0.8;
    z-index: 1;
}

.carousel-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    z-index: 0;
    -ms-transform: translateX(-50%) translateY(-50%);
    -moz-transform: translateX(-50%) translateY(-50%);
    -webkit-transform: translateX(-50%) translateY(-50%);
    transform: translateX(-50%) translateY(-50%);
}

.anim-wrapper {
    position: relative;
    width: 100%;
    display: block;
    opacity: 0;
    height: 100%;
    -ms-transform: scale(2);
    -moz-transform: scale(2);
    -webkit-transform: scale(2);
    -webkit-transition: cubic-bezier(0, 0.4, 0.01, 0.99) 2s;
    -o-transition: cubic-bezier(0, 0.4, 0.01, 0.99) 2s;
    transition: cubic-bezier(0, 0.4, 0.01, 0.99) 2s;
}

.gototop.active {
    opacity: 1;
    visibility: visible;
}

.gototop {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    -webkit-transition: 0.3s;
    -o-transition: 0.3s;
    transition: 0.3s;
}

.gototop a {
    width: 50px;
    height: 50px;
    display: table;
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    text-align: center;
    -webkit-border-radius: 4px;
    -moz-border-radius: 4px;
    -ms-border-radius: 4px;
    border-radius: 4px;
}

.js-gotop img {
    width: 50px;
    padding: 15px;
}

/*== SCROLL ==*/

*::-webkit-scrollbar {
    width: 4px;
}

*::-webkit-scrollbar-thumb {
    background: var(--border-glow);
    border-radius: 2px;
}

/*::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #bbb;
}

::-webkit-resizer {
    width: 6px;
}

::-webkit-scrollbar {
    width: 6px;
}

::-webkit-resizer {
    height: 6px;
}

::-webkit-scrollbar {
    height: 6px;
}

::-webkit-scrollbar-corner {
    background: rgba(0,0,0,0);
}*/

/* ======= */
.burger-menu {
    display: none;
}

.opener {
    pointer-events: none;
    font-size: 14px;
    width: 10%;
    height: 40px;
    right: 0px;
    position: absolute;
    display: block;
    /* float: right; */
    -webkit-transition: 0.3s;
    -o-transition: 0.3s;
    transition: 0.3s;
    -webkit-font-smoothing: antialiased;
}

.opener:before {
    content: "";
    display: block;
    position: absolute;
    top: 50%;
    right: 13px;
    width: 7px;
    height: 1px;
    background-color: #888;
    -ms-transform-origin: 50% 50%;
    transform-origin: 50% 50%;
    transition: all .25s;
}

.opener:after {
    content: "";
    display: block;
    position: absolute;
    top: 50%;
    right: 13px;
    width: 7px;
    height: 1px;
    background-color: #888;
    -ms-transform-origin: 50% 50%;
    transform-origin: 50% 50%;
    transition: all .25s;
    -webkit-font-smoothing: antialiased;
    -webkit-transform: rotate(90deg);
    transform: rotate(90deg);
}

.opener-opened:after {
    -webkit-font-smoothing: antialiased;
    -webkit-transform: rotate(0deg);
    transform: rotate(0deg);
}

.opener-closed:after {
    -webkit-font-smoothing: antialiased;
    -webkit-transform: rotate(90deg);
    transform: rotate(90deg);
}

@media screen and (max-width: 1100px) {
}

@media screen and (max-width: 630px) {
}