@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
    --font-sans: 'Inter', sans-serif;
    --font-heading: 'Plus Jakarta Sans', sans-serif;
    --bg-page: rgba(248, 250, 252, 0.70);
    --bg-white: #ffffff;
    --bg-subtle: #f8fafc;
    --bg-muted: rgba(226, 232, 240, 0.60);
    --border: rgba(226, 232, 240, 0.80);
    --border-hover: #cbd5e1;
    --text-900: #0f172a;
    --text-500: #64748b;
    --text-400: #94a3b8;
    --accent-blue: #2563eb;
    --accent-emerald: #10b981;
    --accent-stripe: #635bff;
    --shadow-sm: 0 1px 3px rgba(15,23,42,0.08), 0 1px 2px rgba(15,23,42,0.04);
    --shadow-md: 0 4px 16px rgba(15,23,42,0.10), 0 1px 4px rgba(15,23,42,0.06);
    --shadow-lg: 0 12px 40px rgba(15,23,42,0.12), 0 2px 8px rgba(15,23,42,0.06);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-full: 9999px;
}

body.dark-theme {
    --bg-page: rgba(15, 23, 42, 0.95);
    --bg-white: #1e293b;
    --bg-subtle: #0f172a;
    --bg-muted: rgba(51, 65, 85, 0.60);
    --border: #334155;
    --border-hover: #475569;
    --text-900: #f8fafc;
    --text-500: #94a3b8;
    --text-400: #64748b;
    color-scheme: dark;
}

body.dark-theme #Poland path:not(.hovered):not(.active) {
    fill: #1e293b;
}
body.dark-theme #Poland path {
    stroke: #334155;
}
body.dark-theme::before {
    display: none;
}
body.dark-theme #bg-overlay {
    background: rgba(15, 23, 42, 0.85);
}
body.dark-theme .glass-header {
    background: rgba(15, 23, 42, 0.85);
}
body.dark-theme .modal-content * {
    color: var(--text-900);
}
body.dark-theme .stat-value {
    color: var(--text-900);
}
body.dark-theme .stat-label {
    color: var(--text-500);
}
body.dark-theme h1, 
body.dark-theme h2, 
body.dark-theme h3, 
body.dark-theme h4, 
body.dark-theme .trip-title {
    color: var(--text-900) !important;
}

::selection { background: #0f172a; color: #fff; }
* { margin: 0; padding: 0; box-sizing: border-box; }

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
}

body {
    background: var(--bg-page);
    color: var(--text-900);
    font-family: var(--font-sans);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    touch-action: manipulation;
    -webkit-font-smoothing: antialiased;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse 80% 60% at 20% -10%, rgba(219,234,254,0.25) 0%, transparent 60%),
        radial-gradient(ellipse 60% 50% at 80% 110%, rgba(236,253,245,0.20) 0%, transparent 55%);
    z-index: -1;
    pointer-events: none;
}

/* ─── VIDEO BG ────────────────────────────────────────────── */
#bg-video {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    object-fit: cover;
    z-index: -100;
    pointer-events: none;
}

#bg-overlay {
    position: fixed;
    inset: 0;
    background: rgba(248, 250, 252, 0.85); /* Zwiększone krycie dla rekompensaty braku bluru */
    z-index: -99;
    pointer-events: none;
    /* Usunięto backdrop-filter, który over video niszczył CPU (1px blur 60fps fullscreen) */
}

/* ─── PROMO BANNER ─────────────────────────────────────────── */
#promo-banner {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: linear-gradient(135deg, #d40b0b, #ef4444);
    color: white;
    text-align: center;
    padding: 0.6rem 1rem;
    font-size: 0.95rem;
    box-shadow: 0 4px 12px rgba(212, 11, 11, 0.3);
}

.promo-banner-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.promo-icon {
    width: 18px;
    height: 18px;
    animation: pulse 2s infinite;
}

.promo-countdown {
    font-family: monospace;
    font-size: 1.1rem;
    font-weight: 700;
    background: rgba(0,0,0,0.2);
    padding: 0.2rem 0.5rem;
    border-radius: 6px;
    margin-left: 0.5rem;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); }
    100% { transform: scale(1); }
}

/* ─── HEADER ─────────────────────────────────────────────── */
.glass-header {
    position: sticky;
    top: 0;
    z-index: 2000;
    background: rgba(255,255,255,0.96);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.header-inner {
    display: flex;
    position: relative;
    z-index: 20000;
    align-items: center;
    justify-content: space-between;
    padding: 0.2rem 2rem;
    min-height: 64px;
    gap: 1.5rem;
}

/* Logo */
.logo { display: flex; align-items: center; }
.logo img { 
    height: 48px; 
    width: auto; 
    object-fit: contain; 
    display: block; 
    filter: drop-shadow(2px 2px 0px rgba(0, 0, 0, 0.6));
}
.logo-text {
    align-items: center;
    gap: 0.4rem;
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-900);
    letter-spacing: -0.5px;
}
.logo-dot {
    width: 8px; height: 8px;
    border-radius: var(--radius-full);
    background: var(--accent-blue);
    flex-shrink: 0;
}
.logo-accent { color: var(--accent-blue); }

