:root {
    --bg-color:#0c0c0c;
    --text-color:#ffffff;
    --card-bg:rgba(255,
    255,
    255,
    0.05);
    --accent-color:#e63946;
    --glass-bg:rgba(20,
    20,
    20,
    0.7);
    --glass-border:rgba(255,
    255,
    255,
    0.1);
    --slot-bg:#1e293b;
    --slot-hover-bg:#334155;
    --watermark-circle:rgba(15,
    23,
    42,
    0.8);
    --circle-bg:rgba(15,
    23,
    42,
    0.8);
    --circle-border:rgba(255,
    255,
    255,
    0.2);
    --sticky-bg:#0f172a;
}

[data-theme="light"] {
    --bg-color:#f1f5f9;
    --text-color:#1e293b;
    --card-bg:rgba(0,
    0,
    0,
    0.03);
    --accent-color:#dc2626;
    --glass-bg:rgba(255,
    255,
    255,
    0.8);
    --glass-border:rgba(0,
    0,
    0,
    0.1);
    --slot-bg:#ffffff;
    --slot-hover-bg:#f8fafc;
    --watermark-circle:rgba(226,
    232,
    240,
    0.8);
    --circle-bg:rgba(241,
    245,
    249,
    0.9);
    --circle-border:rgba(0,
    0,
    0,
    0.1);
    --sticky-bg:#e2e8f0;
}

[data-theme="newspaper"] {
    --bg-color:#f4ecd8;
    --text-color:#2c241e;
    --card-bg:rgba(92, 64, 51, 0.05);
    --accent-color:#5c4033;
    --glass-bg:rgba(244, 236, 216, 0.9);
    --glass-border:rgba(92, 64, 51, 0.2);
    --slot-bg:#eae0c8;
    --slot-hover-bg:#dfd5bd;
    --watermark-circle:rgba(92, 64, 51, 0.15);
    --circle-bg:rgba(234, 224, 200, 0.95);
    --circle-border:rgba(92, 64, 51, 0.2);
    --sticky-bg:#eae0c8;
}

[data-theme="newspaper"] h1,
[data-theme="newspaper"] h2,
[data-theme="newspaper"] h3,
[data-theme="newspaper"] h4 {
    color:#2c241e !important;
    background:none !important;
    -webkit-background-clip:initial !important;
    -webkit-text-fill-color:initial !important;
    border-color:rgba(92, 64, 51, 0.2) !important;
}

[data-theme="newspaper"] svg {
    stroke:#2c241e !important;
}

[data-theme="newspaper"] svg #trophy-gradient stop {
    stop-color:#2c241e !important;
}

* {
    margin:0;
    padding:0;
    box-sizing:border-box;
    font-family:'Outfit',
    'Inter',
    system-ui,
    -apple-system,
    sans-serif;
}

.theme-transitioning,
.theme-transitioning *,
.theme-transitioning *:before,
.theme-transitioning *:after {
    transition:none !important;
    animation-duration:0s !important;
}

body {
    background-color:var(--bg-color);
    color:var(--text-color);
    transition:background-color 0.3s,
    color 0.3s;
    min-height:100vh;
}

.glass {
    background:var(--glass-bg);
    backdrop-filter:blur(12px);
    -webkit-backdrop-filter:blur(12px);
    border:1px solid var(--glass-border);
}

.main-header {
    display:flex;
    justify-content:space-between;
    align-items:center;
    padding:10px 2rem;
    position:relative;
    z-index:9999;
}

.header-left {
    display:flex;
    align-items:center;
    gap:1rem;
}

.logo {
    height:var(--logo-height, 50px);
    width:auto;
    max-width:250px;
    object-fit:contain;
}

.title-container {
    display:flex;
    flex-direction:column;
}

h1 {
    font-size:1.5rem;
    font-weight:700;
    line-height:1.1;
    margin:0;
}

#site-tagline {
    font-size:0.7rem;
    color:var(--text-color);
    opacity:0.7;
    letter-spacing:0.5px;
    font-weight:500;
    margin-top:2px;
}

#site-title {
    color:#3b82f6;
    text-shadow:0 0 10px rgba(0,
    240,
    255,
    0.7),
    0 0 20px rgba(0,
    240,
    255,
    0.4);
    transition:color 0.3s ease,
    text-shadow 0.3s ease;
}

[data-theme="light"] #site-title {
    color:#000000;
    text-shadow:none;
}

.header-right {
    display:flex;
    gap:0.5rem;
    align-items:center;
    position:absolute;
    top:50%;
    transform:translateY(-50%);
    right:2rem;
    z-index:9999;
}

.btn-icon {
    background:transparent;
    border:none;
    color:var(--text-color);
    padding:0.8rem;
    border-radius:12px;
    cursor:pointer;
    font-size:1.2rem;
    transition:background 0.2s,
    transform 0.1s;
}

.btn-icon:hover {
    background:var(--card-bg);
    transform:translateY(-2px);
}

.btn-icon:active {
    transform:scale(0.95);
}

.dropdown {
    position:relative;
    display:inline-block;
}

.dropdown-content {
    display:none;
    position:absolute;
    right:0;
    top:100%;
    min-width:180px;
    border-radius:12px;
    margin-top:0.5rem;
    overflow:hidden;
    z-index:101;
}

.dropdown:hover .dropdown-content,
.dropdown-content.show {
    display:block;
}

.dropdown-content a {
    color:var(--text-color);
    padding:12px 16px;
    text-decoration:none;
    display:block;
    font-size:0.9rem;
    transition:background 0.2s;
}

.dropdown-content a:hover {
    background:var(--card-bg);
}

.type-container {
    display:flex;
    flex-wrap:wrap;
    gap:1rem;
    justify-content:center;
    margin-bottom:2rem;
}

.type-box {
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:0.5rem;
    padding:0.8rem;
    border-radius:12px;
    cursor:pointer;
    transition:transform 0.2s,
    background 0.2s;
    width:80px;
    opacity:0.6;
}

.type-box.active {
    opacity:1;
    background:var(--card-bg);
    border:1px solid var(--accent-color);
}

.type-icon {
    width:32px;
    height:32px;
}

.type-name {
    font-size:0.75rem;
    font-weight:600;
    text-transform:capitalize;
}

.picker-container {
    display:grid;
    grid-template-columns:200px 1fr;
    gap:2rem;
}

.sidebar-filters {
    padding:1.5rem;
    border-radius:20px;
    height:fit-content;
    position:sticky;
    top:100px;
}

.gen-buttons {
    display:flex;
    flex-direction:column;
    gap:0.8rem;
}

.btn-gen {
    background:transparent;
    border:1px solid var(--glass-border);
    color:var(--text-color);
    padding:0.8rem;
    border-radius:10px;
    cursor:pointer;
    font-weight:500;
    transition:background 0.2s,
    border-color 0.2s,
    color 0.2s;
    text-align:left;
}

.btn-gen:hover,
.btn-gen.active {
    background:var(--accent-color);
    border-color:var(--accent-color);
    color:white;
}

.pokemon-section {
    display:flex;
    flex-direction:column;
    gap:1.5rem;
}

.grid-controls input {
    width:100%;
    padding:1rem;
    border-radius:12px;
    border:1px solid var(--glass-border);
    color:var(--text-color);
    outline:none;
}

.pokemon-grid {
    display:grid;
    grid-template-columns:repeat(auto-fill,
    minmax(150px,
    1fr));
    gap:1rem;
}

.pokemon-card {
    background:var(--card-bg);
    border-radius:15px;
    padding:1rem;
    text-align:center;
    cursor:pointer;
    transition:transform 0.2s,
    border 0.2s;
    border:1px solid transparent;
    position:relative;
}

.pokemon-card:hover {
    transform:translateY(-5px);
    background:rgba(255,
    255,
    255,
    0.08);
}

.pokemon-card.selected {
    border-color:var(--accent-color);
}

.pokemon-card img {
    width:100px;
    height:100px;
    object-fit:contain;
    margin-bottom:0.5rem;
}

.spreadsheet-container {
    padding:0;
    overflow-x:auto;
    margin-top:20px;
}

.grid-scroll-wrapper {
    width:max-content;
}

.pokemon-spreadsheet {
    width:auto;
    border-collapse:separate;
    border-spacing:8px;
    table-layout:fixed;
    display:table !important;
}

.pokemon-spreadsheet tr {
    display:table-row !important;
}

.pokemon-spreadsheet th,
.pokemon-spreadsheet td {
    min-width:var(--slot-size, 100px) !important;
    width:var(--slot-size, 100px) !important;
    height:var(--slot-size, 100px) !important;
    text-align:center;
    vertical-align:middle;
    display:table-cell !important;
    will-change:transform;
    backface-visibility:hidden;
    -webkit-font-smoothing:antialiased;
}

.pokemon-spreadsheet th:first-child,
.pokemon-spreadsheet td:first-child {
    position:relative;
    z-index:100;
    background:transparent !important;
    width:var(--slot-size, 100px) !important;
    min-width:var(--slot-size, 100px) !important;
}

.pokemon-spreadsheet th:first-child {
    height:var(--slot-size, 100px) !important;
    vertical-align:middle;
}

.pokemon-spreadsheet th {
    height:auto;
    padding:0;
}

.type-header {
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:10px;
}

.type-header span {
    font-size:calc(var(--slot-size, 100px) * 0.12);
    text-transform:uppercase;
    font-weight:700;
    opacity:0.8;
}

.gen-badge {
    width:var(--slot-size, 100px) !important;
    height:var(--slot-size, 100px) !important;
    min-width:var(--slot-size, 100px) !important;
    border-radius:12px;
    display:flex !important;
    flex-direction:column;
    justify-content:center;
    align-items:center;
    font-weight:700;
    color:#ffffff !important;
    position:relative;
    z-index:101;
    background:#1e293b;
    border:1px solid rgba(255,
    255,
    255,
    0.1);
    background-clip:padding-box;
    margin:0 auto;
    text-shadow:0 1px 2px rgba(0,
    0,
    0,
    0.3);
    box-shadow:none;
    overflow:hidden;
}

.gen-badge div {
    color:#fff !important;
}

.gen-label {
    font-size:calc(var(--slot-size, 100px) * 0.096);
    opacity:0.8;
    font-weight:400;
}

.gen-num {
    font-size:calc(var(--slot-size, 100px) * 0.22);
    line-height:1;
    margin:1px 0;
    font-weight:900;
}

.gen-region {
    font-size:calc(var(--slot-size, 100px) * 0.088);
    letter-spacing:1px;
    opacity:0.9;
}

