
body{
margin:0;
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
background:#f8fafc;
color:#0f172a;
overflow-x:hidden;
}

/* NAVBAR */
nav{
position:sticky;
top:0;
background:#ffffff;
border-bottom:1px solid #e2e8f0;
padding:14px 30px;
display:flex;
justify-content:space-between;
align-items:center;
z-index:10;
}

.logo canvas {
    width: 60px;
    height: 60px;
    display: block;
}

nav ul{
list-style:none;
display:flex;
gap:25px;
margin:0;
padding:0;
}

nav a{
text-decoration:none;
color:#334155;
font-size:14px;
transition:0.3s;
}

nav a:hover{
color:#16a34a;
}

/* HEADER */
header{
text-align:center;
padding:100px 20px 60px 20px;
position:relative;
color:#008080;
overflow:hidden;
z-index:1;
}

h1{
font-size:3rem;
margin-bottom:10px;
color:#008080;
}

h2{
color:#008080;
}

.subtitle{
color:#64748b;
position: relative;
z-index:1;
}

/* CONTAINER */
.container{
max-width:900px;
margin:auto;
padding:20px;
position:relative;
z-index:1;
}

.card{
background:#ffffff;
border-radius:20px;
padding:30px;
margin:20px 0;
box-shadow:0 10px 25px rgba(0,0,0,0.08);
}

code{
background:#f1f5f9;
padding:4px 6px;
border-radius:6px;
}

footer{
text-align:center;
padding:40px;
color:#64748b;
}

/* GRAPH CANVAS */
#graphCanvas{
position:absolute;
top:0;
left:0;
width:100%;
height:100%;
z-index:0;
}

/* Unvisited link */
a:link {
    color: teal;
    text-decoration: none; /* removes underline */
}

/* Visited link */
a:visited {
    color: teal;
}

/* Mouse hover */
a:hover {
    color: teal;
    text-decoration: underline;
}

/* Active link (when clicked) */
a:active {
    color: teal;
}



        /* ============================================================
           TREE COLORING EXPLORER — page-specific styles
           ============================================================ */

.game-wrapper {
    max-width: 900px;
    margin: 0 auto 60px auto;   /* THIS is the key */
    text-align: center;
}

.game-controls {
margin: 0 0 14px 0;
display: flex;
flex-wrap: wrap;
gap: 8px;
align-items: center;
justify-content: center;
}

.game-controls select,
.game-controls button {
font-family: "Latin Modern Roman", Georgia, serif;
font-size: 11pt;
padding: 5px 12px;
background: #ffffff;
color: #0008080;
border: 1px solid #008080;
cursor: pointer;
}

.game-controls button:hover {
border-color: #16a34a;
}

.game-controls button:active {
background: #e2e8f0;
}


.builder-controls {
display: flex;
gap: 8px;
}

.game-scroll {
overflow-x: auto;
-webkit-overflow-scrolling: touch;
display: flex;
justify-content: center;
}

#c {
display: block;
border: 1px solid #008080;
background: #fcfcff;
height:500px;
max-width: 120%;
}

.game-caption {
font-size: 10.5pt;
color: var(--grey);
margin: 10px 0 0 0;
font-style: italic;
line-height: 1.5;
}

@media (prefers-color-scheme: dark) {
#c {
    background: #1a1a20;
    border-color: #2c2c2c;
}
}