/* Stats */
.stats {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    background: var(--bg-muted);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    padding: 0.4rem 1.1rem;
    box-shadow: inset 0 1px 3px rgba(15,23,42,0.06);
}
.stat-item { display: flex; flex-direction: column; align-items: center; }
.stat-value {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-900);
    line-height: 1.2;
}
.stat-total { color: var(--text-400); font-weight: 500; }
.stat-label {
    font-size: 0.625rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--text-400);
}
.stat-divider {
    width: 1px; height: 28px;
    background: var(--border);
}

/* Controls */
.mobile-menu-btn {
    display: none;
    background: transparent;
    border: none;
    color: var(--text-900);
    cursor: pointer;
    padding: 0.5rem;
    z-index: 101;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    transition: background 0.2s;
}
.mobile-menu-btn:hover {
    background: var(--bg-subtle);
}
.mobile-menu-btn svg {
    width: 24px;
    height: 24px;
}

.controls, .subpage-controls {
    display: flex;
    gap: 0.6rem;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.auth-actions-wrapper {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

#email-input {
    padding: 0.5rem 0.9rem;
    border-radius: var(--radius-full);
    border: 1px solid var(--border);
    background: var(--bg-subtle);
    color: var(--text-900);
    font-family: var(--font-sans);
    font-size: 0.875rem;
    width: 200px;
    outline: none;
    transition: all 0.2s ease;
}
#email-input::placeholder { color: var(--text-400); }
#email-input:focus {
    background: var(--bg-white);
    border-color: var(--text-900);
    box-shadow: 0 0 0 2px rgba(15,23,42,0.08);
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.5rem 1rem;
    background: var(--text-900);
    color: #fff;
    border: none;
    border-radius: var(--radius-full);
    font-family: var(--font-sans);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: var(--shadow-sm);
    white-space: nowrap;
}
.btn-primary:hover { background: #1e293b; transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-primary:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.btn-ghost {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.5rem 0.9rem;
    background: transparent;
    color: var(--text-500);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    font-family: var(--font-sans);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}
.btn-ghost:hover {
    background: var(--bg-subtle);
    border-color: var(--border-hover);
    color: var(--text-900);
}
.btn-ghost .btn-icon {
    color: #94a3b8;
    transition: color 0.2s;
}
.btn-ghost:hover .btn-icon {
    color: var(--text-900);
}
.btn-icon { width: 14px; height: 14px; flex-shrink: 0; }

/* ─── MAIN LAYOUT ─────────────────────────────────────────── */
main {
    display: grid;
    grid-template-columns: 1fr minmax(450px, 60%);
    gap: 1.75rem;
    padding: 1.75rem 2rem;
    flex: 1;
    align-items: start;
}

/* ─── MAP SECTION ─────────────────────────────────────────── */
.mobile-map-label {
    display: none;
}

.map-section {
    display: flex;
    justify-content: center;
    align-items: center;
    position: sticky;
    top: 80px;
    height: calc(100vh - 120px);
}

#map-container {
    width: 100%;
    max-width: 680px;
    padding: 16px;
    filter: drop-shadow(0 8px 24px rgba(15,23,42,0.12));
}
#map-container svg { 
    overflow: visible; 
    width: 100%; 
    height: auto; 
    max-height: 60vh;
}

/* ─── TOOLTIP ─────────────────────────────────────────────── */
#tooltip {
    position: absolute;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.85rem 1rem;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s ease;
    z-index: 50;
    transform: translate(-50%, -115%);
    box-shadow: var(--shadow-lg);
    min-width: 155px;
}

@media (hover: none) and (pointer: coarse) {
    #tooltip { display: none !important; }
}
#tooltip h3 { font-family: var(--font-heading); font-size: 1rem; font-weight: 700; margin-bottom: 0.3rem; color: var(--text-900); }
#tooltip p { font-size: 0.8rem; color: var(--text-500); margin-bottom: 0.15rem; }
#tooltip .status { margin-top: 0.4rem; font-weight: 600; font-size: 0.8rem; }
.status.locked { color: #ef4444; }
.status.unlocked { color: var(--accent-emerald); }

/* ─── SIDEBAR ─────────────────────────────────────────────── */
.sidebar {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    height: calc(100vh - 100px);
    overflow-y: auto;
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 80px;
}
.sidebar::-webkit-scrollbar { width: 5px; }
.sidebar::-webkit-scrollbar-track { background: transparent; }
.sidebar::-webkit-scrollbar-thumb { background: var(--border); border-radius: var(--radius-full); }

#sidebar-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.25rem;
    padding: 0;
    height: 100%;
}

.mobile-close-btn { display: none; }

.slogan-container {
    text-align: center;
    max-width: 650px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

.slogan-main {
    font-family: var(--font-heading);
    font-size: 2.75rem;
    font-weight: 700;
    color: var(--text-900);
    line-height: 1.2;
    letter-spacing: -0.01em;
    margin-bottom: 1rem;
}

.slogan-sub {
    font-size: 1.35rem;
    font-weight: 500;
    color: var(--text-700);
    line-height: 1.5;
    letter-spacing: 0.01em;
    margin-bottom: 2rem;
}

.slogan-footer {
    font-size: 0.95rem;
    color: var(--text-500);
    line-height: 1.7;
    letter-spacing: 0.02em;
    max-width: 500px;
    margin: 0 auto;
}

.slogan-container .highlight-red {
    color: #ef4444;
    font-weight: 700;
}

.sidebar-home {
    width: 100%;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-900);
    box-shadow: var(--shadow-sm);
    margin-bottom: 0.5rem;
    align-self: center;
}
.hero-badge svg {
    width: 14px;
    height: 14px;
    stroke-width: 2.2px;
    color: var(--text-500);
}

