/*
    CSS Zen Garden — Blue and Green Theme
    Only the CSS has been changed; the HTML remains unchanged.
*/

/* Variables make the main colors easy to reuse and update. */
:root {
    --dark-blue: #073b5c;
    --blue: #168aad;
    --light-blue: #d8f3f8;
    --dark-green: #1b5e4b;
    --green: #52b788;
    --light-green: #d8f3dc;
    --white: #ffffff;
    --text: #173042;
    --shadow: 0 8px 22px rgba(7, 59, 92, 0.16);
}

/* Border-box keeps padding and borders inside an element's width. */
* {
    box-sizing: border-box;
}

/* A blue-green gradient creates the main page background. */
body {
    margin: 0;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(82, 183, 136, 0.35), transparent 35%),
        linear-gradient(135deg, var(--light-blue), var(--light-green));
    font-family: "Segoe Print", "Bradley Hand", "Comic Sans MS", cursive;
    font-size: 17px;
    line-height: 1.7;
}

/* The wrapper limits the width and uses CSS Grid for the layout. */
.page-wrapper {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(250px, 1fr);
    gap: 28px;
    width: min(1180px, 92%);
    margin: 35px auto;
}

/* The introduction and main content occupy the large left column. */
.intro,
.main {
    grid-column: 1;
}

/* The sidebar stays in the right column. */
.sidebar {
    grid-column: 2;
    grid-row: 1 / span 2;
}

/* The header uses a strong gradient, rounded corners, and a shadow. */
header {
    position: relative;
    overflow: hidden;
    padding: 70px 35px;
    color: var(--white);
    text-align: center;
    background: linear-gradient(135deg, var(--dark-blue), var(--blue), var(--green));
    border: 4px solid rgba(255, 255, 255, 0.7);
    border-radius: 28px;
    box-shadow: var(--shadow);
}

/* A decorative translucent circle is created without changing the HTML. */
header::before {
    position: absolute;
    top: -55px;
    right: -35px;
    width: 190px;
    height: 190px;
    content: "";
    background: rgba(255, 255, 255, 0.12);
    border-radius: 50%;
}

/* A second decorative shape balances the header design. */
header::after {
    position: absolute;
    bottom: -65px;
    left: -25px;
    width: 155px;
    height: 155px;
    content: "";
    background: rgba(82, 183, 136, 0.35);
    border-radius: 50%;
}

/* Letter spacing and text shadow make the title stand out. */
header h1 {
    position: relative;
    z-index: 1;
    margin: 0;
    font-size: clamp(2.6rem, 7vw, 5rem);
    line-height: 1.1;
    letter-spacing: 3px;
    text-shadow: 3px 4px 0 rgba(0, 0, 0, 0.18);
}

/* The subtitle is smaller and lighter than the main heading. */
header h2 {
    position: relative;
    z-index: 1;
    margin: 14px 0 0;
    color: #e4fff2;
    font-size: clamp(1.2rem, 3vw, 2rem);
    font-weight: normal;
}

/* Shared card styling creates visual consistency between sections. */
.summary,
.preamble,
.explanation,
.participation,
.benefits,
.requirements {
    margin-top: 24px;
    padding: 28px 32px;
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid rgba(22, 138, 173, 0.25);
    border-left: 8px solid var(--green);
    border-radius: 18px;
    box-shadow: var(--shadow);
}

/* Alternating border colors help distinguish neighboring sections. */
.explanation,
.benefits {
    border-left-color: var(--blue);
}

