/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-app: #0B0B0E;
    --bg-section: #121217;
    --bg-overlay: rgba(0,0,0,0.6);
    --text-primary: #FFFFFF;
    --text-secondary: #B3B3B8;
    --text-tertiary: #7A7A85;
    --text-accent: #F5C26B;
    --text-success: #4CAF50;
    --text-danger: #E85B5B;
    --card-bg: linear-gradient(180deg, #1A1A21 0%, #121217 100%);
    --card-border: #1F1F26;
    --card-shadow: 0 8px 24px rgba(0,0,0,0.55);
    --btn-primary-bg: linear-gradient(135deg, #F5C26B 0%, #E4A93A 100%);
    --btn-primary-text: #1A1206;
    --btn-primary-hover: linear-gradient(135deg, #FFD27F 0%, #F0B84A 100%);
    --btn-secondary-bg: #1E1E26;
    --btn-secondary-border: #2A2A33;
    --nav-bg: #0B0B0E;
    --nav-border: #1C1C24;
    --radius-small: 10px;
    --radius-medium: 14px;
    --radius-large: 18px;
    --radius-xl: 22px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: var(--bg-app);
    color: var(--text-primary);
    line-height: 1.6;
    font-weight: 500;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

h1 {
    font-size: clamp(2rem, 5vw, 3rem);
}

h2 {
    font-size: clamp(1.5rem, 4vw, 2.25rem);
}

h3 {
    font-size: clamp(1.25rem, 3vw, 1.75rem);
}

p {
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

a {
    color: var(--text-accent);
    text-decoration: none;
    transition: color 180ms ease-out;
}

a:hover {
    color: var(--text-primary);
}

/* Header */
header {
    background-color: var(--nav-bg);
    border-bottom: 1px solid var(--nav-border);
    position: sticky;
    top: 0;
    z-index: 1000;
}


.header-top {
    border-bottom: 1px solid var(--nav-border);
    position: relative;
}

.header-top-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    position: relative;
}

.logo img {
    height: 60px;
    width: auto;
}

.logo svg {
    height: 60px;
    width: auto;
    display: block;
}

.footer-logo svg {
    height: 50px;
    width: auto;
    display: block;
}

.header-cta {
    display: flex;
    gap: 1rem;
}

.header-nav {
    padding: 0.75rem 0;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    justify-content: center;
    flex-wrap: wrap;
}

.nav-menu a {
    color: var(--text-secondary);
    font-weight: 500;
    transition: color 180ms ease-out;
}

.nav-menu a:hover {
    color: var(--text-primary);
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: var(--text-primary);
    transition: all 180ms ease-out;
}

/* ToC Navigation */
.toc-nav {
    background-color: var(--bg-section);
    border-top: 1px solid var(--nav-border);
    position: sticky;
    top: 0;
    z-index: 999;
}

.toc-nav .container {
    overflow: hidden;
}

.toc-list {
    display: flex;
    list-style: none;
    gap: 1.5rem;
    padding: 0.75rem 0;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.toc-list::-webkit-scrollbar {
    display: none;
}

.toc-list li {
    flex-shrink: 0;
}

.toc-list a {
    color: var(--text-tertiary);
    font-size: 0.9rem;
    white-space: nowrap;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-small);
    transition: all 180ms ease-out;
}

.toc-list a:hover,
.toc-list a.active {
    color: var(--text-accent);
    background-color: rgba(245, 194, 107, 0.1);
}

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: var(--radius-medium);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 180ms ease-out;
    min-width: 60px;
    display: inline-block;
    text-align: center;
}

.btn-primary {
    background: var(--btn-primary-bg);
    color: var(--btn-primary-text);
    box-shadow: 0 6px 16px rgba(245,194,107,0.35);
}

.btn-primary:hover {
    background: var(--btn-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(245,194,107,0.4);
}

.btn-primary:active {
    transform: scale(0.97);
    background: linear-gradient(135deg, #E4A93A 0%, #C98C1E 100%);
}

.btn-secondary {
    background: var(--btn-secondary-bg);
    color: var(--text-primary);
    border: 1px solid var(--btn-secondary-border);
}

.btn-secondary:hover {
    background: #262631;
}

.btn:focus {
    outline: 2px solid rgba(245,194,107,0.8);
    outline-offset: 2px;
}

/* Hero Section */
#hero {
    padding: 3rem 0;
    background-color: var(--bg-section);
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    margin-top: 2rem;
}

.hero-text .lead {
    font-size: 1.25rem;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.reading-time {
    margin-top: 1.5rem;
    color: var(--text-tertiary);
    font-size: 0.9rem;
}

.reading-time-label {
    margin-right: 0.5rem;
}

.reading-time-value {
    font-weight: 600;
    color: var(--text-accent);
}

.hero-image {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.hero-image figure {
    width: 100%;
}

.hero-image img {
    width: 100%;
    height: auto;
    border-radius: var(--radius-large);
}

.hero-cta {
    width: 100%;
    max-width: 300px;
}

.fact-checked {
    margin-top: 2rem;
    text-align: center;
    color: var(--text-tertiary);
    font-size: 0.9rem;
}

/* Games Section */
#games {
    padding: 4rem 0;
    background-color: var(--bg-app);
}

#games h2 {
    text-align: center;
    margin-bottom: 3rem;
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1.5rem;
}

@media (min-width: 1200px) {
    .games-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: 1.5rem;
    }
}

@media (max-width: 1199px) and (min-width: 769px) {
    .games-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.25rem;
    }
}

.game-card {
    position: relative;
    background: var(--gameTiles-background, #14141B);
    border-radius: var(--radius-large);
    overflow: hidden;
    aspect-ratio: 3/2;
    transition: transform 180ms ease-out, box-shadow 180ms ease-out;
    display: flex;
    align-items: center;
    justify-content: center;
    contain: layout style paint;
    padding: 0;
}

.game-card a {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.game-card a {
    width: 100%;
    height: 100%;
    display: block;
    position: relative;
}

.game-card:hover {
    transform: scale(1.03);
    box-shadow: 0 10px 28px rgba(0,0,0,0.65);
}

.game-card img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    transition: transform 180ms ease-out;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

.game-card:hover img {
    transform: scale(1.02);
}

.game-card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.75) 100%);
    padding: 1.5rem;
    opacity: 0;
    transition: opacity 180ms ease-out;
    display: flex;
    justify-content: center;
    z-index: 10;
}