.hero-title {
    font-family: var(--font-heading);
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--text-900);
    line-height: 1.2;
    letter-spacing: -0.01em;
    margin-bottom: 0.5rem;
    text-align: center;
}

.hero-subtitle {
    font-size: 0.95rem;
    color: var(--text-500);
    line-height: 1.65;
    letter-spacing: 0.015em;
    margin-bottom: 1.5rem;
    max-width: 90%;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

.tabs-container {
    display: flex;
    gap: 0.5rem;
    background: var(--bg-muted);
    padding: 0.4rem;
    border-radius: var(--radius-full);
    margin-bottom: 1rem;
    align-self: center;
}

.tab-btn {
    padding: 0.5rem 1.2rem;
    border: none;
    background: transparent;
    border-radius: var(--radius-full);
    font-family: var(--font-sans);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-500);
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.tab-btn svg {
    width: 16px;
    height: 16px;
    stroke-width: 2.2px;
}

.tab-btn.active {
    background: var(--bg-white);
    color: var(--text-900);
    box-shadow: var(--shadow-sm);
}

.filters-bar {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.search-input-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: border-color 0.2s ease;
}

.search-input-wrapper:focus-within {
    border-color: var(--text-900);
}

.search-input-wrapper input {
    border: none;
    background: transparent;
    outline: none;
    width: 100%;
    font-family: var(--font-sans);
    font-size: 0.875rem;
    color: var(--text-900);
}

.search-input-wrapper input::placeholder {
    color: var(--text-400);
}

.search-icon {
    width: 16px;
    height: 16px;
    color: var(--text-400);
}

.filter-select {
    padding: 0.6rem 2rem 0.6rem 1rem;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-family: var(--font-sans);
    font-size: 0.875rem;
    color: var(--text-500);
    outline: none;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.7rem center;
    background-size: 1em;
}

.list-header {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-400);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
}

.attraction-card-horizontal {
    display: flex;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 1rem;
    transition: all 0.25s ease;
    box-shadow: var(--shadow-sm);
    text-decoration: none;
    color: inherit;
    height: 260px;
}

.attraction-card-horizontal:hover {
    border-color: var(--border-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.card-content-side {
    flex: 1;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.tag-region {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: #ef4444;
    background: #fef2f2;
    padding: 0.2rem 0.5rem;
    border-radius: var(--radius-full);
}

.meta-icon {
    width: 12px;
    height: 12px;
}

.tag-category {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-500);
}

.card-content-side h4 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-900);
    margin-bottom: 0.4rem;
    line-height: 1.3;
}

.card-content-side p {
    font-size: 0.85rem;
    color: var(--text-500);
    line-height: 1.5;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.card-footer-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
}

.duration {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-500);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.duration svg, .tag-region svg {
    width: 14px;
    height: 14px;
    stroke-width: 2.2px;
}

/* ============================================================
   Locked Trips Blur Preview (Przed zakupem)
   ============================================================ */
.locked-trips-preview-wrapper {
    position: relative;
    border-radius: 16px;
    margin-top: 1.5rem;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid #e2e8f0;
    background: #fafafa;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

.locked-trips-preview-wrapper:hover {
    border-color: #cbd5e1;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
    transform: translateY(-2px);
}

.locked-trips-blur-content {
    filter: blur(6px);
    opacity: 0.45;
    user-select: none;
    pointer-events: none;
    padding: 0.75rem;
    max-height: 420px;
    overflow: hidden;
}

.locked-trips-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.92);
    padding: 1.5rem;
    text-align: center;
    z-index: 10;
}

.locked-overlay-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: #eef2ff;
    color: #4f46e5;
    border: 1px solid #c7d2fe;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.3rem 0.8rem;
    border-radius: 9999px;
    margin-bottom: 0.75rem;
}

.locked-overlay-title {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 0.4rem;
    line-height: 1.3;
}

.locked-overlay-desc {
    font-size: 0.85rem;
    color: #475569;
    margin-bottom: 1.25rem;
    max-width: 320px;
    line-height: 1.4;
}

.locked-overlay-btn {
    background: #635bff;
    color: #ffffff;
    font-weight: 700;
    padding: 0.85rem 1.6rem;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(99, 91, 255, 0.35);
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem;
}

.locked-overlay-btn:hover {
    background: #5247e6;
    transform: scale(1.03);
    box-shadow: 0 6px 20px rgba(99, 91, 255, 0.45);
}


.details-link {
    color: var(--text-900);
    font-weight: 600;
    text-decoration: none;
}
.btn-map-green svg {
    width: 16px;
    height: 16px;
    stroke-width: 2.2px;
}

.card-image-side {
    width: 40%;
    min-width: 220px;
    flex-shrink: 0;
    background: var(--bg-muted);
}

.card-image-side img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#sidebar-content { display: none; flex-direction: column; gap: 1.25rem; }
#sidebar-content.active { display: flex; }