.gen-1 {
    background:linear-gradient(135deg,
    #00C9FF,
    #92FE9D,
    #00C9FF) !important;
}

.gen-2 {
    background:linear-gradient(135deg,
    #f12711,
    #f5af19,
    #f12711) !important;
}

.gen-3 {
    background:linear-gradient(135deg,
    #4facfe,
    #00f2fe,
    #4facfe) !important;
}

.gen-4 {
    background:linear-gradient(135deg,
    #b224ef,
    #7579ff,
    #b224ef) !important;
}

.gen-5 {
    background:linear-gradient(135deg,
    #ff0844,
    #ffb199,
    #ff0844) !important;
}

.gen-6 {
    background:linear-gradient(135deg,
    #11998e,
    #38ef7d,
    #11998e) !important;
}

.gen-7 {
    background:linear-gradient(135deg,
    #FF8008,
    #FFC837,
    #FF8008) !important;
}

.gen-8 {
    background:linear-gradient(135deg,
    #FC466B,
    #3F5EFB,
    #FC466B) !important;
}

.gen-9 {
    background:linear-gradient(135deg,
    #00b09b,
    #96c93d,
    #00b09b) !important;
}

.gen-forms {
    background:linear-gradient(135deg,
    #bdc3c7,
    #2c3e50,
    #bdc3c7) !important;
}

.type-header {
    background:var(--slot-bg);
    padding:10px;
    border-radius:12px;
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:4px;
    width:var(--slot-size, 100px) !important;
    height:var(--slot-size, 100px) !important;
    min-width:var(--slot-size, 100px) !important;
    justify-content:center;
    border:1px solid var(--glass-border);
    background-clip:padding-box;
    margin:0 auto;
    box-shadow:none;
}

.type-icon-circle {
    width:calc(var(--slot-size, 100px) * 0.62);
    height:calc(var(--slot-size, 100px) * 0.62);
    background:var(--circle-bg) !important;
    border-radius:50%;
    display:flex;
    justify-content:center;
    align-items:center;
    border:3px solid var(--circle-border);
}

.type-header img {
    width:calc(var(--slot-size, 100px) * 0.45);
    height:calc(var(--slot-size, 100px) * 0.45);
    object-fit:contain;
    filter:brightness(1.2);
}

.type-color-normal {
    background:linear-gradient(135deg,
    #A8A878,
    #8A8A59) !important;
}

.type-color-fire {
    background:linear-gradient(135deg,
    #F08030,
    #C06010) !important;
}

.type-color-water {
    background:linear-gradient(135deg,
    #6890F0,
    #445E9C) !important;
}

.type-color-grass {
    background:linear-gradient(135deg,
    #78C850,
    #5E9C3E) !important;
}

.type-color-electric {
    background:linear-gradient(135deg,
    #F8D030,
    #C1A110) !important;
}

.type-color-ice {
    background:linear-gradient(135deg,
    #98D8D8,
    #69A1A1) !important;
}

.type-color-fighting {
    background:linear-gradient(135deg,
    #C03028,
    #96251E) !important;
}

.type-color-poison {
    background:linear-gradient(135deg,
    #A040A0,
    #7E327E) !important;
}

.type-color-ground {
    background:linear-gradient(135deg,
    #E0C068,
    #B19751) !important;
}

.type-color-flying {
    background:linear-gradient(135deg,
    #A890F0,
    #8A76C4) !important;
}

.type-color-psychic {
    background:linear-gradient(135deg,
    #F85888,
    #C3456B) !important;
}

.type-color-bug {
    background:linear-gradient(135deg,
    #A8B820,
    #849119) !important;
}

.type-color-rock {
    background:linear-gradient(135deg,
    #B8A038,
    #917D2C) !important;
}

.type-color-ghost {
    background:linear-gradient(135deg,
    #705898,
    #584577) !important;
}

.type-color-dragon {
    background:linear-gradient(135deg,
    #7038F8,
    #4D27AC) !important;
}

.type-color-dark {
    background:linear-gradient(135deg,
    #705848,
    #584539) !important;
}

.type-color-steel {
    background:linear-gradient(135deg,
    #B8B8D0,
    #9191A4) !important;
}

.type-color-fairy {
    background:linear-gradient(135deg,
    #EE99AC,
    #CC8091) !important;
}

.type-color-starter {
    background:linear-gradient(135deg,
    #4FC3F7,
    #0288D1) !important;
}

.type-color-legendary {
    background:linear-gradient(135deg,
    #FFD54F,
    #FFA000) !important;
}

.type-color-ultra {
    background:linear-gradient(135deg,
    #B39DDB,
    #673AB7) !important;
}

@keyframes rainbowFluid {
    0% {
        background-position:0% 50%;
    }

    50% {
        background-position:100% 50%;
    }

    100% {
        background-position:0% 50%;
    }
}

.header-logo-cell {
    padding:0 !important;
}

.logo-wrapper {
    width:var(--slot-size, 100px) !important;
    height:var(--slot-size, 100px) !important;
    min-width:var(--slot-size, 100px) !important;
    background:linear-gradient(270deg,
    #ff3b3b,
    #ff9d00,
    #ffe100,
    #38c92a,
    #00e1ff,
    #3023ff,
    #b100ff);
    background-size:400% 400%;
    animation:rainbowFluid 8s ease infinite;
    border-radius:12px;
    display:flex;
    justify-content:center;
    align-items:center;
    border:1px solid rgba(255,
    255,
    255,
    0.1);
    background-clip:padding-box;
    box-shadow:none;
}

.logo-wrapper img {
    width:calc(var(--slot-size, 100px) * 0.80);
    height:calc(var(--slot-size, 100px) * 0.80);
    object-fit:contain;
}

.pokemon-spreadsheet thead th {
    border-bottom:0;
    padding-bottom:0;
}

.pokemon-spreadsheet td,
.pokemon-spreadsheet th {
    width:var(--slot-size, 100px) !important;
    height:var(--slot-size, 100px) !important;
    min-width:var(--slot-size, 100px) !important;
    max-width:var(--slot-size, 100px) !important;
    padding:0 !important;
    box-sizing:border-box !important;
}

.pokemon-slot {
    width:var(--slot-size, 100px) !important;
    height:var(--slot-size, 100px) !important;
    background:var(--slot-bg);
    border:1px dashed var(--glass-border);
    border-radius:12px;
    cursor:pointer;
    transition:background 0.2s ease,
    border-color 0.2s ease,
    box-shadow 0.2s ease;
    position:relative;
    overflow:hidden;
    display:flex;
    justify-content:center;
    align-items:center;
}

.pokemon-slot:hover {
    background:var(--slot-hover-bg);
    border:1px solid #3b82f6;
    box-shadow:0 0 15px rgba(0,
    240,
    255,
    0.5),
    inset 0 0 5px rgba(0,
    240,
    255,
    0.2);
    z-index:10;
}

.watermark-bg {
    position:absolute;
    top:50%;
    left:50%;
    transform:translate(-50%,
    -50%);
    width:calc(var(--slot-size, 100px) * 0.68);
    height:calc(var(--slot-size, 100px) * 0.68);
    background:var(--circle-bg);
    border-radius:50%;
    display:flex;
    justify-content:center;
    align-items:center;
    z-index:1;
    border:3px solid var(--circle-border);
}

.watermark-icon {
    position:absolute;
    width:calc(var(--slot-size, 100px) * 0.55);
    height:calc(var(--slot-size, 100px) * 0.55);
    object-fit:contain;
    opacity:0.25;
    z-index:2;
    filter:brightness(1.2);
}

.plus-icon {
    font-size:1.1rem;
    color:white;
    opacity:0.5;
    position:relative;
    z-index:3;
    pointer-events:none;
}

.pokemon-slot.filled .watermark-bg {
    opacity:0.2;
}

.p-img {
    width:95%;
    height:95%;
    object-fit:contain;
    position:relative;
    z-index:5;
    animation:rainbowShadow 8s linear infinite alternate;
    will-change:filter;
}

body {
    background-color:var(--bg-color);
    color:var(--text-color);
    transition:background-color 0.3s,
    color 0.3s;
    min-height:100vh;
}

.modal-overlay {
    position:fixed;
    top:0;
    left:0;
    width:100%;
    height:100%;
    background:rgba(0,
    0,
    0,
    0.85);
    display:flex;
    justify-content:center;
    align-items:center;
    z-index:1000;
}

.modal-content {
    width:90%;
    max-width:900px;
    height:80vh;
    border-radius:25px;
    display:flex;
    flex-direction:column;
    padding:2rem;
}

.modal-header {
    display:flex;
    justify-content:space-between;
    align-items:center;
    margin-bottom:1.5rem;
    padding-bottom:1rem;
    border-bottom:1px solid var(--glass-border);
}

.modal-header h2 {
    font-size:1.5rem;
    color:#4facfe;
    margin:0;
}

.modal-search input {
    width:100%;
    padding:1rem;
    border-radius:12px;
    border:1px solid var(--glass-border);
    color:var(--text-color);
    margin-bottom:2rem;
}

.modal-grid {
    display:grid;
    grid-template-columns:repeat(auto-fill,
    minmax(100px,
    1fr));
    gap:1rem;
    overflow-y:auto;
    overflow-x:hidden;
    align-content:start;
    flex:1;
    padding-right:10px;
}

::-webkit-scrollbar {
    width:8px;
    height:8px;
}

::-webkit-scrollbar-track {
    background:rgba(0,
    0,
    0,
    0.2);
    border-radius:4px;
}

::-webkit-scrollbar-thumb {
    background:#3b82f6;
    border-radius:4px;
    box-shadow:0 0 10px rgba(0,
    240,
    255,
    0.5);
}

::-webkit-scrollbar-thumb:hover {
    background:#00c3ff;
}

.modal-p-card {
    background:var(--card-bg);
    border-radius:12px;
    padding:8px !important;
    width:100px !important;
    height:100px !important;
    min-width:100px !important;
    text-align:center;
    cursor:pointer;
    transition:transform 0.2s;
}

.modal-p-card:hover {
    transform:scale(1.05);
}

.modal-p-card img {
    width:55px !important;
    height:55px !important;
    object-fit:contain;
}

.modal-p-card .name {
    font-size:0.65rem !important;
    font-weight:600;
    margin-top:2px !important;
}

.content-wrapper {
    max-width:100%;
    margin:0;
    padding:0;
}

.p-name {
    font-weight:600;
    font-size:0.9rem;
}

.p-id {
    font-size:0.7rem;
    opacity:0.5;
    position:absolute;
    top:10px;
    left:10px;
}

.popup-overlay {
    position:fixed;
    top:0;
    left:0;
    width:100%;
    height:100%;
    background:rgba(0,
    0,
    0,
    0.8);
    display:flex;
    justify-content:center;
    align-items:center;
    z-index:1000;
}

.popup-content {
    padding:2rem;
    border-radius:20px;
    max-width:400px;
    width:90%;
    text-align:center;
}

.hidden {
    display:none !important;
}

.popup-actions {
    display:flex;
    gap:1rem;
    justify-content:center;
    margin-top:2rem;
}

.btn-secondary,
.btn-danger {
    padding:0.8rem 1.5rem;
    border-radius:10px;
    border:none;
    cursor:pointer;
    font-weight:600;
    transition:filter 0.2s;
}

.btn-secondary {
    background:#4a4a4a;
    color:white;
}

.btn-danger {
    background:var(--accent-color);
    color:white;
}

.btn-secondary:hover,
.btn-danger:hover {
    filter:brightness(1.2);
}

.main-footer {
    margin-top:4rem;
    color:var(--text-color);
    background:var(--glass-bg);
    border-top:1px solid var(--glass-border);
    backdrop-filter:blur(12px);
    width:100%;
}

.footer-container-simple {
    max-width:1000px;
    margin:0 auto;
    padding:2rem 2rem 1.5rem;
    text-align:center;
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:1.5rem;
}

.footer-links-inline {
    display:flex;
    flex-wrap:wrap;
    justify-content:center;
    gap:2rem;
}

.footer-links-inline a {
    color:var(--text-color);
    text-decoration:none;
    font-size:0.95rem;
    opacity:0.8;
    transition:opacity 0.2s,
    color 0.2s;
    font-weight:500;
}

.footer-links-inline a:hover {
    opacity:1;
    color:#3b82f6;
}

.footer-links-inline a i {
    margin-right:5px;
}

.disclaimer-inline {
    font-size:0.75rem !important;
    opacity:0.5 !important;
    line-height:1.6 !important;
    max-width:800px;
}

.footer-bottom {
    text-align:center;
    padding:1rem;
    border-top:1px solid var(--glass-border);
    font-size:0.85rem;
    opacity:0.7;
    background:rgba(0,
    0,
    0,
    0.1);
}

.bottom-features-container {
    max-width:1440px;
    margin:2rem auto;
    padding:0 2rem;
    display:flex;
    flex-wrap:wrap;
    gap:3rem;
    align-items:flex-start;
}

.feature-title {
    color:#4a80ff;
    font-size:1rem;
    font-weight:800;
    text-transform:uppercase;
    margin-bottom:1rem;
    letter-spacing:1px;
}

.feature-slots {
    display:flex;
    gap:12px;
    flex-wrap:wrap;
}

.feature-slot-card {
    width:100px !important;
    height:100px !important;
    min-width:100px !important;
    aspect-ratio:1/1;
    flex:0 0 auto;
    align-self:flex-start;
    position:relative;
    border-radius:12px;
    background:#1e293b;
    border:2px dashed rgba(255,
    255,
    255,
    0.15);
    display:flex;
    flex-direction:column;
    justify-content:center;
    align-items:center;
    cursor:pointer;
    transition:background 0.2s,
    border-color 0.2s,
    transform 0.2s;
    overflow:hidden;
}

[data-theme="light"] .feature-slot-card {
    background:#e2e8f0;
    border-color:rgba(0,
    0,
    0,
    0.15);
}

.feature-slot-card:hover {
    border-color:#4a80ff;
    background:rgba(74,
    128,
    255,
    0.05);
    transform:translateY(-2px);
}

.feature-slot-card.filled {
    border-style:solid;
    border-color:rgba(255,
    255,
    255,
    0.3);
}

[data-theme="light"] .feature-slot-card.filled {
    border-color:rgba(0,
    0,
    0,
    0.3);
}

.feature-slot-card.special-glow {
    border-color:rgba(74,
    128,
    255,
    0.5);
    box-shadow:0 0 15px rgba(74,
    128,
    255,
    0.2);
}

.slot-label-top {
    position:absolute;
    top:6px;
    width:100%;
    text-align:center;
    font-size:0.5rem;
    font-weight:800;
    color:var(--text-color);
    opacity:0.7;
    text-transform:uppercase;
    line-height:1.3;
    padding:0 4px;
    box-sizing:border-box;
}

.slot-label-bottom {
    position:absolute;
    bottom:8px;
    width:100%;
    text-align:center;
    font-size:0.6rem;
    font-weight:700;
    color:var(--text-color);
    opacity:0.6;
}

.slot-plus {
    font-size:1.5rem;
    color:var(--text-color);
    opacity:0.2;
    font-weight:300;
}

.feature-slot-card:hover .slot-plus {
    opacity:0.5;
    color:#4a80ff;
}

.feature-p-img {
    width:55px;
    height:55px;
    object-fit:contain;
    z-index:2;
    animation:rainbowShadow 8s linear infinite alternate;
    will-change:filter;
    transition:transform 0.2s;
}

.feature-slot-card:hover .feature-p-img {
    transform:scale(1.1);
}

.pokemon-hover-name {
    position:absolute;
    bottom:0;
    left:0;
    width:100%;
    background:rgba(0,
    0,
    0,
    0.8);
    backdrop-filter:blur(4px);
    -webkit-backdrop-filter:blur(4px);
    color:#fff;
    text-align:center;
    padding:calc(var(--slot-size, 100px) * 0.06) 0;
    font-size:calc(var(--slot-size, 100px) * 0.115);
    font-weight:700;
    text-transform:capitalize;
    transform:translateY(100%);
    transition:transform 0.2s cubic-bezier(0.4,
    0,
    0.2,
    1);
    z-index:10;
    border-bottom-left-radius:inherit;
    border-bottom-right-radius:inherit;
}

[data-theme="light"] .pokemon-hover-name {
    background:rgba(255,
    255,
    255,
    0.9);
    color:#000;
}

.pokemon-slot:hover .pokemon-hover-name,
.feature-slot-card:hover .pokemon-hover-name {
    transform:translateY(0);
}

@media (max-width:768px) {
    .main-header {
        justify-content: flex-start !important;
        padding: 10px 1rem !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        background: var(--bg-color) !important;
    }

    .header-left {
        width: auto !important;
        justify-content: flex-start !important;
    }

    h1 {
        font-size:1.25rem;
    }

    .header-right {
        position:fixed !important;
        top:auto !important;
        transform:none !important;
        bottom:0 !important;
        left:0 !important;
        right:0 !important;
        width:100% !important;
        display:flex !important;
        justify-content:space-evenly !important;
        align-items:center !important;
        background:rgba(15,
        23,
        42,
        0.95) !important;
        backdrop-filter:blur(15px) !important;
        -webkit-backdrop-filter:blur(15px) !important;
        border-top:1px solid var(--glass-border) !important;
        padding:0 !important;
        padding-bottom:env(safe-area-inset-bottom) !important;
        height:calc(65px + env(safe-area-inset-bottom)) !important;
        z-index:999999 !important;
        gap:0 !important;
        box-shadow:0 -4px 30px rgba(0,
        0,
        0,
        0.5) !important;
    }

    [data-theme="light"] .header-right .btn-icon {
        color:#ffffff !important;
    }

    .header-right .btn-icon,
    .header-right .dropdown,
    .header-right .mob-grid-size-wrapper {
        flex:1 !important;
        height:65px !important;
        display:flex !important;
        justify-content:center !important;
        align-items:center !important;
        padding:0 !important;
        margin:0 !important;
        position:relative !important;
    }

    .header-right .btn-icon {
        width:100% !important;
        border-radius:0 !important;
        font-size:1.4rem !important;
    }

    body {
        padding-bottom:100px !important;
    }

    .dropdown-content {
        top:auto;
        bottom:100%;
        margin-top:0;
        margin-bottom:1.2rem;
        right:auto;
        left:50%;
        transform:translateX(-50%);
        max-height:50vh;
        overflow-y:auto;
        box-shadow:0 -8px 30px rgba(0,
        0,
        0,
        0.6);
    }

    .spreadsheet-container {
        margin-top:10px !important;
        padding-top:0px !important;
    }

    .main-header {
        padding:10px 1rem !important;
    }

    .pokemon-spreadsheet th,
    .pokemon-spreadsheet td {
        min-width: var(--slot-size, 60px) !important;
        width: var(--slot-size, 60px) !important;
        height: var(--slot-size, 60px) !important;
    }

    .gen-badge,
    .logo-wrapper {
        width: var(--slot-size, 60px) !important;
        height: var(--slot-size, 60px) !important;
        min-width: var(--slot-size, 60px) !important;
    }

    .gen-num {
        font-size: calc(var(--slot-size, 60px) * 0.22) !important;
    }

    .gen-region {
        font-size: calc(var(--slot-size, 60px) * 0.08) !important;
    }

    .logo-wrapper img {
        width: calc(var(--slot-size, 60px) * 0.80) !important;
        height: calc(var(--slot-size, 60px) * 0.80) !important;
    }

    .type-icon-circle {
        width: calc(var(--slot-size, 60px) * 0.62) !important;
        height: calc(var(--slot-size, 60px) * 0.62) !important;
    }

    .type-header img {
        width: calc(var(--slot-size, 60px) * 0.45) !important;
        height: calc(var(--slot-size, 60px) * 0.45) !important;
    }

    .type-header {
        width: var(--slot-size, 60px) !important;
        height: var(--slot-size, 60px) !important;
        min-width: var(--slot-size, 60px) !important;
        padding: 5px !important;
        border-width: 2px !important;
        gap: 2px !important;
    }

    .type-header span {
        font-size: calc(var(--slot-size, 60px) * 0.11) !important;
    }

    .grid-scroll-wrapper {
        min-width: 1900px !important;
    }

    .watermark-icon {
        width: calc(var(--slot-size, 60px) * 0.65) !important;
        height: calc(var(--slot-size, 60px) * 0.65) !important;
    }

    .p-img {
        width: 95% !important;
        height: 95% !important;
    }

    .feature-slot-card {
        width: var(--slot-size, 60px) !important;
        height: var(--slot-size, 60px) !important;
        aspect-ratio: 1/1 !important;
    }

    .feature-p-img {
        width: calc(var(--slot-size, 60px) * 0.62) !important;
        height: calc(var(--slot-size, 60px) * 0.62) !important;
    }

    .slot-label-top {
        font-size: calc(var(--slot-size, 60px) * 0.08) !important;
        top: 5px !important;
    }

    .slot-plus {
        font-size:1.2rem !important;
        margin-top:10px !important;
    }
}

.download-watermark {
    display:none;
    text-align:center;
    width:100%;
    font-size:1.8rem;
    font-weight:800;
    color:rgba(220,
    220,
    220,
    0.5) !important;
    margin:40px 0;
    letter-spacing:4px;
    text-transform:lowercase;
    font-family:'Inter',
    sans-serif;
}

@keyframes rainbowShadow {
    0% {
        filter:drop-shadow(0 4px 12px rgba(255,
        0,
        0,
        0.6));
    }

    16% {
        filter:drop-shadow(0 4px 12px rgba(255,
        165,
        0,
        0.6));
    }

    33% {
        filter:drop-shadow(0 4px 12px rgba(255,
        255,
        0,
        0.6));
    }

    50% {
        filter:drop-shadow(0 4px 12px rgba(0,
        255,
        0,
        0.6));
    }

    66% {
        filter:drop-shadow(0 4px 12px rgba(0,
        0,
        255,
        0.6));
    }

    82% {
        filter:drop-shadow(0 4px 12px rgba(75,
        0,
        130,
        0.6));
    }

    100% {
        filter:drop-shadow(0 4px 12px rgba(238,
        130,
        238,
        0.6));
    }
}

.content-accordion-container {
    max-width:1300px;
    margin:4rem auto;
    padding:0 1rem;
}

.accordion-item {
    border-radius:20px;
    overflow:hidden;
    border:1px solid rgba(255,
    255,
    255,
    0.05);
    transition:all 0.4s cubic-bezier(0.4,
    0,
    0.2,
    1);
}

.accordion-header {
    padding:2rem;
    display:flex;
    justify-content:space-between;
    align-items:center;
    cursor:pointer;
    background:rgba(255,
    255,
    255,
    0.02);
}

.accordion-header h2 {
    font-size:1.5rem;
    margin:0;
    line-height:1.4;
    background:linear-gradient(135deg,
    #3b82f6,
    #0072ff);
    -webkit-background-clip:text;
    background-clip:text;
    -webkit-text-fill-color:transparent;
}

.toggle-icon {
    font-size:1.5rem;
    color:#4facfe;
    transition:transform 0.4s cubic-bezier(0.4,
    0,
    0.2,
    1);
}

.accordion-content {
    display:grid;
    grid-template-rows:0fr;
    overflow:hidden;
    transition:grid-template-rows 0.3s cubic-bezier(0.4,
    0,
    0.2,
    1);
    background:rgba(0,
    0,
    0,
    0.05);
}

.accordion-item.open .accordion-content {
    grid-template-rows:1fr;
}

.accordion-item.open .toggle-icon {
    transform:rotate(180deg);
}

.guide-inner {
    min-height:0;
    padding:0 2rem 2rem;
}

.guide-inner h3 {
    margin:2.5rem 0 1.5rem;
    color:#4facfe;
    border-bottom:1px solid rgba(79,
    172,
    254,
    0.2);
    padding-bottom:0.5rem;
}

.guide-inner p {
    margin-bottom:1.2rem;
    line-height:1.8;
    opacity:0.85;
}

.guide-inner ul {
    margin-left:1.5rem;
    margin-top:1rem;
}

.guide-inner li {
    margin-bottom:1rem;
    opacity:0.9;
}

.faq-list {
    margin:2rem 0;
}

.faq-item {
    margin-bottom:2rem;
    padding-bottom:1.5rem;
    border-bottom:1px solid rgba(255,
    255,
    255,
    0.05);
}

.faq-item:last-child {
    border:none;
}

.guide-footer {
    margin-top:3rem;
    padding:2rem;
    text-align:center;
    border-radius:12px;
}

[data-theme="light"] .accordion-header {
    background:rgba(0,
    0,
    0,
    0.02);
}

@media (max-width:768px) {
    .accordion-header h2 {
        font-size:1.2rem;
    }

    .guide-inner {
        padding:0 1rem 1.5rem;
    }
}

.reviews-section-container {
    animation:fadeIn 0.8s ease-out;
}

.star-rating span {
    transition:transform 0.2s,
    text-shadow 0.2s;
}

.star-rating span:hover {
    transform:scale(1.2);
    text-shadow:0 0 10px rgba(255,
    204,
    0,
    0.8);
}

.btn-submit-review:hover {
    transform:translateY(-3px);
    box-shadow:0 5px 15px rgba(255,
    59,
    59,
    0.4);
}

.review-public-card {
    transition:transform 0.3s,
    border-color 0.3s;
    border:1px solid rgba(255,
    255,
    255,
    0.05);
}

.review-public-card:hover {
    transform:translateX(5px);
    border-color:rgba(0,
    240,
    255,
    0.3);
}

.approved-reviews-container::-webkit-scrollbar {
    width:6px;
}

.approved-reviews-container::-webkit-scrollbar-track {
    background:rgba(255,
    255,
    255,
    0.02);
    border-radius:10px;
}

.approved-reviews-container::-webkit-scrollbar-thumb {
    background:rgba(0,
    240,
    255,
    0.3);
    border-radius:10px;
}

.approved-reviews-container::-webkit-scrollbar-thumb:hover {
    background:rgba(0,
    240,
    255,
    0.5);
}

@media (max-width:992px) {
    .reviews-grid {
        grid-template-columns:1fr !important;
        gap:2rem !important;
    }
}

.bottom-features-container {
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:4rem;
}

.feature-section {
    width:100%;
}

.feature-title-row {
    text-align:center;
    margin-bottom:2rem;
}

.feature-title {
    font-size:1.25rem;
}

#special-slots-container {
    justify-content:center;
    max-width:1400px;
    margin:0 auto;
    display:flex;
    flex-wrap:wrap;
    gap:1rem;
}

.feature-slot.glass {
    width:100px;
    height:100px;
    border-radius:12px;
    border:1px solid rgba(255,
    255,
    255,
    0.1);
    display:flex;
    align-items:center;
    justify-content:center;
    position:relative;
    cursor:pointer;
    transition:transform 0.2s;
    overflow:hidden;
}

.slot-placeholder {
    font-size:0.7rem;
    opacity:0.3;
    text-align:center;
    color:white;
}

#team-slots-container {
    justify-content:center;
    display:flex;
    flex-wrap:wrap;
    gap:1rem;
}

.feature-slot.team-slot {
    width:120px;
    height:120px;
    border-radius:15px;
    border:1px solid rgba(0,
    240,
    255,
    0.2);
    transition:all 0.3s;
}

.slot-placeholder.team-placeholder {
    font-size:0.8rem;
    opacity:0.4;
    color:#3b82f6;
}

.seo-content-section {
    max-width:1300px;
    margin:3rem auto 4rem;
    padding:0 1.5rem;
}

.seo-intro-block {
    background:rgba(255,
    255,
    255,
    0.03);
    border:1px solid rgba(0,
    240,
    255,
    0.15);
    border-left:4px solid #3b82f6;
    border-radius:20px;
    padding:2.5rem 3rem;
    margin-bottom:1.5rem;
}

.seo-intro-block h2 {
    font-size:1.75rem;
    font-weight:800;
    margin-bottom:1.2rem;
    background:linear-gradient(135deg,
    #3b82f6,
    #a78bfa);
    -webkit-background-clip:text;
    -webkit-text-fill-color:transparent;
    line-height:1.3;
}

.seo-tagline {
    font-size: 0.95rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
    font-style: italic;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 12px;
}


.seo-intro-block p {
    color:var(--text-color);
    opacity:0.85;
    line-height:1.85;
    font-size:1rem;
    margin-bottom:0.75rem;
}

.seo-cards-grid {
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:1.5rem;
    margin-bottom:1.5rem;
}

.seo-card {
    background:rgba(255,
    255,
    255,
    0.03);
    border:1px solid rgba(255,
    255,
    255,
    0.07);
    border-radius:18px;
    padding:2rem 2.2rem;
    transition:border-color 0.3s ease,
    transform 0.3s ease,
    box-shadow 0.3s ease;
    position:relative;
    overflow:hidden;
}

.seo-card::before {
    content:'';
    position:absolute;
    top:0;
    left:0;
    width:100%;
    height:3px;
    background:linear-gradient(90deg,
    #3b82f6,
    #a78bfa,
    #ff6ec7);
    opacity:0;
    transition:opacity 0.3s ease;
}

.seo-card:hover {
    border-color:rgba(0,
    240,
    255,
    0.25);
    transform:translateY(-4px);
    box-shadow:0 12px 40px rgba(0,
    240,
    255,
    0.08);
}

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

.seo-card.full-width {
    grid-column:1 / -1;
}

.seo-card h2,
.seo-card h3 {
    font-size:1.25rem;
    font-weight:800;
    color:#3b82f6;
    margin-bottom:1.2rem;
    padding-bottom:0.7rem;
    border-bottom:1px solid rgba(0, 240, 255, 0.15);
    display:flex;
    align-items:center;
    gap:0.5rem;
    font-family:'Outfit', sans-serif;
}

.seo-card p {
    color:var(--text-color);
    opacity:0.82;
    line-height:1.8;
    font-size:0.95rem;
    margin-bottom:0.7rem;
}

.seo-card p:last-child {
    margin-bottom:0;
}

.seo-steps-list {
    list-style:none !important;
    padding:0 !important;
    margin:0 0 1.2rem;
    display:flex;
    flex-direction:column;
    gap:0.55rem;
    counter-reset:step-counter;
}

.seo-steps-list li {
    color:var(--text-color);
    opacity:0.85;
    line-height:1.7;
    font-size:0.95rem;
    padding:0.75rem 1rem 0.75rem 3.2rem;
    background:rgba(0,
    240,
    255,
    0.04);
    border-radius:8px;
    border-left:2px solid rgba(0,
    240,
    255,
    0.3);
    position:relative;
}

.seo-steps-list li::before {
    counter-increment:step-counter;
    content:counter(step-counter);
    position:absolute;
    left:1rem;
    top:50%;
    transform:translateY(-50%);
    width:22px;
    height:22px;
    background:linear-gradient(135deg,
    #3b82f6,
    #0072ff);
    color:#000;
    border-radius:50%;
    display:flex;
    align-items:center;
    justify-content:center;
    font-weight:800;
    font-size:0.75rem;
    box-shadow:0 0 8px rgba(0,
    240,
    255,
    0.4);
    line-height:1;
}

.seo-steps-list li strong {
    color:#e2e8f0;
}

.seo-faq-grid {
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:1rem;
}

.seo-faq-item {
    background:rgba(0,
    0,
    0,
    0.2);
    border:1px solid rgba(255,
    255,
    255,
    0.05);
    border-radius:12px;
    padding:1.2rem 1.4rem;
    transition:border-color 0.3s;
}

.seo-faq-item:hover {
    border-color:rgba(167,
    139,
    250,
    0.3);
}

.seo-faq-item h3,
.seo-faq-item strong {
    display:block;
    color:#a78bfa;
    font-size:0.95rem;
    font-weight:700;
    margin:0 0 0.45rem;
    font-family:'Outfit', sans-serif;
}

.seo-faq-item p {
    color:var(--text-color);
    opacity:0.72;
    font-size:0.88rem;
    line-height:1.65;
    margin:0;
}

.seo-card.share-card h2,
.seo-card.share-card h3 {
    color:#ff6ec7;
    border-bottom-color:rgba(255, 110, 199, 0.2);
}

.seo-disclaimer {
    text-align:center;
    font-size:0.78rem;
    opacity:0.4;
    margin-top:0.5rem;
    font-style:italic;
    color:var(--text-color);
    line-height:1.6;
}

[data-theme="light"] .seo-intro-block,
[data-theme="light"] .seo-card {
    background:rgba(0, 0, 0, 0.02);
    border-color:rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .seo-card h2,
[data-theme="light"] .seo-card h3 {
    color:#0072ff;
    border-bottom:1px solid rgba(0, 114, 255, 0.15);
}

[data-theme="light"] .seo-card.share-card h2,
[data-theme="light"] .seo-card.share-card h3 {
    color:#c026d3;
    border-bottom-color:rgba(192, 38, 211, 0.15);
}

[data-theme="light"] .seo-faq-item h3,
[data-theme="light"] .seo-faq-item strong {
    color:#7c3aed;
}

[data-theme="light"] .seo-steps-list li {
    background:rgba(0,
    114,
    255,
    0.05);
    border-left:2px solid rgba(0,
    114,
    255,
    0.4);
}

[data-theme="light"] .seo-steps-list li strong {
    color:#0f172a;
}

[data-theme="light"] .seo-steps-list li::before {
    background:linear-gradient(135deg,
    #0072ff,
    #7c3aed);
    color:#fff;
    box-shadow:0 0 8px rgba(0,
    114,
    255,
    0.2);
}

[data-theme="light"] .seo-faq-item {
    background:rgba(0,
    0,
    0,
    0.03);
}

[data-theme="light"] .seo-faq-item strong {
    color:#7c3aed;
}

[data-theme="light"] .seo-intro-block h2 {
    background:linear-gradient(135deg,
    #0072ff,
    #7c3aed);
    -webkit-background-clip:text;
    -webkit-text-fill-color:transparent;
}

.seo-comparison-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.92rem;
}
.seo-comparison-table th, 
.seo-comparison-table td {
    padding: 12px 16px;
}
.seo-comparison-table tbody tr {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    transition: background 0.2s;
}
.seo-comparison-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.02);
}
.seo-comparison-table tbody tr:last-child {
    border-bottom: none;
}

[data-theme="light"] .seo-comparison-table thead tr {
    background: rgba(37, 99, 235, 0.06) !important;
    border-bottom: 2px solid rgba(37, 99, 235, 0.2) !important;
}
[data-theme="light"] .seo-comparison-table tbody tr {
    border-bottom: 1px solid rgba(0, 0, 0, 0.06) !important;
}
[data-theme="light"] .seo-comparison-table tbody tr:hover {
    background: rgba(0, 0, 0, 0.02) !important;
}

[data-theme="light"] .seo-tagline {
    color: #475569;
    border-bottom-color: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .seo-card:hover {
    border-color:rgba(0, 114, 255, 0.25);
    box-shadow:0 12px 40px rgba(0, 114, 255, 0.08);
}

@media (max-width:900px) {
    .seo-cards-grid {
        grid-template-columns:1fr;
    }

    .seo-faq-grid {
        grid-template-columns:1fr;
    }

    .seo-intro-block {
        padding:1.8rem;
    }

    .seo-intro-block h2 {
        font-size:1.35rem;
    }

    .seo-card {
        padding:1.5rem;
    }
}

@media (max-width:480px) {
    .seo-content-section {
        padding:0 1rem;
    }
}



/* ══════════════════════════════════════════════════════════════════
   DESKTOP FLOATING ACTION BAR  (#desktop-fab)
   Fixed bottom-center pill — only shown on desktop (≥769px)
   ══════════════════════════════════════════════════════════════════ */

#desktop-fab {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9998;
    display: flex;
    align-items: center;
    gap: 2px;
    background: rgba(15, 23, 42, 0.82);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    padding: 6px 10px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255,255,255,0.05);
    animation: fabSlideUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

@keyframes fabSlideUp {
    from { transform: translateX(-50%) translateY(30px); opacity: 0; }
    to   { transform: translateX(-50%) translateY(0);    opacity: 1; }
}

.fab-btn {
    width: 44px;
    height: 44px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.75);
    transition: background 0.18s, color 0.18s, transform 0.15s;
    flex-shrink: 0;
    position: relative;
}

.fab-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    transform: translateY(-2px);
}

.fab-btn:active {
    transform: scale(0.92);
}

#download-btn-fab:hover {
    background: rgba(0, 240, 255, 0.12);
    color: #3b82f6;
}

.fab-divider {
    width: 1px;
    height: 24px;
    background: rgba(255, 255, 255, 0.12);
    margin: 0 4px;
    flex-shrink: 0;
}

.fab-dropdown .dropdown-content {
    bottom: calc(100% + 12px);
    top: auto;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    min-width: 160px;
    max-height: 260px;
    overflow-y: auto;
    border-radius: 14px;
}

[data-theme="light"] #desktop-fab {
    background: rgba(255, 255, 255, 0.88);
    border-color: rgba(0, 0, 0, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0,0,0,0.04);
}

[data-theme="light"] .fab-btn {
    color: rgba(30, 41, 59, 0.7);
}

[data-theme="light"] .fab-btn:hover {
    background: rgba(0, 0, 0, 0.06);
    color: #1e293b;
}

[data-theme="light"] #download-btn-fab:hover {
    background: rgba(0, 114, 255, 0.08);
    color: #0072ff;
}

[data-theme="light"] .fab-divider {
    background: rgba(0, 0, 0, 0.1);
}

/* ══════════════════════════════════════════════════════════════════
   FAB GRID SIZE SLIDER POPOVER
   ══════════════════════════════════════════════════════════════════ */

.fab-grid-size-popover {
    position: absolute;
    bottom: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    width: 180px;
    padding: 12px 16px;
    border-radius: 14px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.08);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), visibility 0.2s;
    pointer-events: auto;
}

.fab-grid-size-popover.show {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

#grid-size-badge-fab {
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border: 1.5px solid currentColor;
    border-radius: 50%;
    transition: transform 0.15s;
}

.fab-btn:hover #grid-size-badge-fab {
    transform: scale(1.08);
}

[data-theme="light"] .fab-grid-size-popover {
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1), 0 0 0 1px rgba(0, 0, 0, 0.06);
}

/* Mobile Grid Size Popover and Badge */
.mob-grid-size-popover {
    position: absolute;
    bottom: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    width: 180px;
    padding: 12px 16px;
    border-radius: 14px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.08);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), visibility 0.2s;
    pointer-events: auto;
}

.mob-grid-size-popover.show {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

#grid-size-badge-mob {
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border: 1.5px solid currentColor;
    border-radius: 50%;
    transition: transform 0.15s;
}

.header-right .btn-icon:hover #grid-size-badge-mob {
    transform: scale(1.08);
}

[data-theme="light"] .mob-grid-size-popover {
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1), 0 0 0 1px rgba(0, 0, 0, 0.06);
}

.grid-size-container {
    display: none !important;
}


/* ══════════════════════════════════════════════════════════════════
   MAIN PAGE HEADING BLOCK (Moved from Header)
   ══════════════════════════════════════════════════════════════════ */

.main-heading-block {
    text-align: center;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(59, 130, 246, 0.1);
    border-top: 4px solid #3b82f6;
    border-radius: 20px;
    padding: 2.5rem 2rem;
    margin-bottom: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.main-heading-block #site-title {
    font-size: 2.2rem;
    font-weight: 900;
    color: #3b82f6;
    text-shadow: 0 0 20px rgba(59, 130, 246, 0.2);
    margin: 0;
    line-height: 1.2;
}

.main-heading-block #site-tagline {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-color);
    opacity: 0.75;
    letter-spacing: 0.5px;
    margin: 0;
}

/* Light mode overrides for Main Heading Block */
[data-theme="light"] .main-heading-block {
    background: rgba(0, 0, 0, 0.02);
    border-color: rgba(0, 0, 0, 0.08);
    border-top-color: #0072ff;
}

[data-theme="light"] .main-heading-block #site-title {
    color: #0072ff;
    text-shadow: none;
    background: linear-gradient(135deg, #0072ff, #7c3aed);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

[data-theme="light"] .main-heading-block #site-tagline {
    color: #475569;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .main-heading-block {
        padding: 1.8rem 1.2rem;
        margin-bottom: 1.5rem;
    }
    .main-heading-block #site-title {
        font-size: 1.6rem;
    }
    .main-heading-block #site-tagline {
        font-size: 0.85rem;
    }
}


/* ══════════════════════════════════════════════════════════════════
   DOWNLOAD PERSONALISATION MODAL
══════════════════════════════════════════════════════════════════ */

.dl-custom-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.82);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 99999;
    padding: 1rem;
    animation: dlFadeIn 0.25s ease;
}

@keyframes dlFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.dl-custom-modal {
    width: 100%;
    max-width: 520px;
    border-radius: 24px;
    overflow: hidden;
    animation: dlSlideUp 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: #18181b;
    box-shadow: 0 0 60px rgba(59, 130, 246, 0.05), 0 30px 80px rgba(0, 0, 0, 0.5);
}

@keyframes dlSlideUp {
    from { transform: translateY(30px) scale(0.96); opacity: 0; }
    to   { transform: translateY(0)    scale(1);    opacity: 1; }
}

/* ── Header ── */
.dl-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 1.8rem 1.2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    background: rgba(59, 130, 246, 0.02);
}

.dl-modal-title-group {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.dl-modal-icon {
    font-size: 2rem;
    line-height: 1;
}

.dl-modal-header h2 {
    font-size: 1.15rem;
    font-weight: 800;
    margin: 0 0 2px;
    color: var(--text-color);
}

.dl-modal-header p {
    font-size: 0.8rem;
    opacity: 0.5;
    margin: 0;
}

.dl-close-btn {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-color);
    width: 34px;
    height: 34px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.2s;
    flex-shrink: 0;
}

.dl-close-btn:hover {
    background: rgba(255, 50, 50, 0.2);
    transform: scale(1.1);
}

/* ── Body ── */
.dl-modal-body {
    padding: 1.6rem 1.8rem;
    display: flex;
    flex-direction: column;
    gap: 1.4rem;
}

.dl-field-group {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.dl-label {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-color);
    opacity: 0.8;
    letter-spacing: 0.3px;
}

.dl-optional {
    font-weight: 400;
    opacity: 0.45;
    font-size: 0.78rem;
}

/* ── Photo Upload ── */
.dl-photo-upload-area {
    display: flex;
    align-items: center;
    gap: 1.2rem;
}

.dl-photo-preview-ring {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 2.5px dashed rgba(59, 130, 246, 0.2);
    background: rgba(59, 130, 246, 0.03);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: border-color 0.25s, background 0.25s, transform 0.2s;
    overflow: hidden;
    flex-shrink: 0;
    position: relative;
}

.dl-photo-preview-ring:hover {
    border-color: #3b82f6;
    background: rgba(59, 130, 246, 0.08);
    transform: scale(1.04);
}

.dl-photo-preview-ring.has-photo {
    border-style: solid;
    border-color: rgba(0, 240, 255, 0.6);
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.15);
}

.dl-photo-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    color: var(--text-color);
    opacity: 0.4;
    font-size: 0.55rem;
    font-weight: 600;
    text-align: center;
    pointer-events: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dl-photo-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.dl-photo-meta {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.dl-photo-hint {
    font-size: 0.75rem;
    opacity: 0.4;
    margin: 0;
}

.dl-remove-photo {
    background: rgba(255, 50, 50, 0.12);
    border: 1px solid rgba(255, 50, 50, 0.3);
    color: #ff6060;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s;
    width: fit-content;
}

.dl-remove-photo:hover {
    background: rgba(255, 50, 50, 0.22);
}

/* ── Name Input ── */
.dl-input-wrap {
    position: relative;
}

.dl-name-input {
    width: 100%;
    padding: 0.85rem 3.5rem 0.85rem 1rem;
    border-radius: 12px;
    border: 1.5px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-color);
    font-size: 1rem;
    font-weight: 600;
    outline: none;
    transition: border-color 0.25s, box-shadow 0.25s;
    box-sizing: border-box;
}

.dl-name-input:focus {
    border-color: rgba(59, 130, 246, 0.3);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.05);
}

.dl-name-input::placeholder {
    opacity: 0.3;
    font-weight: 400;
}

.dl-char-count {
    position: absolute;
    right: 0.8rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.7rem;
    opacity: 0.35;
    pointer-events: none;
}

.dl-input-hint {
    font-size: 0.78rem;
    opacity: 0.5;
    margin: 0;
    line-height: 1.4;
}

.dl-input-hint strong {
    color: #3b82f6;
    opacity: 1;
}

/* ── Live Banner Preview ── */
.dl-banner-preview {
    background: linear-gradient(135deg, rgba(0, 240, 255, 0.06), rgba(167, 139, 250, 0.06));
    border: 1px solid rgba(0, 240, 255, 0.12);
    border-radius: 14px;
    padding: 1rem 1.3rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    position: relative;
    min-height: 72px;
}

.dl-banner-photo-wrap {
    flex-shrink: 0;
}

.dl-banner-circle {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(167, 139, 250, 0.2));
    border: 2.5px solid rgba(59, 130, 246, 0.2);
    box-shadow: 0 0 16px rgba(59, 130, 246, 0.15), inset 0 0 10px rgba(59, 130, 246, 0.03);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: box-shadow 0.3s;
}

.dl-banner-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.dl-banner-text-wrap {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.dl-banner-name {
    font-size: 1rem;
    font-weight: 800;
    background: linear-gradient(120deg, #3b82f6, #a78bfa);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1.2;
}

.dl-banner-subtitle {
    font-size: 0.72rem;
    opacity: 0.5;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.dl-preview-label {
    position: absolute;
    top: 8px;
    right: 10px;
    font-size: 0.6rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.3;
    color: #3b82f6;
}

/* ── Footer ── */
.dl-modal-footer {
    padding: 1.2rem 1.8rem 1.6rem;
    display: flex;
    justify-content: flex-end;
    gap: 0.8rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.dl-skip-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--text-color);
    padding: 0.75rem 1.3rem;
    border-radius: 12px;
    cursor: pointer;
    font-size: 0.88rem;
    font-weight: 600;
    opacity: 0.7;
    transition: opacity 0.2s, background 0.2s;
}

.dl-skip-btn:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.09);
}

.dl-download-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #2563eb !important;
    border: none;
    color: #ffffff !important;
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 700;
    transition: background 0.2s, transform 0.15s;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
}

.dl-download-btn:hover {
    background: #1d4ed8 !important;
    color: #ffffff !important;
    transform: translateY(-2px);
}

.dl-download-btn:active {
    transform: scale(0.97);
}

.dl-download-btn.loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Light theme modal adjustments (Crisp Pure White) */
[data-theme="light"] .dl-custom-modal {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15) !important;
}

[data-theme="light"] .dl-modal-header {
    background: #ffffff !important;
    border-bottom: 1px solid #f1f5f9 !important;
}

[data-theme="light"] .dl-modal-header h2 {
    color: #0f172a !important;
}

[data-theme="light"] .dl-modal-header p {
    color: #64748b !important;
    opacity: 1 !important;
}

[data-theme="light"] .dl-label {
    color: #1e293b !important;
}

[data-theme="light"] .dl-name-input {
    background: #f8fafc !important;
    border: 1.5px solid #cbd5e1 !important;
    color: #0f172a !important;
}

[data-theme="light"] .dl-name-input:focus {
    background: #ffffff !important;
    border-color: #2563eb !important;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12) !important;
}

[data-theme="light"] .dl-input-hint {
    color: #64748b !important;
    opacity: 1 !important;
}

[data-theme="light"] .dl-close-btn {
    background: #f1f5f9 !important;
    border: 1px solid #e2e8f0 !important;
    color: #64748b !important;
}

[data-theme="light"] .dl-close-btn:hover {
    background: #fee2e2 !important;
    color: #ef4444 !important;
}

[data-theme="light"] .dl-char-count {
    color: #94a3b8 !important;
}

[data-theme="light"] #share-generate-btn,
[data-theme="light"] .dl-download-btn {
    background: #2563eb !important;
    color: #ffffff !important;
}

[data-theme="light"] #share-url-output {
    background: #f8fafc !important;
    border: 1.5px solid #cbd5e1 !important;
    color: #0f172a !important;
}

[data-theme="light"] .dl-banner-preview {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.05), rgba(79, 70, 229, 0.05));
    border-color: rgba(37, 99, 235, 0.15);
}

/* ── Injected header banner (appears inside capture-target during render) ── */
.dl-injected-banner {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    padding: 22px 40px 0px;
    box-sizing: border-box;
    margin-bottom: 20px;
}

.dl-injected-photo {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(59, 130, 246, 0.7);
    box-shadow: 0 0 22px rgba(59, 130, 246, 0.2), 0 0 40px rgba(59, 130, 246, 0.1);
    flex-shrink: 0;
}

.dl-injected-photo-placeholder {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(167, 139, 250, 0.2));
    border: 3px solid rgba(59, 130, 246, 0.3);
    box-shadow: 0 0 22px rgba(59, 130, 246, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 2rem;
}

.dl-injected-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.dl-injected-title {
    font-size: 1.5rem;
    font-weight: 900;
    color: #3b82f6;
    text-shadow: 0 0 15px rgba(59, 130, 246, 0.3);
    white-space: nowrap;
    letter-spacing: 0.3px;
}

.dl-injected-title em {
    font-style: normal;
    color: #ffffff;
}

.dl-injected-sub {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    font-weight: 500;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

/* Mobile tweaks */
@media (max-width: 540px) {
    .dl-custom-modal {
        border-radius: 18px;
    }
    .dl-modal-header,
    .dl-modal-body,
    .dl-modal-footer {
        padding-left: 1.2rem;
        padding-right: 1.2rem;
    }
    .dl-modal-footer {
        flex-direction: column;
    }
    .dl-skip-btn,
    .dl-download-btn {
        width: 100%;
        justify-content: center;
    }
}



/* ── Light theme contrast adjustments for Download Modal ── */
[data-theme="light"] .dl-modal-header p {
    color: #475569;
    opacity: 0.9;
}

[data-theme="light"] .dl-modal-header h2 {
    background: linear-gradient(120deg, #0055ff, #7c3aed);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

[data-theme="light"] .dl-optional {
    color: #475569;
    opacity: 0.85;
}

[data-theme="light"] .dl-photo-hint {
    color: #475569;
    opacity: 0.85;
}

[data-theme="light"] .dl-name-input::placeholder {
    color: #94a3b8;
    opacity: 1;
}

[data-theme="light"] .dl-char-count {
    color: #475569;
    opacity: 0.85;
}

[data-theme="light"] .dl-input-hint {
    color: #334155;
    opacity: 0.9;
}

[data-theme="light"] .dl-input-hint strong {
    color: #0055ff;
}

[data-theme="light"] .dl-banner-name {
    color: #ff3b3b !important;
    background: none !important;
    -webkit-text-fill-color: initial !important;
}

[data-theme="light"] .dl-banner-subtitle {
    color: #475569;
    opacity: 0.9;
}

[data-theme="light"] .dl-banner-circle svg {
    stroke: #0055ff;
    opacity: 0.65 !important;
}

[data-theme="light"] .dl-banner-circle {
    border-color: rgba(0, 114, 255, 0.4);
    box-shadow: 0 0 16px rgba(0, 114, 255, 0.15);
}

[data-theme="light"] .dl-preview-label {
    color: #0055ff;
    opacity: 0.6;
}

[data-theme="light"] .dl-close-btn {
    background: rgba(0, 0, 0, 0.05);
    border-color: rgba(0, 0, 0, 0.08);
    color: #1e293b;
}

[data-theme="light"] .dl-skip-btn {
    background: rgba(0, 0, 0, 0.03);
    border-color: rgba(0, 0, 0, 0.1);
    color: #1e293b;
    opacity: 0.85;
}

[data-theme="light"] .dl-skip-btn:hover {
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .dl-photo-placeholder {
    color: #1e293b;
    opacity: 0.6;
}

[data-theme="light"] .dl-photo-preview-ring {
    border-color: rgba(0, 114, 255, 0.3);
    background: rgba(0, 114, 255, 0.02);
}

[data-theme="light"] .dl-photo-preview-ring:hover {
    border-color: #0055ff;
    background: rgba(0, 114, 255, 0.06);
}

[data-theme="light"] .dl-photo-preview-ring.has-photo {
    border-color: rgba(0, 114, 255, 0.6);
    box-shadow: 0 0 20px rgba(0, 114, 255, 0.15);
}



/* ── Light mode injected banner text/photo styles (Downloaded image header) ── */
[data-theme="light"] .dl-injected-title em {
    color: #ff3b3b !important; /* Red color for name in light mode */
    text-shadow: none !important;
}

[data-theme="light"] .dl-injected-title {
    color: #1e293b !important; /* Dark slate for "Favorite Pokémons" in light mode */
    text-shadow: none !important;
}

[data-theme="light"] .dl-injected-sub {
    color: #64748b !important; /* Slate-500 for URL subtitle */
}

[data-theme="light"] .dl-injected-photo {
    border-color: #ff3b3b !important;
    box-shadow: 0 4px 15px rgba(255, 59, 59, 0.2) !important;
}

[data-theme="light"] .dl-injected-photo-placeholder {
    border-color: rgba(0, 0, 0, 0.15) !important;
    background: rgba(0, 0, 0, 0.05) !important;
    box-shadow: none !important;
}

/* ═══ Header Navigation Menu ═══ */

/* Desktop menu structure */
.header-nav-desktop {
    display: flex;
    align-items: center;
    gap: 1.8rem;
    margin-left: auto;
    margin-right: 2.2rem;
}

.nav-item-link, .nav-dropdown-btn {
    background: transparent;
    border: none;
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: color 0.2s, opacity 0.2s;
    font-family: inherit;
    opacity: 0.85;
}

.nav-item-link:hover, .nav-dropdown-btn:hover {
    color: #3b82f6;
    opacity: 1;
}

[data-theme="light"] .nav-item-link:hover, 
[data-theme="light"] .nav-dropdown-btn:hover {
    color: #2563eb;
}

/* Dropdown layout */
.nav-dropdown-wrapper {
    position: relative;
}

.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 0.5rem;
    min-width: 220px;
    border-radius: 14px;
    border: 1px solid var(--glass-border);
    padding: 0.5rem;
    display: none;
    flex-direction: column;
    gap: 0.2rem;
    z-index: 10000;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    background: var(--glass-bg);
}

/* Pseudo-element bridge to prevent hover loss between button and menu */
.nav-dropdown-menu::before {
    content: '';
    position: absolute;
    top: -15px;
    left: 0;
    width: 100%;
    height: 15px;
    background: transparent;
}

.nav-dropdown-menu.show {
    display: flex;
}

.nav-dropdown-menu a {
    color: var(--text-color);
    text-decoration: none;
    padding: 0.6rem 1rem;
    border-radius: 8px;
    font-size: 0.88rem;
    font-weight: 500;
    transition: background 0.2s, color 0.2s;
    opacity: 0.9;
}

.nav-dropdown-menu a:hover {
    background: rgba(59, 130, 246, 0.08);
    color: #3b82f6;
    opacity: 1;
}

[data-theme="light"] .nav-dropdown-menu a:hover {
    background: rgba(37, 99, 235, 0.08);
    color: #2563eb;
}

.dropdown-chevron {
    transition: transform 0.2s ease;
    opacity: 0.7;
}

/* Hamburger menu toggle default */
#hamburger-btn {
    display: none;
}

/* ═══ Mobile Drawer Styles ═══ */
.mobile-drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 99998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.mobile-drawer-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.mobile-drawer {
    position: fixed;
    top: 0;
    right: -300px;
    width: 280px;
    height: 100vh;
    background: var(--sticky-bg);
    border-left: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 99999;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    transition: right 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: -10px 0 30px rgba(0,0,0,0.3);
}

.mobile-drawer.open {
    right: 0;
}

.drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 1rem;
}

.drawer-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-color);
}

.close-drawer-btn {
    padding: 0.5rem !important;
}

.drawer-body {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.drawer-link {
    color: var(--text-color);
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 600;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.03);
    display: block;
    opacity: 0.9;
}

.drawer-link:hover {
    color: #3b82f6;
}

[data-theme="light"] .drawer-link:hover {
    color: #2563eb;
}

/* Mobile accordion */
.drawer-accordion {
    display: flex;
    flex-direction: column;
}

.drawer-accordion-btn {
    background: transparent;
    border: none;
    color: var(--text-color);
    font-family: inherit;
    text-align: left;
    font-size: 1.1rem;
    font-weight: 600;
    padding: 0.5rem 0;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    opacity: 0.9;
    border-bottom: 1px solid rgba(255,255,255,0.03);
}

.drawer-accordion-btn:hover {
    color: #3b82f6;
}

[data-theme="light"] .drawer-accordion-btn:hover {
    color: #2563eb;
}

.accordion-chevron {
    transition: transform 0.2s ease;
}

.drawer-accordion-btn.active .accordion-chevron {
    transform: rotate(180deg);
}

.drawer-accordion-content {
    display: none;
    flex-direction: column;
    padding-left: 1rem;
    gap: 0.6rem;
    margin-top: 0.6rem;
}

.drawer-accordion-content.show {
    display: flex;
}

.drawer-accordion-content a {
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    opacity: 0.75;
    padding: 0.3rem 0;
}

.drawer-accordion-content a:hover {
    opacity: 1;
    color: #3b82f6;
}

[data-theme="light"] .drawer-accordion-content a:hover {
    color: #2563eb;
}

/* Responsive navigation styling */
@media (max-width: 768px) {
    .header-nav-desktop {
        display: none !important;
    }
    #hamburger-btn {
        display: flex !important;
        position: absolute !important;
        right: 1rem !important;
        top: 50% !important;
        transform: translateY(-50%) !important;
        z-index: 100000 !important;
        background: none !important;
        border: none !important;
        color: var(--text-color) !important;
        cursor: pointer !important;
        padding: 8px !important;
        align-items: center !important;
        justify-content: center !important;
    }
}

/* Shared Team Personalized Top Banner (Compact) */
.shared-team-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.7rem 1.4rem !important;
    border-radius: 12px !important;
    margin: 0.8rem 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box;
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: none;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

@media (max-width: 768px) {
    .shared-team-banner {
        width: 100%;
        margin: 0.8rem 0 !important;
        padding: 0.8rem 1rem !important;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.8rem;
        border-radius: 12px;
    }
    
    .shared-team-banner a.btn-secondary {
        width: 100%;
        text-align: center;
        box-sizing: border-box;
    }
}

/* ═══════════════════════════════════════════════════════════════
   NEWSPAPER THEME — COMPREHENSIVE OVERRIDES
   These rules override every hardcoded color to match the vintage
   newspaper look across all elements site-wide.
═══════════════════════════════════════════════════════════════ */

/* ---------- Base text & background ---------- */
[data-theme="newspaper"] body {
    background-color: #f4ecd8 !important;
    color: #2c241e !important;
}

[data-theme="newspaper"] #site-title {
    color: #2c241e !important;
    text-shadow: none !important;
    background: none !important;
    -webkit-text-fill-color: #2c241e !important;
}

[data-theme="newspaper"] #site-tagline {
    color: #5c4033 !important;
    opacity: 1 !important;
}

/* ---------- Header & Nav ---------- */
[data-theme="newspaper"] .main-header {
    background: rgba(244, 236, 216, 0.95) !important;
    border-bottom: 1px solid rgba(92, 64, 51, 0.2) !important;
    backdrop-filter: none !important;
}

[data-theme="newspaper"] .btn-icon {
    color: #2c241e !important;
}

[data-theme="newspaper"] .btn-icon:hover {
    background: rgba(92, 64, 51, 0.1) !important;
}

[data-theme="newspaper"] .nav-item-link,
[data-theme="newspaper"] .drawer-link,
[data-theme="newspaper"] .dropdown-content a,
[data-theme="newspaper"] .nav-dropdown-btn {
    color: #2c241e !important;
}

[data-theme="newspaper"] .nav-dropdown-menu,
[data-theme="newspaper"] .dropdown-content {
    background: rgba(244, 236, 216, 0.98) !important;
    border: 1px solid rgba(92, 64, 51, 0.2) !important;
}

[data-theme="newspaper"] .mobile-drawer {
    background: #f4ecd8 !important;
    border-right: 1px solid rgba(92, 64, 51, 0.2) !important;
}

[data-theme="newspaper"] .drawer-header {
    border-bottom: 1px solid rgba(92, 64, 51, 0.15) !important;
}

[data-theme="newspaper"] .drawer-title,
[data-theme="newspaper"] .drawer-accordion-btn {
    color: #2c241e !important;
}

/* ---------- Desktop FAB ---------- */
[data-theme="newspaper"] #desktop-fab {
    background: rgba(244, 236, 216, 0.95) !important;
    border: 1px solid rgba(92, 64, 51, 0.2) !important;
    box-shadow: 0 4px 16px rgba(92, 64, 51, 0.15) !important;
}

[data-theme="newspaper"] .fab-btn {
    color: #2c241e !important;
}

[data-theme="newspaper"] .fab-divider {
    background: rgba(92, 64, 51, 0.2) !important;
}

/* ---------- Scrollbar ---------- */
[data-theme="newspaper"] ::-webkit-scrollbar-track {
    background: rgba(92, 64, 51, 0.1) !important;
}

[data-theme="newspaper"] ::-webkit-scrollbar-thumb {
    background: #8b6a52 !important;
    box-shadow: none !important;
}

[data-theme="newspaper"] ::-webkit-scrollbar-thumb:hover {
    background: #5c4033 !important;
}

/* ---------- Grid Size Container ---------- */
[data-theme="newspaper"] .grid-size-container {
    color: #2c241e !important;
}

[data-theme="newspaper"] .drag-title {
    color: #2c241e !important;
}

/* ---------- Spreadsheet slots ---------- */
[data-theme="newspaper"] .pokemon-slot {
    background: #eae0c8 !important;
    border-color: rgba(92, 64, 51, 0.25) !important;
}

[data-theme="newspaper"] .pokemon-slot:hover {
    background: #dfd5bd !important;
    border: 1px solid #5c4033 !important;
    box-shadow: 0 0 10px rgba(92, 64, 51, 0.2),
                inset 0 0 4px rgba(92, 64, 51, 0.08) !important;
}

[data-theme="newspaper"] .plus-icon {
    color: #5c4033 !important;
    opacity: 0.6 !important;
}

[data-theme="newspaper"] .watermark-bg {
    background: rgba(234, 224, 200, 0.9) !important;
    border-color: rgba(92, 64, 51, 0.2) !important;
}

[data-theme="newspaper"] .p-name {
    color: #2c241e !important;
}

/* ---------- Gen Badges — strip bright gradients ---------- */
[data-theme="newspaper"] .gen-badge,
[data-theme="newspaper"] .gen-1,
[data-theme="newspaper"] .gen-2,
[data-theme="newspaper"] .gen-3,
[data-theme="newspaper"] .gen-4,
[data-theme="newspaper"] .gen-5,
[data-theme="newspaper"] .gen-6,
[data-theme="newspaper"] .gen-7,
[data-theme="newspaper"] .gen-8,
[data-theme="newspaper"] .gen-9,
[data-theme="newspaper"] .gen-forms {
    background: #c9b898 !important;
    border: 1px solid rgba(92, 64, 51, 0.3) !important;
    color: #2c241e !important;
    text-shadow: none !important;
}

[data-theme="newspaper"] .gen-badge div,
[data-theme="newspaper"] .gen-label,
[data-theme="newspaper"] .gen-num,
[data-theme="newspaper"] .gen-region {
    color: #2c241e !important;
}

/* ---------- Type Headers — strip colored gradients ---------- */
[data-theme="newspaper"] .type-color-normal,
[data-theme="newspaper"] .type-color-fire,
[data-theme="newspaper"] .type-color-water,
[data-theme="newspaper"] .type-color-grass,
[data-theme="newspaper"] .type-color-electric,
[data-theme="newspaper"] .type-color-ice,
[data-theme="newspaper"] .type-color-fighting,
[data-theme="newspaper"] .type-color-poison,
[data-theme="newspaper"] .type-color-ground,
[data-theme="newspaper"] .type-color-flying,
[data-theme="newspaper"] .type-color-psychic,
[data-theme="newspaper"] .type-color-bug,
[data-theme="newspaper"] .type-color-rock,
[data-theme="newspaper"] .type-color-ghost,
[data-theme="newspaper"] .type-color-dragon,
[data-theme="newspaper"] .type-color-dark,
[data-theme="newspaper"] .type-color-steel,
[data-theme="newspaper"] .type-color-fairy,
[data-theme="newspaper"] .type-color-starter,
[data-theme="newspaper"] .type-color-legendary,
[data-theme="newspaper"] .type-color-ultra,
[data-theme="newspaper"] .type-header {
    background: #d6c8a8 !important;
    border-color: rgba(92, 64, 51, 0.2) !important;
}

[data-theme="newspaper"] .type-header span {
    color: #2c241e !important;
    opacity: 0.9 !important;
}

[data-theme="newspaper"] .type-icon-circle {
    background: rgba(234, 224, 200, 0.9) !important;
    border-color: rgba(92, 64, 51, 0.2) !important;
}

[data-theme="newspaper"] .type-header img {
    filter: sepia(50%) brightness(0.85) contrast(1.1) !important;
}

/* ---------- Logo wrapper — no rainbow ---------- */
[data-theme="newspaper"] .logo-wrapper {
    background: #c8b88a !important;
    animation: none !important;
    border: 1px solid rgba(92, 64, 51, 0.3) !important;
}

/* ---------- Modal (search/pick) ---------- */
[data-theme="newspaper"] .modal-overlay {
    background: rgba(44, 36, 30, 0.78) !important;
}

[data-theme="newspaper"] .modal-content {
    background: #f0e6ca !important;
    color: #2c241e !important;
    border: 1px solid rgba(92, 64, 51, 0.2) !important;
}

[data-theme="newspaper"] .modal-header {
    border-bottom-color: rgba(92, 64, 51, 0.15) !important;
}

[data-theme="newspaper"] .modal-header h2 {
    color: #2c241e !important;
}

[data-theme="newspaper"] .modal-search input,
[data-theme="newspaper"] input[type="text"],
[data-theme="newspaper"] input[type="search"],
[data-theme="newspaper"] input[type="email"],
[data-theme="newspaper"] textarea,
[data-theme="newspaper"] select {
    background: #eae0c8 !important;
    color: #2c241e !important;
    border-color: rgba(92, 64, 51, 0.25) !important;
}

[data-theme="newspaper"] .modal-p-card {
    background: #ddd4b8 !important;
    color: #2c241e !important;
}

[data-theme="newspaper"] .modal-p-card:hover {
    background: #d0c6a4 !important;
}

[data-theme="newspaper"] .modal-p-card .p-name {
    color: #2c241e !important;
}

/* ---------- Download Modal ---------- */
[data-theme="newspaper"] .dl-modal-wrap,
[data-theme="newspaper"] .dl-modal-card {
    background: #f0e6ca !important;
    border-color: rgba(92, 64, 51, 0.2) !important;
    color: #2c241e !important;
}

[data-theme="newspaper"] .dl-modal-title,
[data-theme="newspaper"] .dl-modal-subtitle,
[data-theme="newspaper"] .dl-label,
[data-theme="newspaper"] .dl-input-hint {
    color: #2c241e !important;
}

[data-theme="newspaper"] .dl-name-input {
    background: #eae0c8 !important;
    color: #2c241e !important;
    border-color: rgba(92, 64, 51, 0.25) !important;
}

[data-theme="newspaper"] .dl-banner-preview {
    background: #ddd4b8 !important;
    border-color: rgba(92, 64, 51, 0.2) !important;
}

[data-theme="newspaper"] .dl-banner-name,
[data-theme="newspaper"] .dl-banner-subtitle,
[data-theme="newspaper"] .dl-banner-circle {
    color: #2c241e !important;
}

[data-theme="newspaper"] .dl-skip-btn {
    color: #5c4033 !important;
    border-color: rgba(92, 64, 51, 0.3) !important;
    background: transparent !important;
}

[data-theme="newspaper"] .dl-download-btn {
    background: linear-gradient(135deg, #7a5c44, #4a2e1a) !important;
    color: #f4ecd8 !important;
    box-shadow: 0 4px 12px rgba(92, 64, 51, 0.3) !important;
}

/* ---------- Share modal ---------- */
[data-theme="newspaper"] #share-modal {
    background: rgba(44, 36, 30, 0.75) !important;
}

[data-theme="newspaper"] #share-modal .modal-content,
[data-theme="newspaper"] #share-modal .glass {
    background: #f0e6ca !important;
    border-color: rgba(92, 64, 51, 0.2) !important;
    color: #2c241e !important;
}

