:root {
    --bg: white;
    --text: black;
    --card: white;
    --border: #242528;
    --button-bg: white;
    --button-text: red;
    --button-border: red;
}

body.dark-mode {
    --bg: #121212;
    --text: #f1f1f1;
    --card: #1f1f1f;
    --border: #555;
    --button-bg: #333;
    --button-text: #ff6b6b;
    --button-border: #ff6b6b;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell,
    "Open Sans", "Helvetica Neue", sans-serif;
    transition: background 0.3s, color 0.3s;
}

.main {
    margin: 0 auto;
    max-width: 1280px;
}


.head1 {
    max-width: 600px;
    margin: 20px auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header {
    margin: 0;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--text);
}


.theme-toggle {
    padding: 8px 14px;
    border: none;
    border-radius: 8px;
    background: #333;
    color: white;
    cursor: pointer;
}

.theme-toggle:hover {
    opacity: 0.85;
}

body.dark-mode .theme-toggle {
    background: #f1f1f1;
    color: #121212;
}


.title h3 {
    display: inline-block;
    padding: 12px 0;
    text-transform: uppercase;
    letter-spacing: 8px;
    font-size: 20px;
    font-weight: 500;
    margin: 0 0 4px 8px;
}


.game {
    box-sizing: border-box;
    float: left;
    width: 25%;
    margin-bottom: 10px;
    margin-right: 10px;
    border: 1px solid var(--border);
    background: var(--card);
    transition: background 0.3s, border-color 0.3s;
}

.border-header {
    margin-bottom: 12px;
}

.border-header h3 {
    font-size: 24px;
    font-weight: 500;
    margin: 1rem;
}

.thumbnail {
    margin: -12px 0;
    padding-top: 56.25%;
    position: relative;
    overflow: hidden;
    border: 1px solid var(--border);
}

.thumbnail img {
    pointer-events: none;
    position: absolute;
    height: 100%;
    width: 100%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* Play button */

.button-container {
    width: 302px;
    height: 53px;
    margin-bottom: -8px;
    margin-top: 12px;
    padding: 4px;
}

.button {
    border-radius: 4px;
    border: 1px solid var(--button-border);
    color: var(--button-text);
    background: var(--button-bg);
    min-height: 34px;
    line-height: 34px;
    margin: 4px;
    padding: 0 12px;
    cursor: pointer;
}

/* about */
#about {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
    clear: both;
}

#about a {
    color: var(--text);
}