/* ─── REGION HEADER ───────────────────────────────────────── */
.region-header h2 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--text-900);
    margin-bottom: 0.2rem;
}
.region-header p { font-size: 0.875rem; color: var(--text-500); }

/* ─── PURCHASE / UNLOCK SECTION ───────────────────────────── */
.purchase-section {
    background: var(--bg-subtle);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.35rem;
    text-align: center;
}
.purchase-section h3 {
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-900);
    margin-bottom: 0.4rem;
}
.purchase-section p { font-size: 0.875rem; color: var(--text-500); margin-bottom: 1rem; line-height: 1.6; }

.glass-white-section {
    background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 100%);
    border: 1px solid rgba(16,185,129,0.2);
}
.glass-white-section h3 { color: #065f46 !important; }
.glass-white-section p { color: #047857 !important; }

/* ─── BUTTONS ─────────────────────────────────────────────── */
.btn-buy {
    background: var(--text-900);
    color: #fff;
    border: none;
    padding: 0.7rem 1.5rem;
    border-radius: var(--radius-full);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    font-family: var(--font-sans);
    box-shadow: var(--shadow-sm);
}
.btn-buy:hover { background: #1e293b; transform: translateY(-1px); box-shadow: var(--shadow-md); }

.btn-map-green {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 0.75rem;
    padding: 0.75rem 1.25rem;
    background: var(--accent-emerald);
    color: white;
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    font-family: var(--font-sans);
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(16,185,129,0.25);
}
.btn-map-green:hover { background: #059669; transform: translateY(-1px); box-shadow: 0 6px 20px rgba(16,185,129,0.35); }

.btn-stripe {
    background: linear-gradient(135deg, var(--accent-stripe) 0%, #4f46e5 100%);
    box-shadow: 0 4px 14px rgba(99,91,255,0.30);
}
.btn-stripe:hover:not(:disabled) {
    background: linear-gradient(135deg, #7c75ff 0%, var(--accent-stripe) 100%);
    box-shadow: 0 6px 20px rgba(99,91,255,0.45);
}
.btn-stripe:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

/* ─── ATTRACTION CARDS ────────────────────────────────────── */
.attractions-list { display: flex; flex-direction: column; gap: 0.75rem; }

.attraction-card {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all 0.25s ease;
    box-shadow: var(--shadow-sm);
}
.attraction-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.article-card-link { text-decoration: none; color: inherit; display: block; }

.card-image { width: 100%; height: 140px; position: relative; overflow: hidden; background: var(--bg-muted); }
.card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s ease; }
.attraction-card:hover .card-image img { transform: scale(1.03); }

.locked-blur { filter: blur(8px) grayscale(40%); }

.card-image-placeholder {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    background: var(--bg-muted);
    font-size: 2rem;
}

.card-content { padding: 0.85rem 1rem; }
.card-content h4 {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-900);
    margin-bottom: 0.25rem;
    line-height: 1.3;
}

.card-details { display: flex; justify-content: space-between; font-size: 0.8rem; color: var(--text-500); margin-bottom: 0.4rem; }

.article-date-tag {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-400);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 0.2rem 0 0.35rem;
}

.article-excerpt-text {
    font-size: 0.8rem;
    color: var(--text-500);
    line-height: 1.5;
    margin-bottom: 0.5rem;
}

.read-more-inline {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent-blue);
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    transition: gap 0.2s ease;
}
.attraction-card:hover .read-more-inline { gap: 0.45rem; }

.card-hint {
    font-size: 0.8rem;
    color: var(--accent-emerald);
    background: rgba(16,185,129,0.08);
    border: 1px solid rgba(16,185,129,0.15);
    padding: 0.4rem 0.6rem;
    border-radius: var(--radius-sm);
    display: none;
}
.unlocked-view .card-hint { display: block; }

/* ─── LOADING STATES ──────────────────────────────────────── */
.articles-loading { text-align: center; padding: 2.5rem 1rem; color: var(--text-400); }

.loading-spinner {
    width: 32px; height: 32px;
    border: 2.5px solid var(--border);
    border-top-color: var(--text-900);
    border-radius: var(--radius-full);
    margin: 0 auto 0.75rem;
    animation: spin 0.75s linear infinite;
}
.articles-loading p { font-size: 0.85rem; }

@keyframes spin { to { transform: rotate(360deg); } }

.articles-empty {
    text-align: center; padding: 1.75rem 1rem;
    color: var(--text-500); font-size: 0.875rem;
    background: var(--bg-subtle);
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
}
.articles-empty.error-state { border-color: rgba(239,68,68,0.2); background: rgba(239,68,68,0.04); color: #b91c1c; }
.articles-empty span { display: block; margin-top: 0.4rem; }



/* ─── CUSTOM MODAL ────────────────────────────────────────── */
#custom-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15,23,42,0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.2s ease;
    padding: 1rem;
}
#custom-modal-overlay.visible { opacity: 1; }
#custom-modal-overlay.visible .custom-modal { transform: scale(1) translateY(0); }

.custom-modal {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 2rem 1.75rem 1.75rem;
    max-width: 380px;
    width: 100%;
    text-align: center;
    box-shadow: var(--shadow-lg);
    transform: scale(0.94) translateY(12px);
    transition: transform 0.28s cubic-bezier(0.34,1.56,0.64,1);
}
.custom-modal-icon { font-size: 2.5rem; margin-bottom: 0.6rem; line-height: 1; }
.custom-modal-title {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-900);
    margin-bottom: 0.4rem;
}
.custom-modal-message {
    font-size: 0.9rem;
    color: var(--text-500);
    line-height: 1.65;
    margin-bottom: 1.5rem;
}
.custom-modal-btn {
    background: var(--accent-stripe);
    color: #ffffff;
    border: none;
    padding: 0.65rem 2.25rem;
    border-radius: var(--radius-full);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    font-family: var(--font-sans);
    transition: all 0.2s ease;
    box-shadow: var(--shadow-sm);
}
.custom-modal-btn:hover { background: #4f46e5; transform: translateY(-1px); box-shadow: var(--shadow-md); }

/* ─── SUCCESS TOAST ───────────────────────────────────────── */
#success-toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--bg-white);
    border: 1px solid rgba(16,185,129,0.3);
    border-radius: var(--radius-lg);
    padding: 0.85rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.85rem;
    z-index: 9999;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    transition: transform 0.4s cubic-bezier(0.34,1.56,0.64,1), opacity 0.3s ease;
    max-width: 380px;
    width: 90%;
}
#success-toast.visible { transform: translateX(-50%) translateY(0); opacity: 1; }
.toast-icon { font-size: 1.75rem; flex-shrink: 0; }
.toast-text { display: flex; flex-direction: column; gap: 0.1rem; }
.toast-text strong { color: var(--accent-emerald); font-size: 0.95rem; font-weight: 700; }
.toast-text span { color: var(--text-500); font-size: 0.85rem; }
.toast-text em { font-style: normal; color: var(--text-900); font-weight: 600; }

/* ─── TRIP MODAL (MARKDOWN) ───────────────────────────────── */
#trip-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15,23,42,0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.25s ease;
    padding: 1.5rem;
}
#trip-modal-overlay.visible { opacity: 1; }