.game-card:hover .game-card-overlay {
    opacity: 1;
}

.game-card-overlay .btn {
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateY(10px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Content Sections */
section[id^="was-ist"],
section[id^="roulettino"],
section[id^="seriositat"],
section[id^="kontakt"],
section[id^="nutzererfahrung"],
section[id^="roulettino-im-vergleich"],
section[id^="sicherheit"],
section[id^="zusammenfassung"],
section[id^="expertenbewertung"] {
    padding: 4rem 0;
    background-color: var(--bg-section);
}

section[id^="was-ist"]:nth-child(even),
section[id^="roulettino"]:nth-child(even),
section[id^="seriositat"]:nth-child(even),
section[id^="kontakt"]:nth-child(even),
section[id^="nutzererfahrung"]:nth-child(even),
section[id^="roulettino-im-vergleich"]:nth-child(even),
section[id^="sicherheit"]:nth-child(even),
section[id^="zusammenfassung"]:nth-child(even),
section[id^="expertenbewertung"]:nth-child(even) {
    background-color: var(--bg-app);
}

section h2 {
    margin-bottom: 2rem;
}

section figure {
    margin: 2rem 0;
    text-align: center;
}

section figure img {
    width: 100%;
    max-width: 800px;
    height: auto;
    border-radius: var(--radius-large);
    margin: 0 auto;
    object-fit: contain;
}

.content {
    margin-top: 2rem;
}

.content h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 2rem 0;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-medium);
    overflow: hidden;
}

thead {
    background: rgba(245, 194, 107, 0.1);
}

th {
    padding: 1rem;
    text-align: left;
    font-weight: 700;
    color: var(--text-primary);
    border-bottom: 1px solid var(--card-border);
}

td {
    padding: 1rem;
    border-bottom: 1px solid var(--card-border);
    color: var(--text-secondary);
}

tbody tr:last-child td {
    border-bottom: none;
}

tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.02);
}

/* Author Section */
#author {
    padding: 3rem 0;
    background-color: var(--bg-section);
}

.author-block {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-large);
    padding: 2rem;
    box-shadow: var(--card-shadow);
}

.author-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.author-info h3 {
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.author-bio {
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.author-updated {
    color: var(--text-tertiary);
    font-size: 0.9rem;
}

/* FAQ Section */
#faq {
    padding: 4rem 0;
    background-color: var(--bg-app);
}

.faq-list {
    margin-top: 2rem;
}

details {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-medium);
    margin-bottom: 1rem;
    padding: 1.5rem;
    box-shadow: var(--card-shadow);
}

summary {
    font-weight: 600;
    color: var(--text-primary);
    cursor: pointer;
    list-style: none;
    padding: 0.5rem 0;
    transition: color 180ms ease-out;
}

summary::-webkit-details-marker {
    display: none;
}

summary::before {
    content: '+ ';
    margin-right: 0.5rem;
    color: var(--text-accent);
    font-weight: 700;
}

details[open] summary::before {
    content: '− ';
}

summary:hover {
    color: var(--text-accent);
}

details[open] summary {
    margin-bottom: 1rem;
}

details p {
    color: var(--text-secondary);
    padding-left: 1.5rem;
}