/* ---------- SEO Section ---------- */
[data-theme="newspaper"] .seo-content-section {
    background: transparent !important;
}

[data-theme="newspaper"] .main-heading-block,
[data-theme="newspaper"] .seo-intro-block {
    background: rgba(234, 224, 200, 0.6) !important;
    border-color: rgba(92, 64, 51, 0.15) !important;
    color: #2c241e !important;
}

[data-theme="newspaper"] .seo-intro-block h2,
[data-theme="newspaper"] .seo-intro-block p {
    color: #2c241e !important;
    background: none !important;
    -webkit-text-fill-color: #2c241e !important;
}

[data-theme="newspaper"] .seo-card {
    background: rgba(234, 224, 200, 0.7) !important;
    border-color: rgba(92, 64, 51, 0.15) !important;
    color: #2c241e !important;
}

[data-theme="newspaper"] .seo-card h3 {
    color: #2c241e !important;
    background: none !important;
    -webkit-text-fill-color: #2c241e !important;
}

[data-theme="newspaper"] .seo-card p,
[data-theme="newspaper"] .seo-card li,
[data-theme="newspaper"] .seo-card strong,
[data-theme="newspaper"] .seo-faq-item strong,
[data-theme="newspaper"] .seo-faq-item p {
    color: #2c241e !important;
}