.trip-modal {
    background: radial-gradient(at 0% 0%, rgba(226, 232, 240, 0.4) 0px, transparent 50%), radial-gradient(at 100% 0%, rgba(241, 245, 249, 0.4) 0px, transparent 50%), #f8fafc;
    border-radius: 24px;
    width: 100%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;  /* Firefox */
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
}

.trip-modal::-webkit-scrollbar {
    display: none;
}

#trip-modal-overlay.visible .trip-modal { transform: scale(1) translateY(0); }

.trip-modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: #f1f5f9;
    border: none;
    font-size: 1.5rem;
    color: var(--text-500);
    cursor: pointer;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    z-index: 10;
}
.trip-modal-close:hover { background: #e2e8f0; color: var(--text-900); }

.trip-modal-header {
    background: transparent;
    padding: 2.5rem 3rem 2rem;
    border-bottom: 1px solid rgba(226, 232, 240, 0.6);
    border-top-left-radius: 24px;
    border-top-right-radius: 24px;
}

.trip-badges {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.badge-accent {
    background: #fee2e2;
    color: #ef4444;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.35rem 0.8rem;
    border-radius: var(--radius-full);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.trip-meta-gray {
    color: var(--text-400);
    font-size: 0.85rem;
    font-weight: 600;
}

.trip-title {
    font-family: var(--font-heading);
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--text-900);
    line-height: 1.2;
    margin-bottom: 1rem;
    letter-spacing: -0.04em;
    padding-right: 2rem;
}

.trip-desc {
    color: var(--text-500);
    font-size: 1.05rem;
    line-height: 1.6;
}

.trip-modal-content {
    padding: 1.5rem 3rem 3rem;
}

.trip-section-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-400);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    margin-top: 1rem;
}

.trip-section-title:first-child {
    margin-top: 0;
}

.red-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background-color: #ef4444;
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.5);
}

.trip-day-card {
    background: rgba(255, 255, 255, 0.98);
    /* Usunięto backdrop-filter ze względu na wyciek wydajności CPU */
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.8);
    padding: 1.75rem 2.25rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 24px -1px rgba(0, 0, 0, 0.04), 0 0 1px 0 rgba(0,0,0,0.06);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.3s ease;
    overflow: hidden;
}

.trip-day-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
    border-color: rgba(255, 255, 255, 1);
}

.trip-day-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.badge-red {
    background: #dc2626;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 800;
    padding: 0.35rem 0.8rem;
    border-radius: var(--radius-full);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-glass-red {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.2);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.35rem 0.8rem;
    border-radius: var(--radius-full);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.day-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-900);
}

.trip-step {
    padding-top: 1.5rem;
    margin-top: 1.5rem;
    border-top: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}

.trip-step:first-of-type {
    padding-top: 0;
    margin-top: 0;
    border-top: none;
}

.step-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}


.step-time {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    font-weight: 700;
    color: #ef4444;
}

.step-transport {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-400);
}

.step-transport svg {
    width: 14px;
    height: 14px;
}

