:root {
–bg-color: #000000;
–card-bg: #191919;
–input-bg: #333333;
–text-main: #ffffff;
–text-dim: #8e8e93;
–accent: #0a84ff;
–border: #666666;
–list-bg: #252525;
–am-color: #fa243c;
}

body.light-mode {
–bg-color: #e5e5ea;
–card-bg: #ffffff;
–input-bg: #d1d1d6;
–text-main: #000000;
–text-dim: #636366;
–border: #c7c7cc;
–list-bg: #f2f2f7;
background-color: #e5e5ea !important;
color: #000000 !important;
}

body {
font-family: -apple-system, BlinkMacSystemFont, “Segoe UI”, Roboto, sans-serif;
background-color: var(–bg-color);
color: var(–text-main);
margin: 0;
padding: 20px;
padding-bottom: 100px;
line-height: 1.5;
transition: background-color 0.3s ease;
-webkit-text-size-adjust: 100%;
}

.container { max-width: 600px; margin: 0 auto; position: relative; }

/* ===================== */
/* FLOATING DOCK         */
/* ===================== */
.floating-dock {
position: fixed;
bottom: 20px;
bottom: calc(20px + env(safe-area-inset-bottom));
left: 50%;
transform: translateX(-50%);
z-index: 1000;
display: flex;
align-items: center;
gap: 14px;
padding: 10px 16px;
background: rgba(28, 28, 30, 0.82);
backdrop-filter: blur(24px) saturate(180%);
-webkit-backdrop-filter: blur(24px) saturate(180%);
border: 1px solid rgba(255, 255, 255, 0.1);
border-radius: 26px;
box-shadow: 0 8px 30px rgba(0, 0, 0, 0.45);
transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
white-space: nowrap;
max-width: calc(100vw - 40px);
}