[data-theme="newspaper"] .seo-steps-list li {
    color: #2c241e !important;
}

[data-theme="newspaper"] .seo-disclaimer {
    color: rgba(44, 36, 30, 0.6) !important;
}

/* ---------- Footer ---------- */
[data-theme="newspaper"] .main-footer {
    background: rgba(234, 224, 200, 0.95) !important;
    border-top: 1px solid rgba(92, 64, 51, 0.15) !important;
}

[data-theme="newspaper"] .footer-links-inline a,
[data-theme="newspaper"] .disclaimer-inline,
[data-theme="newspaper"] .footer-bottom p {
    color: #5c4033 !important;
    opacity: 1 !important;
}

[data-theme="newspaper"] .footer-links-inline svg {
    fill: #5c4033 !important;
}

/* ---------- Confirm popup ---------- */
[data-theme="newspaper"] .popup-overlay {
    background: rgba(44, 36, 30, 0.72) !important;
}

[data-theme="newspaper"] .popup-content {
    background: #f0e6ca !important;
    border-color: rgba(92, 64, 51, 0.2) !important;
    color: #2c241e !important;
}

[data-theme="newspaper"] .popup-content h3,
[data-theme="newspaper"] .popup-content p {
    color: #2c241e !important;
}

[data-theme="newspaper"] .btn-secondary {
    background: transparent !important;
    border: 1px solid rgba(92, 64, 51, 0.4) !important;
    color: #5c4033 !important;
}