.step-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-900);
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.step-desc {
    font-size: 0.95rem;
    color: var(--text-500);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.step-desc strong {
    color: var(--text-900);
    font-weight: 600;
}

.step-desc a {
    color: var(--accent-blue);
    text-decoration: none;
    font-weight: 500;
}

.step-desc a:hover {
    text-decoration: underline;
}

.recommendation-box {
    background: rgba(240, 253, 244, 0.96);
    /* Usunięto backdrop-filter ze względu na obciążenie CPU */
    border: 1px solid rgba(134, 239, 172, 0.4);
    border-radius: 12px;
    padding: 1rem 1.25rem;
    color: #166534;
    font-size: 0.95rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 1rem;
    box-shadow: 0 4px 12px rgba(22, 101, 52, 0.05);
}

.recommendation-box svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    color: #15803d;
}

.step-image {
    width: 100%;
    max-height: 350px;
    object-fit: cover;
    border-radius: 12px;
    margin: 1rem 0;
}

.markdown-body {
    padding: 0;
    color: var(--text-500);
    line-height: 1.45; /* Bardziej zbity tekst */
}
.markdown-body h1 { 
    font-size: 1.45rem; /* Pomniejszona o kolejne 2pkt */
    line-height: 1.2;
    margin-bottom: 0.5rem; /* Zmniejszony odstęp */
    color: var(--text-900);
}
.markdown-body h2 { 
    font-size: 1.15rem; /* Pomniejszona o kolejne 2pkt */
    margin-top: 0.8rem; /* Zmniejszony odstęp */
    margin-bottom: 0.4rem; /* Zmniejszony odstęp */
    color: var(--text-900);
}
.markdown-body h3, .markdown-body h4 { 
    font-size: 1rem; /* Pomniejszona o kolejne 2pkt */
    color: var(--text-900); 
    margin-top: 0.8rem; /* Zmniejszony odstęp */
    margin-bottom: 0.3rem; /* Zmniejszony odstęp */
}
.markdown-body p, .markdown-body li { 
    font-size: 0.84rem; /* Zmniejszona czcionka ogólna */
    margin-bottom: 0.5rem; /* Zmniejszony odstęp w paragrafach */
    line-height: 1.45;
}
/* Plan zwiedzania (Godziny) - odchudzone (niepogrubione) i mniejsze */
.markdown-body li strong {
    font-weight: 500;
    font-size: 0.85em; /* Zmniejszone */
    color: var(--text-900);
}
.markdown-body ul { padding-left: 1.2rem; margin-bottom: 0.75rem; }
.markdown-body a { color: var(--accent-blue); text-decoration: none; font-weight: 500; }
.markdown-body a:hover { text-decoration: underline; }

/* Przycisk Google Maps (Pigułka po prawej stronie) */
.markdown-body a.btn-map-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #eef2ff;
    color: #635bff;
    padding: 0.35rem 0.85rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid #c7d2fe;
    transition: all 0.2s ease;
    margin: 0;
    float: right;
}
.markdown-body a.btn-map-pill:hover {
    background: #635bff;
    color: #ffffff;
    border-color: #635bff;
    text-decoration: none;
}
/* Clearfix dla paragrafow by float dzialal poprawnie */
.markdown-body p.step-desc::after {
    content: "";
    display: table;
    clear: both;
}

.markdown-body img { box-shadow: var(--shadow-sm); max-width: 100%; border-radius: 8px; margin: 1rem 0; }

/* ─── RESPONSIVE ──────────────────────────────────────────── */
@media (max-width: 1280px) {
    body.map-page {
        overflow: hidden; /* Blokada przewijania całej strony */
    }
    body.map-page main { 
        grid-template-columns: 1fr; 
        height: calc(100vh - 80px);
        overflow: hidden;
        padding: 0; 
        gap: 0;
    }
    .map-section {
        height: 100%;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding: 1rem;
    }
    .mobile-map-label {
        display: inline-flex;
        align-items: center;
        gap: 0.5rem;
        font-family: var(--font-heading);
        font-size: 1.25rem;
        font-weight: 800;
        color: #ef4444;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        margin-bottom: 0.5rem;
        animation: pulse 2s infinite;
        user-select: none;
        pointer-events: none;
    }
    .mobile-map-label svg {
        color: #94a3b8;
        width: 22px;
        height: 22px;
    }
    .sidebar { 
        position: fixed; 
        bottom: 0;
        left: 0;
        width: 100%;
        height: 85vh; 
        z-index: 1000;
        transform: translateY(100%);
        transition: transform 0.35s cubic-bezier(0.32, 0.72, 0, 1);
        border-radius: 24px 24px 0 0;
        box-shadow: 0 -4px 24px rgba(0,0,0,0.15);
        padding: 2rem 1.5rem 3rem 1.5rem;
        overflow-y: auto;
    }
    .sidebar.bottom-sheet-open {
        transform: translateY(0);
    }
    
    /* Pasek - uchwyt na górze sidebaru */
    .sidebar::before {
        content: '';
        position: absolute;
        top: 12px;
        left: 50%;
        transform: translateX(-50%);
        width: 40px;
        height: 5px;
        background: var(--border);
        border-radius: 10px;
    }
    
    .mobile-close-btn {
        display: flex;
        position: absolute;
        top: 12px;
        right: 15px;
        background: var(--bg-muted);
        border: 1px solid var(--border);
        width: 30px;
        height: 30px;
        border-radius: 50%;
        font-size: 1.2rem;
        color: var(--text-500);
        cursor: pointer;
        z-index: 1001;
        align-items: center;
        justify-content: center;
        line-height: 1;
        box-shadow: var(--shadow-sm);
    }
    
    .stats { display: none; }
    
    .attraction-card-horizontal {
        flex-direction: column;
        height: auto;
    }
    .card-image-side {
        width: 100%;
        height: 220px;
    }
}

