/* =============================================
   CSS Playground — original design
   Aesthetic: bold lab/workshop feel,
   high-contrast sections, monospace labels
============================================= */

*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --col-red:    #e63946;
    --col-yellow: #f4c430;
    --col-blue:   #457b9d;
    --col-wood:   #a0785a;
    --bg-light:   #f4f4f0;
    --bg-dark:    #1a1a2e;
    --accent:     #e63946;
    --mono:       'Courier New', Courier, monospace;
    --sans:       Verdana, Geneva, sans-serif;
}

body {
    font-family: var(--sans);
    background: var(--bg-light);
    color: #222;
    font-size: 0.92rem;
    line-height: 1.6;
}

code {
    font-family: var(--mono);
    background: rgba(0,0,0,0.08);
    padding: 1px 5px;
    border-radius: 2px;
    font-size: 0.85em;
}

/* ── Page header ── */
.pg-header {
    background: var(--bg-dark);
    color: #fff;
    padding: 3rem 4rem 2.5rem;
    display: flex;
    align-items: flex-end;
    gap: 3rem;
}

.pg-header h1 {
    font-family: var(--sans);
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 0.9;
    letter-spacing: -0.02em;
    color: #fff;
}

.pg-header h1 span {
    color: var(--col-yellow);
}

.pg-header p {
    font-size: 0.88rem;
    color: rgba(255,255,255,0.6);
    max-width: 340px;
    line-height: 1.5;
}

/* ── Chapter sections ── */
.chapter {
    padding: 3rem 4rem;
    background: var(--bg-light);
}

.chapter-dark {
    background: #0f0f1a;
}

.chapter-label {
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--accent);
    background: rgba(230, 57, 70, 0.1);
    display: inline-block;
    padding: 3px 10px;
    margin-bottom: 1.8rem;
}

.chapter-label.light {
    color: var(--col-yellow);
    background: rgba(244, 196, 48, 0.12);
}

/* ── Experiment blocks ── */
.exp-block {
    margin-bottom: 3.5rem;
}

h2 {
    font-size: 1rem;
    font-weight: bold;
    color: #111;
    margin-bottom: 0.4rem;
}

h2 span {
    font-weight: normal;
    font-family: var(--mono);
    font-size: 0.8em;
    color: #888;
    margin-left: 0.5em;
}

.desc {
    font-size: 0.82rem;
    color: #666;
    margin-bottom: 1rem;
}

.desc.light-text {
    color: rgba(255,255,255,0.5);
}

/* ── Shapes — shared ── */
.sq, .ci {
    width: 100px;
    height: 100px;
    display: inline-block;
    float: left;
}

.ci {
    border-radius: 50%;
}

.red    { background-color: var(--col-red); }
.yellow { background-color: var(--col-yellow); }
.blue   { background-color: var(--col-blue); }
.wood   {
    background-image: url('https://images.pexels.com/photos/172276/pexels-photo-172276.jpeg');
    background-size: cover;
    background-position: center;
}

/* ── Containers ── */
#container-a {
    background: #ddd;
    width: 400px;
    height: 400px;
    overflow: hidden;
}

#container-b {
    position: relative;
    background: #e8e8e8;
    width: 400px;
    height: 240px;
    border: 2px dashed #bbb;
}

#container-c {
    background: #ddd;
    width: 400px;
    height: 100px;
    overflow: hidden;
}

.clear { clear: both; }

/* ── Art section ── */
.art-title {
    font-size: 1.1rem;
    font-weight: bold;
    color: #fff;
    margin-bottom: 0.5rem;
}

.art-title span {
    display: block;
    font-weight: normal;
    font-family: var(--mono);
    font-size: 0.78em;
    color: rgba(255,255,255,0.4);
    margin-top: 0.3em;
}

.art-stage {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.2rem;
}

/* ── The artwork ── */
#artwork {
    position: relative;
    width: 480px;
    height: 480px;
    background: #f0ece0;
    border-style: solid;
    border-color: #111;
    border-width: 4px;
    overflow: hidden;
}

/* Quadrant backgrounds */
.q { position: absolute; }
#q1 { background: #c0392b; width: 234px; height: 234px; top: 0;    left: 0;    }
#q2 { background: #2471a3; width: 234px; height: 234px; top: 0;    left: 246px;}
#q3 { background: #1e8449; width: 234px; height: 234px; top: 246px;left: 0;    }
#q4 { background: #d4a017; width: 234px; height: 234px; top: 246px;left: 246px;}

/* Cross */
#cross-h {
    position: absolute;
    background: #111;
    width: 480px; height: 12px;
    top: 234px; left: 0;
}
#cross-v {
    position: absolute;
    background: #111;
    width: 12px; height: 480px;
    top: 0; left: 234px;
}

/* Bars */
.bar { position: absolute; background: rgba(255,255,255,0.45); }
.bh  { width: 80px; height: 14px; }
.bv  { width: 14px; height: 80px; }

/* Q1 top-left */
#bar-1a { top: 100px; left: 77px; }
#bar-1b { top: 66px;  left: 110px;}
/* Q2 top-right */
#bar-2a { top: 100px; left: 316px;}
#bar-2b { top: 66px;  left: 349px;}
/* Q3 bottom-left */
#bar-3a { top: 347px; left: 77px; }
#bar-3b { top: 313px; left: 110px;}
/* Q4 bottom-right */
#bar-4a { top: 347px; left: 316px;}
#bar-4b { top: 313px; left: 349px;}

/* Dots */
.dot {
    position: absolute;
    border-radius: 50%;
    width: 52px; height: 52px;
    background: rgba(255,255,255,0.65);
}
#dot-1 { top:  91px; left:  91px; }
#dot-2 { top:  91px; left: 337px; }
#dot-3 { top: 337px; left:  91px; }
#dot-4 { top: 337px; left: 337px; }

/* Art caption */
.art-caption {
    font-family: var(--mono);
    font-size: 0.72rem;
    color: rgba(255,255,255,0.35);
    line-height: 1.8;
}