/* Footer */
footer {
    background-color: var(--bg-section);
    border-top: 1px solid var(--nav-border);
    padding: 3rem 0 1.5rem;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.footer-logo img {
    height: 50px;
    width: auto;
}

.footer-nav ul {
    list-style: none;
}

.footer-nav li {
    margin-bottom: 0.75rem;
}

.footer-nav a {
    color: var(--text-secondary);
    transition: color 180ms ease-out;
}

.footer-nav a:hover {
    color: var(--text-primary);
}

.footer-payments h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.payment-icons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.payment-icon {
    padding: 0.5rem 1rem;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-small);
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.footer-responsible img {
    max-width: 150px;
    height: auto;
    opacity: 0.8;
    transition: opacity 180ms ease-out;
}

.footer-responsible a:hover img {
    opacity: 1;
}

.footer-copyright {
    grid-column: 1 / -1;
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--nav-border);
    color: var(--text-tertiary);
    font-size: 0.9rem;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    background: var(--btn-primary-bg);
    color: var(--btn-primary-text);
    border: none;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: var(--card-shadow);
    z-index: 100;
    transition: all 180ms ease-out;
}

.back-to-top:hover {
    background: var(--btn-primary-hover);
    transform: translateY(-3px);
}

.back-to-top:focus {
    outline: 2px solid rgba(245,194,107,0.8);
    outline-offset: 2px;
}

/* Responsive Design */
@media (max-width: 768px) {
    header {
        position: relative;
    }

    .header-top {
        position: relative;
    }

    .header-top-content {
        flex-wrap: wrap;
        position: relative;
    }

    .header-cta {
        width: 100%;
        justify-content: flex-end;
        margin-top: 1rem;
        position: relative;
        z-index: 1;
    }

    .header-cta .btn {
        flex: 1;
        min-width: 0;
    }

    .header-top .container {
        position: relative;
        overflow: visible;
    }

    .header-top-content {
        overflow: visible;
    }

    .header-nav {
        padding: 0.75rem 0;
    }

    .header-nav .container {
        position: relative;
    }

    .nav-menu {
        display: none;
        flex-direction: column;
        width: 100%;
        gap: 0;
        margin-top: 1rem;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease-out;
    }

    .nav-menu.active {
        display: flex;
        max-height: 1000px;
    }

    .nav-menu li {
        width: 100%;
        border-bottom: 1px solid var(--nav-border);
    }

    .nav-menu a {
        display: block;
        padding: 1rem;
    }

    .mobile-menu-toggle {
        display: flex;
        position: absolute;
        top: 1rem;
        right: 0;
        z-index: 1001;
        background-color: var(--nav-bg);
        border-radius: var(--radius-small);
        padding: 10px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
        outline: none;
        -webkit-tap-highlight-color: transparent;
        pointer-events: auto;
        touch-action: manipulation;
    }

    .mobile-menu-toggle:focus {
        outline: none;
    }

    .mobile-menu-toggle:active {
        outline: none;
    }

    .mobile-menu-toggle:hover {
        cursor: pointer;
    }

    .hero-content {
        grid-template-columns: 1fr;
    }

    .hero-image {
        display: flex;
        flex-direction: column;
    }

    .hero-cta {
        order: -1;
        margin-bottom: 1rem;
    }

    .hero-image figure {
        order: 0;
    }

    .games-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .author-block {
        flex-direction: column;
        text-align: center;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }

    table {
        display: block;
        overflow-x: auto;
    }

    .back-to-top {
        bottom: 1rem;
        right: 1rem;
        width: 45px;
        height: 45px;
        font-size: 1.25rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .games-grid {
        grid-template-columns: 1fr;
        overflow-x: auto;
        display: flex;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
    }

    .game-card {
        min-width: 280px;
        scroll-snap-align: start;
    }

    h1 {
        font-size: 1.75rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    .btn {
        padding: 0.625rem 1.25rem;
        font-size: 0.9rem;
    }
}

/* Accessibility */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Focus styles */
*:focus-visible {
    outline: 2px solid rgba(245,194,107,0.8);
    outline-offset: 2px;
}

/* Step-by-Step Section Styles */
.steps {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    list-style: none;
    margin: 2rem 0;
    padding: 0;
}

.step-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-medium);
    padding: 1.5rem;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    box-shadow: var(--card-shadow);
    transition: transform 180ms ease-out, box-shadow 180ms ease-out;
}

.step-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.7);
}

.step-index {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--btn-primary-bg);
    color: var(--btn-primary-text);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.step-body {
    flex: 1;
}

.step-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

/* Pros & Cons Section Styles */
.pros-cons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin: 2rem 0;
}

.pros-col,
.cons-col {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-medium);
    padding: 2rem;
    box-shadow: var(--card-shadow);
}

.pros-col h3,
.cons-col h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.pros-list,
.cons-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.pros-list li,
.cons-list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--card-border);
}

.pros-list li:last-child,
.cons-list li:last-child {
    border-bottom: none;
}

.icon-check {
    color: var(--text-success);
    flex-shrink: 0;
}

.icon-cross {
    color: var(--text-danger);
    flex-shrink: 0;
}

/* Responsive adjustments for special sections */
@media (max-width: 768px) {
    .steps {
        grid-template-columns: 1fr;
    }

    .pros-cons {
        grid-template-columns: 1fr;
    }

    .pros-col {
        order: 1;
    }

    .cons-col {
        order: 2;
    }
}

/* Print styles */
@media print {
    header,
    footer,
    .toc-nav,
    .back-to-top {
        display: none;
    }
}