@media (max-width: 1024px) {
    .mobile-menu-btn {
        display: flex;
    }
    .controls {
        display: none;
        position: absolute;
        top: 100%;
        right: 1rem;
        background: rgba(255, 255, 255, 0.98);
        border: 1px solid var(--border);
        border-radius: var(--radius-md);
        padding: 1rem;
        flex-direction: column;
        gap: 0.75rem;
        box-shadow: var(--shadow-lg);
        min-width: 240px;
        z-index: 10000;
        align-items: stretch;
    }
    .controls.menu-open {
        display: flex;
    }
    .controls .btn-ghost, .controls .btn-primary {
        justify-content: flex-start;
        width: 100%;
    }
    .auth-actions-wrapper, .auth-actions-wrapper button {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .header-inner { padding: 0.5rem 1rem; flex-wrap: wrap; }
    #email-input { width: 100%; max-width: 200px; margin-bottom: 0.5rem; }
    main { padding: 0.5rem; gap: 1.5rem; }
    .hero-title { font-size: 1.8rem; }
    .filters-bar { flex-direction: column; }
    .map-section { min-height: 40vh; }

    /* Modal na pełen ekran dla smartfonów */
    #trip-modal-overlay { padding: 0; }
    .trip-modal {
        border-radius: 0;
        max-width: 100%;
        width: 100%;
        max-height: 100vh;
        height: 100vh;
    }
    
    /* Pasek - uchwyt na górze modala do swipowania */
    .trip-modal::before {
        content: '';
        position: absolute;
        top: 12px;
        left: 50%;
        transform: translateX(-50%);
        width: 36px;
        height: 4px;
        background: #cbd5e1;
        border-radius: 4px;
        z-index: 10;
    }
    
    .trip-modal-close {
        top: max(1.8rem, env(safe-area-inset-top));
        right: 1rem;
    }
    .trip-modal-header {
        padding: 1.5rem 1.25rem 1rem;
        border-radius: 0;
    }
    .trip-modal-content {
        padding: 0 0 2rem 0;
    }
    .trip-day-card {
        border-radius: 0;
        border-left: none;
        border-right: none;
        padding: 1.5rem 1.25rem;
        margin-bottom: 0.5rem;
    }
}

/* ============================================================
   Nowe Etykiety: Freemium i VIP (Klub Odkrywców)
   ============================================================ */
.tag-free-trial {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.75rem;
    font-weight: 700;
    color: #059669; /* Zielony */
    background: #ecfdf5;
    border: 1px solid #10b981;
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-full);
}

.tag-vip-club {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.75rem;
    font-weight: 700;
    color: #4f46e5; /* Indygowy / Fioletowy */
    background: #eef2ff;
    border: 1px solid #c7d2fe;
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-full);
}

.vip-locked-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255,255,255,0.4);
    z-index: 10;
    pointer-events: none;
}
/* --- DARK MODE UI FIXES --- */
body.dark-theme .controls {
    background: rgba(15, 23, 42, 0.95);
    border-color: var(--border);
}
body.dark-theme .controls .btn-ghost, 
body.dark-theme .controls .btn-primary {
    color: var(--text-900);
}
body.dark-theme .controls .btn-primary {
    background: var(--bg-muted);
}

/* Przycisk Wyloguj / Profil w nav-bar / controls */
body.dark-theme #login-btn {
    background: var(--bg-muted) !important;
    color: var(--text-900) !important;
    border-color: var(--border) !important;
}

/* Karty wycieczek — tło i ramka */
body.dark-theme .attraction-card-horizontal {
    background: var(--bg-white) !important;
    border-color: var(--border) !important;
}

/* Tytuł i opis na karcie */
body.dark-theme .card-content-side h4,
body.dark-theme .card-content-side > h4 {
    color: var(--text-900) !important;
}
body.dark-theme .card-content-side p {
    color: var(--text-500) !important;
}

/* Footer karty (linia + tekst "Województwo") */
body.dark-theme .card-footer-info {
    border-top-color: var(--border) !important;
}
body.dark-theme .card-footer-info span:first-child {
    color: var(--text-500) !important;
}
body.dark-theme .card-footer-info span strong {
    color: var(--text-900) !important;
}

/* Czas trwania */
body.dark-theme .duration {
    color: var(--text-500) !important;
}

/* Badge KLUB ODKRYWCÓW i DARMOWA TRASA PRÓBNA */
body.dark-theme .tag-vip-club {
    background: rgba(99, 91, 255, 0.2) !important;
    color: #a5b4fc !important;
    border-color: rgba(99, 91, 255, 0.35) !important;
}
body.dark-theme .tag-free-trial {
    background: rgba(16, 185, 129, 0.2) !important;
    color: #6ee7b7 !important;
    border-color: rgba(16, 185, 129, 0.3) !important;
}

