/* Defaults */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
    min-height: 100vh; /* only lets me make sure the footer is on the bottom with 100vh, not 100%? */
    display: flex;    
    flex-direction: column; 
}

/* Hedaer */
header {
    background-color: #2c3e50;
    color: white;
    margin: 0;
    padding: 24px 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.header-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 {
    font-size: 32px;
    margin: 0;
}

nav {
    display: flex;
    gap: 15px;
}

nav a {
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 4px;
    transition: background-color 0.3s;
    white-space: nowrap;
}

nav a:hover,
nav a.active {
    background-color: #34495e;
}

/* Main */
.container {
    max-width: 1000px;
    margin: 32px auto;
    padding: 0 20px;
}

/* Layout */
.content-wrapper {
    display: flex;
    gap: 30px;
    align-items: stretch;
}

.left-column {
    flex: 0 0 480px;
    display: flex;
    flex-direction: column;
}

.right-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Canvas container */
.illusion-canvas-container {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

#kanizsa-canvas {
    display: block;
    width: 100%;
    height: auto;
}

/* Controls section */
.controls {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    flex-grow: 1;
}

.button-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.control-btn {
    padding: 12px 20px;
    font-size: 16px;
    border: none;
    border-radius: 5px;
    background-color: #3498db;
    color: white;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.1s;
}

.control-btn:hover {
    background-color: #2980b9;
}

.control-btn:active {
    transform: scale(0.98);
}

.control-btn.reset {
    background-color: #e74c3c;
}

.control-btn.reset:hover {
    background-color: #c0392b;
}

/* Slider styling */
.slider-container {
    margin-bottom: 15px;
}

.slider-container label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
}

#spacing-slider {
    width: 100%;
    height: 8px;
    border-radius: 5px;
    background: #ddd;
    outline: none;
    cursor: pointer;
}

/* Right column sections */
.explanation-top {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.explanation-bottom {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    flex-grow: 1;
}

.explanation-top h2,
.explanation-bottom h2 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 24px;
    border-bottom: 2px solid #3498db;
    padding-bottom: 8px;
}

.explanation-top p,
.explanation-bottom p {
    margin-bottom: 12px;
}

/* Footer */
footer {
    text-align: center;
    padding: 24px;
    background-color: #2c3e50;
    color: white;
    margin-top: auto;
    width: 100%;
}