/* A subtle hover transition makes the content cards interactive. */
.summary,
.preamble,
.explanation,
.participation,
.benefits,
.requirements {
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.summary:hover,
.preamble:hover,
.explanation:hover,
.participation:hover,
.benefits:hover,
.requirements:hover {
    transform: translateY(-4px);
    box-shadow: 0 13px 28px rgba(7, 59, 92, 0.22);
}

/* Section headings use blue text and a green underline. */
h3 {
    display: inline-block;
    margin: 0 0 12px;
    color: var(--dark-blue);
    font-size: 1.65rem;
    border-bottom: 4px solid var(--green);
}

/* Paragraph spacing improves readability. */
p {
    margin: 0 0 1em;
}

p:last-child {
    margin-bottom: 0;
}

/* Links use green and receive a blue background on hover or focus. */
a {
    color: var(--dark-green);
    font-weight: bold;
    text-decoration-color: var(--blue);
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
    transition: color 0.2s ease, background-color 0.2s ease;
}

a:hover,
a:focus {
    color: var(--white);
    background-color: var(--blue);
    border-radius: 4px;
    outline: none;
}

/* Abbreviations receive a dotted underline to show extra information. */
abbr {
    cursor: help;
    text-decoration: underline dotted var(--green) 2px;
    text-underline-offset: 3px;
}

/* The sidebar uses a dark vertical gradient. */
.sidebar {
    align-self: start;
    position: sticky;
    top: 20px;
    padding: 25px;
    color: var(--white);
    background: linear-gradient(180deg, var(--dark-blue), var(--dark-green));
    border: 3px solid rgba(255, 255, 255, 0.75);
    border-radius: 24px;
    box-shadow: var(--shadow);
}

/* Sidebar headings use light colors for contrast. */
.sidebar h3 {
    display: block;
    margin-top: 18px;
    color: var(--light-green);
    border-bottom-color: var(--blue);
}

/* The first sidebar heading does not need extra top spacing. */
.sidebar h3:first-child {
    margin-top: 0;
}

/* Default list bullets are removed from navigation areas. */
.sidebar ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

/* Each list item becomes a separate translucent panel. */
.sidebar li {
    margin: 9px 0;
    padding: 11px 13px;
    background: rgba(255, 255, 255, 0.1);
    border-left: 4px solid var(--green);
    border-radius: 8px;
}

/* Sidebar links need a light color against the dark background. */
.sidebar a {
    color: #e4fff2;
}

/* The designer name is displayed with a lighter font weight. */
.sidebar .designer-name {
    color: #a9e8ff;
    font-weight: normal;
}

/* Sidebar list items move slightly when the pointer hovers over them. */
.sidebar li {
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.sidebar li:hover {
    background: rgba(82, 183, 136, 0.35);
    transform: translateX(5px);
}

/* Footer links are arranged evenly with Flexbox. */
footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin-top: 25px;
    padding: 24px;
    background: var(--dark-blue);
    border-radius: 18px;
    box-shadow: var(--shadow);
}

/* Footer links look like rounded buttons. */
footer a {
    min-width: 68px;
    padding: 10px 14px;
    color: var(--white);
    text-align: center;
    text-decoration: none;
    background: var(--green);
    border: 2px solid transparent;
    border-radius: 999px;
}

/* Hover and keyboard focus styles make footer buttons clearer. */
footer a:hover,
footer a:focus {
    color: var(--dark-blue);
    background: var(--light-green);
    border-color: var(--white);
}

/* Decorative fixed circles add depth using the empty HTML elements. */
.extra1,
.extra2 {
    position: fixed;
    z-index: -1;
    border-radius: 50%;
    filter: blur(2px);
}

.extra1 {
    top: 12%;
    left: -80px;
    width: 190px;
    height: 190px;
    background: rgba(22, 138, 173, 0.18);
}

.extra2 {
    right: -100px;
    bottom: 8%;
    width: 250px;
    height: 250px;
    background: rgba(82, 183, 136, 0.2);
}

/* This media query changes the two-column layout for tablets and phones. */
@media (max-width: 850px) {
    .page-wrapper {
        display: block;
        width: min(94%, 720px);
    }

    .sidebar {
        position: static;
        margin-top: 25px;
    }

    header {
        padding: 55px 22px;
    }
}

/* Smaller padding and font sizes improve the mobile layout. */
@media (max-width: 520px) {
    body {
        font-size: 15px;
    }

    .page-wrapper {
        margin-top: 16px;
    }

    .summary,
    .preamble,
    .explanation,
    .participation,
    .benefits,
    .requirements {
        padding: 21px 19px;
        border-left-width: 6px;
    }

    header {
        border-radius: 18px;
    }

    footer {
        gap: 8px;
    }

    footer a {
        min-width: 58px;
        padding: 8px 11px;
    }
}

/* Reduced-motion support improves accessibility for sensitive users. */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto;
        transition: none !important;
    }
}