[data-theme="newspaper"] .btn-danger {
    background: #8b2500 !important;
    color: #f4ecd8 !important;
    border-color: transparent !important;
}

/* ---------- Shared team banner ---------- */
[data-theme="newspaper"] .shared-team-banner {
    background: rgba(234, 224, 200, 0.88) !important;
    border: 1px solid rgba(92, 64, 51, 0.2) !important;
    box-shadow: none !important;
}

[data-theme="newspaper"] .shared-team-banner h2,
[data-theme="newspaper"] .shared-team-banner p {
    color: #2c241e !important;
}

/* ---------- Leaderboard ---------- */
[data-theme="newspaper"] .pokemon-stat-card,
[data-theme="newspaper"] .gen-top-card,
[data-theme="newspaper"] .recent-share-link {
    background: rgba(234, 224, 200, 0.7) !important;
    border-color: rgba(92, 64, 51, 0.15) !important;
}

[data-theme="newspaper"] .pokemon-stat-card *,
[data-theme="newspaper"] .gen-top-card *,
[data-theme="newspaper"] .recent-share-link * {
    color: #2c241e !important;
    -webkit-text-fill-color: #2c241e !important;
    background: none !important;
    text-shadow: none !important;
}

[data-theme="newspaper"] .rank-badge {
    background: #8b6a52 !important;
    color: #f4ecd8 !important;
}