/* Overlay "Zostań Klubowiczem" (vip-locked-overlay) na zdjęciu */
body.dark-theme .vip-locked-overlay {
    background: rgba(15, 23, 42, 0.55) !important;
}

/* Przycisk "Odblokuj Dostęp" na karcie locked */
body.dark-theme .attraction-card-horizontal span.btn-primary[style*="4f46e5"] {
    background: #635bff !important;
    color: #fff !important;
    border-color: #635bff !important;
}

/* Przycisk "Zobacz Propozycję" — standardowy */
body.dark-theme .attraction-card-horizontal .btn-primary,
body.dark-theme .attraction-card-horizontal .btn-white,
body.dark-theme .trip-day-card .btn-primary,
body.dark-theme .trip-card .btn-primary,
body.dark-theme .trip-card .btn-white {
    background: var(--bg-muted) !important;
    color: var(--text-900) !important;
    border: 1px solid var(--border) !important;
}

/* --- DARK MODE UI FIXES FOR TRIP MODAL --- */
body.dark-theme .trip-modal,
body.dark-theme .trip-modal-content {
    background: var(--bg-white) !important;
}
body.dark-theme .trip-modal-header {
    background: var(--bg-subtle) !important;
    border-bottom: 1px solid var(--border) !important;
}
body.dark-theme .trip-modal-header * {
    color: var(--text-900) !important;
}
body.dark-theme .trip-modal-header .badge-accent {
    background: rgba(239, 68, 68, 0.2) !important;
    color: #fca5a5 !important;
}
body.dark-theme .trip-day-card {
    background: var(--bg-white) !important;
    border-color: var(--border) !important;
}
body.dark-theme .trip-day-header {
    border-bottom: 1px solid var(--border) !important;
}
body.dark-theme .trip-day-header * {
    color: var(--text-900) !important;
}
body.dark-theme .markdown-body p, 
body.dark-theme .markdown-body li, 
body.dark-theme .markdown-body em, 
body.dark-theme .markdown-body strong, 
body.dark-theme .markdown-body h1, 
body.dark-theme .markdown-body h2, 
body.dark-theme .markdown-body h3, 
body.dark-theme .markdown-body h4 {
    color: var(--text-900) !important;
}
body.dark-theme .markdown-body hr {
    border-bottom: 1px solid var(--border) !important;
}

/* --- DARK MODE UI FIXES FOR ALL MODALS --- */
body.dark-theme .modal-content {
    background: var(--bg-white) !important;
}

body.dark-theme #manage-sub-btn-profile {
    background: var(--bg-muted) !important;
    color: var(--text-900) !important;
    border-color: var(--border) !important;
}

body.dark-theme #profile-heatmap-container {
    background: var(--bg-subtle) !important;
    border-color: var(--border) !important;
}

body.dark-theme .auth-tabs button {
    background: var(--bg-muted) !important;
    color: var(--text-500) !important;
}
body.dark-theme .auth-tabs button.active {
    background: var(--bg-subtle) !important;
    color: var(--text-900) !important;
    border: 1px solid var(--border) !important;
}

body.dark-theme .modal-close {
    background: var(--bg-muted) !important;
    color: var(--text-900) !important;
}

body.dark-theme .plan-option {
    background: var(--bg-subtle) !important;
    border-color: var(--border) !important;
}

/* --- CPU & PERFORMANCE FIX (KILL BLUR OVER VIDEO) --- */
/* Zastąpienie morderczego dla CPU rozmycia na rzecz estetycznego przyciemnienia (Opacity) */
.modal-overlay,
#auth-modal,
#trip-modal-overlay,
.swal2-backdrop-show,
.swal2-container.swal2-backdrop-show {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

body.dark-theme .swal2-popup {
    background: var(--bg-white) !important;
    color: var(--text-900) !important;
    border: 1px solid var(--border) !important;
}
body.dark-theme .swal2-title,
body.dark-theme .swal2-html-container {
    color: var(--text-900) !important;
}
body.dark-theme .swal2-confirm {
    background: var(--bg-muted) !important;
    color: var(--text-900) !important;
}

/* Przyciemniamy warstwę po usunięciu bluru, aby fokus padał na modal */
body.dark-theme .modal-overlay,
body.dark-theme #auth-modal,
body.dark-theme #trip-modal-overlay,
body.dark-theme .swal2-backdrop-show,
body.dark-theme .swal2-container.swal2-backdrop-show {
    background: rgba(15, 23, 42, 0.95) !important;
}

body:not(.dark-theme) .modal-overlay,
body:not(.dark-theme) #auth-modal,
body:not(.dark-theme) #trip-modal-overlay,
body:not(.dark-theme) .swal2-backdrop-show,
body:not(.dark-theme) .swal2-container.swal2-backdrop-show {
    background: rgba(15, 23, 42, 0.70) !important;
}

/* --- SWEETALERT CONFIRM BUTTON DARK MODE FIX --- */
body.dark-theme .swal2-actions button,
body.dark-theme button.swal2-confirm.swal2-styled {
    background-color: var(--bg-subtle) !important;
    background-image: none !important;
    color: var(--text-900) !important;
    border: 1px solid var(--border) !important;
}
body.dark-theme button.swal2-confirm.swal2-styled:hover {
    background-color: var(--bg-muted) !important;
}