body.light-mode .floating-dock {
background: rgba(240, 240, 245, 0.88);
border-color: rgba(0, 0, 0, 0.08);
box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

@media (min-width: 768px) {
.floating-dock {
max-width: 400px;
}
}

@media (display-mode: standalone) {
.floating-dock {
bottom: calc(18px + env(safe-area-inset-bottom));
}
body {
padding-bottom: calc(100px + env(safe-area-inset-bottom));
}
}

.dock-btn {
width: 36px;
height: 36px;
flex-shrink: 0;
display: flex;
align-items: center;
justify-content: center;
background: rgba(255, 255, 255, 0.07);
border: 1px solid rgba(255, 255, 255, 0.1);
border-radius: 12px;
cursor: pointer;
opacity: 0.8;
transition: opacity 0.2s ease, border-color 0.2s ease, background 0.2s ease;
text-decoration: none;
}

body.light-mode .dock-btn {
background: rgba(0, 0, 0, 0.05);
border-color: rgba(0, 0, 0, 0.1);
}

.dock-btn:hover {
opacity: 1;
border-color: var(–accent);
}

.dock-btn img {
width: 17px;
height: 17px;
display: block;
}

.dock-update {
flex: 1;
text-align: center;
font-size: 0.68rem;
color: #ff9500;
font-weight: 600;
letter-spacing: 0.3px;
min-width: 0;
padding: 0 4px;
}

/* ===================== */
/* END FLOATING DOCK     */
/* ===================== */

.info-link, .theme-switch {
position: absolute; top: 15px; z-index: 1000; cursor: pointer;
width: 30px !important; height: 30px !important;
opacity: 0.6; transition: all 0.2s ease;
border: 1px solid var(–border); border-radius: 8px;
display: flex; align-items: center; justify-content: center;
background: var(–card-bg); box-sizing: border-box;
}
.info-link { left: 15px; }
.theme-switch { right: 15px; }
.info-link:hover, .theme-switch:hover { opacity: 1; border-color: var(–accent); }
.info-link img, .theme-switch img { width: 16px !important; height: 16px !important; display: block; }

.radar-container {
background: #101010; border: 1px solid var(–border); border-radius: 20px;
padding: 15px; margin: 0 auto 40px auto; max-width: 450px;
box-shadow: 0 4px 20px rgba(0,0,0,0.3); box-sizing: border-box; text-align: center;
}
.radar-header {
font-size: 0.7rem; color: #ff9500; text-transform: uppercase; letter-spacing: 1.5px;
font-weight: bold; display: flex; align-items: center; justify-content: center; gap: 6px; margin-bottom: 5px;
}
.radar-icon-img { height: 12px; width: auto; }
.radar-list { display: none; flex-direction: column; gap: 10px; margin-top: 15px; text-align: left; width: 100%; }

.radar-item {
display: flex; align-items: center; justify-content: space-between; padding: 10px 12px;
background: #303030; border-radius: 14px;
border: 1px solid rgba(255, 255, 255, 0.05); width: 100%; box-sizing: border-box;
overflow: hidden;
}

.radar-title {
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
max-width: 100%;
}

.radar-empty { font-size: 0.75rem; color: var(–text-dim); padding: 10px; font-style: italic; }

.hs-grid { display: grid; grid-template-columns: 1fr; gap: 20px; margin-top: 20px; }
@media (min-width: 768px) { .container { max-width: 1000px; } .hs-grid { grid-template-columns: 1fr 1fr; } }
header { text-align: center; padding: 20px 0 40px; }
header h1 { margin: 0; font-size: 1.8rem; letter-spacing: -0.5px; display: flex; align-items: center; justify-content: center; }
.title-icon { height: 1.0em; width: auto; margin-left: 12px; border-radius: 20%; }

.update-tag {
display: inline-block; background: var(–input-bg); padding: 5px 15px;
border-radius: 20px; font-size: 0.85rem; color: #ff9500; border: 1px solid var(–border); text-align: center;
}
.hs-card { background: var(–card-bg); border-radius: 16px; overflow: hidden; border: 1px solid var(–border); height: fit-content; }
.hs-header { display: flex; padding: 15px; border-bottom: 1px solid var(–border); align-items: center; }
.clickable-cover { width: 75px; height: 75px; border-radius: 10px; margin-right: 15px; object-fit: cover; background-color: var(–input-bg); cursor: pointer; }
.hs-title-area { flex: 1; }
.hs-title-area h3 { margin: 0; font-size: 1.15rem; line-height: 1.2; }
.am-icon { width: 13px; height: 13px; margin-right: 6px; display: inline-block; vertical-align: middle; }
.apple-link { color: #ff375f; text-decoration: none; font-size: 0.85rem; display: flex; align-items: center; margin-top: 6px; }

.serie-stats {
font-size: 0.7rem;
color: var(–text-dim);
margin-top: 4px;
opacity: 0.8;
font-family: Arial, Helvetica, sans-serif;
letter-spacing: 0.3px;
}

.folgen-liste { padding: 5px 15px; background: var(–list-bg); }

.folge-item {
font-size: 1.0rem;
padding: 10px 0;
border-bottom: 1px solid var(–border);
display: flex;
align-items: center;
white-space: nowrap;
overflow: hidden;  
}

.label-text {
font-size: 0.9rem;
opacity: 0.6;
margin-right: 4px;
letter-spacing: -0.2px;
flex-shrink: 0;
}

.icon {
margin-right: 6px;
color: var(–accent);
font-size: 0.7rem;
flex-shrink: 0;
}

.folge-item:last-child { border-bottom: none; }
.folge-hidden { display: none; }

footer { text-align: center; margin: 40px 0 60px; font-size: 0.7rem; color: var(–text-dim); }
.footer-badge { display: inline-block; margin-top: 8px; padding: 3px 10px; border: 1px solid var(–border); border-radius: 10px; margin-bottom: 15px; }
.webapp-status-icon { width: 64px; height: auto; margin-top: 10px; opacity: 0.8; cursor: pointer; transition: opacity 0.2s; }
.webapp-status-icon:hover { opacity: 1; }

.ios-back-button {
display: inline-block; background: #00b0ba; color: #ffffff !important;
padding: 8px 20px; border-radius: 20px; text-decoration: none;
font-size: 0.85rem; border: 1px solid var(–border); margin-bottom: 10px;
}
.design-button { display: inline-block; padding: 12px 24px; border-radius: 12px; text-decoration: none; font-size: 0.9rem; font-weight: 600; color: #ffffff !important; }
.am-btn { background: #fa243c !important; box-shadow: 0 4px 12px rgba(250, 36, 60, 0.3); color: #ffffff !important; }

.expand-btn, .radar-toggle-btn {
text-align: center; font-size: 0.75rem; color: var(–text-dim); padding: 10px 0;
cursor: pointer; display: flex; justify-content: center; align-items: center; gap: 8px;
}
.arrow { display: inline-block; transition: transform 0.3s ease; font-size: 0.6rem; }
.expanded .arrow { transform: rotate(180deg); }
.animate-open { animation: slideFade 0.3s ease-out forwards; transform-origin: top; }
@keyframes slideFade { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }

.modal { display: none; position: fixed; z-index: 2000; left: 0; top: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.95); justify-content: center; align-items: center; cursor: pointer; }
.modal-content { width: 512px; max-width: 90%; height: auto; border-radius: 20px; box-shadow: 0 10px 40px rgba(0,0,0,0.5); }

.sheet-overlay {
position: fixed;
top: 0; left: 0;
width: 100%; height: 100%;
background: rgba(0, 0, 0, 0.5);
z-index: 3000;
display: flex;
flex-direction: column;
justify-content: flex-end;
opacity: 0;
visibility: hidden;
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sheet-overlay.active {
opacity: 1;
visibility: visible;
}

.bottom-sheet {
background: #e5e5e5 !important;
width: 100%;
max-width: 600px;
margin: 0 auto;
border-radius: 30px 30px 0 0;
padding: 12px 20px calc(20px + env(safe-area-inset-bottom));
transform: translateY(100%);
transition: transform 0.4s cubic-bezier(0.17, 0.84, 0.44, 1);
box-sizing: border-box;
border: none;
}

.sheet-overlay.active .bottom-sheet {
transform: translateY(0);
}

.sheet-handle {
width: 40px;
height: 5px;
background: rgba(0,0,0,0.2);
border-radius: 3px;
margin: 0 auto 15px;
}

.sheet-content {
display: flex;
flex-direction: column;
align-items: center;
text-align: center;
}

.install-img {
width: 100%;
max-width: 400px;
height: auto;
border-radius: 15px;
margin-bottom: 20px;
}

.sheet-close-btn {
width: 100%;
background: #00b0ba;
color: white;
border: none;
padding: 16px;
border-radius: 12px;
font-size: 1.1rem;
font-weight: 600;
cursor: pointer;
-webkit-tap-highlight-color: transparent;
}

.sheet-close-btn:active {
opacity: 0.8;
}

@media (prefers-color-scheme: dark) {
.bottom-sheet {
background: #CACACA !important;
}
}

.info-container { background: var(–card-bg); padding: 30px; border-radius: 24px; border: 1px solid var(–border); margin-top: 20px; text-align: left; }
.info-container h2 { margin-top: 0; color: var(–accent); font-size: 1.4rem; }
.info-container p { font-size: 0.95rem; color: var(–text-main); opacity: 0.9; }
.info-section { margin-bottom: 25px; }
.info-label { font-size: 0.7rem; text-transform: uppercase; color: var(–text-dim); letter-spacing: 1px; margin-bottom: 8px; display: block; }

/* Explicit light-mode overrides for cards and containers */
body.light-mode .hs-card {
background: #ffffff;
border-color: #d1d1d6;
}
body.light-mode .hs-header {
border-bottom-color: #d1d1d6;
}
body.light-mode .folgen-liste {
background: #f9f9fb;
}
body.light-mode .folge-item {
border-bottom-color: #d1d1d6;
}
body.light-mode .radar-container {
background: #ffffff;
border-color: #d1d1d6;
}
body.light-mode .radar-item {
background: rgba(0, 0, 0, 0.02);
border-color: rgba(0, 0, 0, 0.06);
}

/* Explicit dark-mode overrides - guarantee card colors regardless of var resolution */
body:not(.light-mode) .hs-card {
background: #3a3a3a !important;
border: 1px solid #666666 !important;
}
body:not(.light-mode) .hs-header {
border-bottom: 1px solid #666666 !important;
}
body:not(.light-mode) .folgen-liste {
background: #252525 !important;
}
body:not(.light-mode) .folge-item {
border-bottom: 1px solid #555555 !important;
}
body:not(.light-mode) .radar-container {
background: #3a3a3a !important;
border: 1px solid #666666 !important;
}