[data-theme="newspaper"] .pokemon-stat-card img {
    filter: sepia(20%) brightness(0.9) !important;
}

/* ---------- Feature Sections (Extended Special Categories & 6-Slot Team) ---------- */

/* Section headings "EXTENDED SPECIAL CATEGORIES", "ULTIMATE 6-SLOT TEAM" */
[data-theme="newspaper"] .feature-title {
    color: #5c4033 !important;
}

/* Feature slot cards — remove dark navy */
[data-theme="newspaper"] .feature-slot-card {
    background: #eae0c8 !important;
    border-color: rgba(92, 64, 51, 0.25) !important;
}

/* Feature slot hover */
[data-theme="newspaper"] .feature-slot-card:hover {
    background: #dfd5bd !important;
    border-color: #5c4033 !important;
    box-shadow: 0 0 10px rgba(92, 64, 51, 0.2) !important;
}

/* Filled feature slot borders */
[data-theme="newspaper"] .feature-slot-card.filled {
    border-color: rgba(92, 64, 51, 0.4) !important;
}

/* Special glow on feature slot */
[data-theme="newspaper"] .feature-slot-card.special-glow {
    border-color: rgba(92, 64, 51, 0.5) !important;
    box-shadow: 0 0 12px rgba(92, 64, 51, 0.2) !important;
}

/* Plus icon inside feature slot */
[data-theme="newspaper"] .slot-plus {
    color: #5c4033 !important;
    opacity: 0.4 !important;
}

[data-theme="newspaper"] .feature-slot-card:hover .slot-plus {
    color: #2c241e !important;
    opacity: 0.7 !important;
}

/* Slot placeholder text */
[data-theme="newspaper"] .slot-placeholder,
[data-theme="newspaper"] .slot-placeholder.team-placeholder {
    color: #5c4033 !important;
    opacity: 0.5 !important;
}

/* Team slot specific */
[data-theme="newspaper"] .feature-slot.team-slot,
[data-theme="newspaper"] .feature-slot.glass {
    background: #eae0c8 !important;
    border-color: rgba(92, 64, 51, 0.2) !important;
}

/* Pokemon hover name overlay inside slots */
[data-theme="newspaper"] .pokemon-hover-name {
    background: rgba(92, 64, 51, 0.85) !important;
    color: #f4ecd8 !important;
}

/* Slot top/bottom labels */
[data-theme="newspaper"] .slot-label-top,
[data-theme="newspaper"] .slot-label-bottom {
    color: #2c241e !important;
    opacity: 0.7 !important;
}

/* Bottom features container background */
[data-theme="newspaper"] .bottom-features-container {
    background: transparent !important;
}

/* SEO tagline and intro block accents */
[data-theme="newspaper"] .seo-tagline {
    color: rgba(44, 36, 30, 0.65) !important;
    border-bottom-color: rgba(92, 64, 51, 0.15) !important;
}

[data-theme="newspaper"] .seo-intro-block {
    border-left-color: #8b6a52 !important;
    border-color: rgba(92, 64, 51, 0.15) !important;
}

/* ---------- Mobile Bottom Action Bar ---------- */
@media (max-width: 768px) {
    [data-theme="newspaper"] .header-right {
        background: rgba(244, 236, 216, 0.97) !important;
        border-top: 1px solid rgba(92, 64, 51, 0.2) !important;
        box-shadow: 0 -4px 20px rgba(92, 64, 51, 0.15) !important;
        backdrop-filter: blur(10px) !important;
        -webkit-backdrop-filter: blur(10px) !important;
    }

    [data-theme="newspaper"] .header-right .btn-icon {
        color: #2c241e !important;
    }

    [data-theme="newspaper"] .header-right .btn-icon svg {
        stroke: #2c241e !important;
        color: #2c241e !important;
    }

    [data-theme="newspaper"] .header-right .btn-icon:hover {
        background: rgba(92, 64, 51, 0.1) !important;
    }

    /* Grid size badge in mobile bar */
    [data-theme="newspaper"] #grid-size-badge-mob {
        background: #8b6a52 !important;
        color: #f4ecd8 !important;
    }

    /* Dropdown from bottom bar */
    [data-theme="newspaper"] .header-right .dropdown-content {
        background: rgba(244, 236, 216, 0.98) !important;
        border: 1px solid rgba(92, 64, 51, 0.2) !important;
    }

    [data-theme="newspaper"] .header-right .dropdown-content a {
        color: #2c241e !important;
    }
}
