/* ==========================================================
   MURALMASTER.ORG — shared stylesheet for every page
   One file controls the look of the whole site.
   Pages in a section folder link it as:  ../css/muralmaster.css
   Pages in the main folder link it as:   css/muralmaster.css
   ========================================================== */

/* ---------- 1. Colors and fonts used across the site ---------- */
:root {
    --teal:        #007882;
    --teal-dark:   #004646;
    --peach:       #f9ce9f;   /* page titles, footer links */
    --yellow:      #fafa64;   /* menu, big titles */
    --green:       #64fa96;   /* captions, link hover */
    --spring:      #00ff7f;   /* "font-2" text */
    --white:       #ffffff;

    --font-body:    Baskerville, Georgia, "Times New Roman", serif;
    --font-title:   "Cooper Black", Geneva, Verdana, sans-serif;
    --font-ui:      Verdana, Arial, sans-serif;

    --page-width:   960px;
    --shadow:       0 6px 20px 0 rgba(0, 0, 0, 0.5);
}

/* ---------- 2. Basics ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    color: var(--white);
    font-family: var(--font-body);
    background-color: #00505a;              /* shows while the picture loads */
    cursor: url(../images_site_supplemental/cursor6-muralmaster.cur), default;
}

/* Teal background picture. Placed on a fixed layer so it stays put
   while scrolling on every device (including iPhones and iPads). */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    background: url(../images_site_supplemental/images/shared/background-image-teal-gradient.webp) center top / cover no-repeat;
}

img, video { max-width: 100%; height: auto; }

a { color: var(--yellow); }
a:hover { color: var(--green); }

hr {
    border: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.45);
    margin: 20px 0;
}

/* The page column: 960px on a PC, full width with a small margin on phones */
.page {
    width: 100%;
    max-width: var(--page-width);
    margin: 20px auto 0;
    padding: 0 16px;
}
@media (min-width: 992px) {
    .page { padding: 0; }   /* full 960px column on a PC, exactly like before */
}

/* ---------- 3. Header: video, quote scroll, logo and menu ---------- */
.site-header {
    display: flex;
    flex-wrap: nowrap;   /* one row on a PC; allowed to wrap on tablets/phones below */
    align-items: flex-start;
    gap: 0;
}

.header-video {
    flex: 0 1 500px;
    min-width: 0;
    background: #000;
    border: 2px solid var(--teal);
    border-radius: 10px;
    box-shadow: var(--shadow);
    padding: 20px;
}
.header-video video { display: block; width: 100%; }

.header-intro {
    flex: 1 1 400px;
    padding: 30px 20px 0;
    text-align: center;
}
.header-title, h1.header-title {
    font-weight: normal;
    font-family: var(--font-title);
    color: var(--yellow);
    font-size: 30px;
    line-height: 1.2;
    letter-spacing: 1.25px;
    text-shadow: 3px 3px 6px var(--teal-dark);
    margin: 0 0 24px;
}
.header-quote + .header-title { margin-top: 24px; }
.header-quote {
    font-family: var(--font-body);
    color: var(--green);
    font-size: 14px;
    font-style: italic;
    font-weight: bold;
    line-height: 1.3;
    letter-spacing: 1.25px;
    text-shadow: 3px 3px 6px var(--teal-dark);
    margin: 0;
}
.header-image {
    flex: 0 1 auto;
    min-width: 0;
    max-width: 360px;
    padding: 0 10px;
    text-align: center;
}
.header-image img { display: block; margin: 0 auto; max-width: 100%; }
.header-image.pair { display: flex; gap: 10px; max-width: none; align-items: flex-start; }
.header-image.pair img { flex: 0 1 auto; min-width: 0; margin: 0; }

.header-side {
    flex: 0 0 175px;
    margin-left: auto;
    text-align: center;
}
.logo { display: block; width: 175px; margin: 0 auto; }

/* ---------- 4. MENU (tap to open on phones/tablets, hover on a PC) ---------- */
.site-nav {
    position: relative;
    font-family: var(--font-ui);
    font-size: 12px;
    font-weight: 600;
}
.menu-button {
    font: inherit;
    color: var(--yellow);
    background: none;
    border: 0;
    padding: 8px 12px;
    cursor: pointer;
    letter-spacing: 0.5px;
}
.menu-button:hover,
.menu-button[aria-expanded="true"] { color: var(--white); }

.drop-menu {
    display: none;
    list-style: none;
    margin: 0;
    padding: 10px 0;
    background: rgba(0, 120, 130, 0.92);
    border-radius: 10px;
    box-shadow: var(--shadow);
}
.drop-menu li a {
    display: block;
    padding: 5px 10px;
    color: var(--yellow);
    text-decoration: none;
}
.drop-menu li a:hover,
.drop-menu li a:focus { color: var(--green); text-shadow: 1px 2px rgba(0, 0, 0, 0.19); }

.site-nav.open .drop-menu { display: block; }

/* On a computer with a mouse, the menu also opens on hover, as before */
@media (hover: hover) and (pointer: fine) {
    .site-nav:hover .drop-menu { display: block; }
}

/* ---------- 5. Main text ---------- */
.content {
    overflow-wrap: break-word;   /* long web addresses and emails wrap on small screens */
    font-size: 15px;
    line-height: 1.4;
    text-align: justify;
    -webkit-font-smoothing: antialiased;
    padding: 30px 0 20px;
}
.content p {
    text-indent: 60px;
    margin: 0 0 1.6em;
}
.content p.no-indent { text-indent: 0; }

/* Titles (these replace the old <title-1>, <title-2> ... tags) */
.title-1, .title-2, .title-3, .title-4, .title-5 {
    font-family: var(--font-title);
    font-weight: normal;
    text-shadow: 3px 3px 6px var(--teal-dark);
    letter-spacing: 1.25px;
    text-align: left;
    margin: 0 0 18px;
}
.title-1 { color: var(--peach);  font-size: 25px; }
.title-2 { color: var(--yellow); font-size: 30px; }

/* Smaller section headings inside an article */
.subtitle {
    font-family: var(--font-title);
    font-weight: normal;
    color: var(--white);
    font-size: 26px;
    letter-spacing: 1.25px;
    text-shadow: 3px 3px 6px var(--teal-dark);
    text-align: left;
    margin: 10px 0 18px;
}
.title-3 { color: var(--spring); font-family: var(--font-body); font-weight: bold; font-size: 18px; letter-spacing: 1.1px; text-shadow: none; }

/* Small labels and quotes inside articles */
.content .title-4 { color: var(--yellow); font-family: var(--font-ui); font-size: 14px; text-indent: 0; text-align: left; margin: 0 0 8px; }
.content .title-5 { font-family: var(--font-body); font-size: 15px; text-indent: 0; text-align: center; margin: 0 0 8px; }
.content .h-1 { color: var(--peach); font-size: 18px; font-style: italic; line-height: 1.25; text-indent: 0; text-align: justify; }
.content .h-2 { color: var(--yellow); font-size: 18px; font-style: italic; line-height: 1.4; text-indent: 0; text-align: center; }

/* Colored text (these replace the old <font-1>, <font-2> ... tags) */
.font-1 { color: yellow; }
.font-2 { color: var(--spring); }
.font-3 { color: var(--peach); }
.font-4 { color: #fb88e4; }
.font-5 { color: #fcc181; }
.font-6 { color: #3dfbf9; }
.font-7 { color: #4ffb8e; }
.p-1    { color: var(--peach); }
.shift-3 { color: var(--peach); }

/* "Under construction" page: everything centered */
.content.under-construction, .content.under-construction p { text-align: center; }
.under-construction .title-2 { text-align: center; }
.under-construction .fig { max-width: 680px; margin-top: 30px; }

/* ---------- 6. Picture + caption blocks ---------- */
/* Picture on the left, caption on the right (PC/tablet); stacked on phones */
.fig {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 50px;
    margin: 0 auto 2.5em;
    max-width: 640px;
}
.fig .box { flex: 0 0 auto; position: relative; z-index: 1; }
.fig .box + .box { margin-left: -30px; }   /* two pictures sharing one caption */
.fig .box img {
    display: block;
    border: 4px solid var(--white);
    box-shadow: var(--shadow);
    transition: transform 0.5s;
}
.fig .box img.zoomable { cursor: zoom-in; }
.fig .box.plain img { border: 0; box-shadow: none; }   /* pictures shown without a frame on the original page */

.caption {
    flex: 0 1 290px;
    color: var(--green);
    font-family: var(--font-ui);
    font-size: 11px;
    font-weight: bold;
    line-height: 1.5;
    text-align: justify;
    margin: 0;
}

/* Text that sat in a table box on the original page */
.table-text { margin: 0 auto 1.6em; max-width: 720px; }

/* Text boxes that sat side by side on the original page */
.text-columns { display: flex; gap: 40px; margin: 0 0 2em; }
.text-column { flex: 1 1 0; min-width: 0; }

/* A caption whose picture is missing in the original page */
.caption.solo { max-width: 520px; margin: 0 auto 2.5em; text-align: center; }

/* Picture with the caption underneath, centered */
.fig.stack { flex-direction: column; gap: 12px; }
.fig.stack .caption { flex: none; text-align: center; max-width: 520px; }

/* On a computer: hover over a picture to enlarge it, as before */
@media (hover: hover) and (pointer: fine) and (min-width: 900px) {
    .fig .box:not(.plain):hover { z-index: 10; }
    .fig .box:not(.plain):hover img.zoomable { transform: scale(4); }
    .fig.stack .box:not(.plain):hover img.zoomable { transform: scale(2.5); }
}

/* ---------- 7. Photo gallery grid ---------- */
.gallery {
    list-style: none;
    margin: 25px 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;   /* each row of thumbnails is centered */
    gap: 30px 100px;           /* at most four per row on a PC, as before */
}
.gallery li {
    flex: 0 0 auto;
    min-width: 130px;
    text-align: center;
    font-family: var(--font-ui);
    font-size: 11px;
    color: var(--green);
}
.gallery a { color: inherit; text-decoration: none; }
.gallery img {
    display: block;
    margin: 0 auto 6px;
    padding: 4px;
    background: #ebebeb;
    border: 1px solid #004b4b;
    box-shadow: var(--shadow);
}
.gallery img:hover { border-color: var(--green); }

/* Videos inside an article */
.content-video {
    display: block;
    width: 100%;
    max-width: 720px;
    margin: 0 auto 2em;
    background: #000;
    border: 2px solid var(--teal);
    border-radius: 10px;
    box-shadow: var(--shadow);
}

/* ---------- 8. PDF documents ---------- */
.pdf-block { margin: 0 0 2em; }
.pdf-link { text-indent: 0 !important; text-align: center; margin: 0 0 12px !important; }
.pdf-link a {
    display: inline-block;
    padding: 10px 18px;
    border: 2px solid var(--yellow);
    border-radius: 8px;
    font-family: var(--font-ui);
    font-size: 13px;
    font-weight: bold;
    text-decoration: none;
}
.pdf-embed { display: block; width: 100%; height: 80vh; border: 0; background: #fff; }

/* ---------- 8b. "About Muralmaster" box ---------- */
.about { padding: 20px 0; text-align: justify; font-size: 15px; line-height: 1.4; }

/* ---------- 9. Footer ---------- */
.site-footer { text-align: center; padding: 15px 0 30px; }
.footer-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px 0;
}
.footer-nav a {
    display: inline-block;
    padding: 8px 12px;
    color: var(--peach);
    text-decoration: none;
    font-family: var(--font-ui);
    font-weight: 600;
    font-size: 12px;
}
.footer-nav a:hover { color: var(--green); text-shadow: 1px 2px rgba(0, 0, 0, 0.19); }
.copyright {
    font-family: var(--font-ui);
    font-weight: 600;
    font-size: 11px;
    padding-top: 30px;
}

/* ---------- 10. Full-size picture viewer (tap or click any picture) ---------- */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 12px;
    padding: 20px;
    background: rgba(0, 20, 22, 0.94);
    cursor: zoom-out;
}
.lightbox.open { display: flex; }
.lightbox img {
    max-width: 100%;
    max-height: 85vh;
    border: 4px solid var(--white);
    box-shadow: var(--shadow);
}
.lightbox p {
    margin: 0;
    max-width: 700px;
    color: var(--green);
    font-family: var(--font-ui);
    font-size: 13px;
    text-align: center;
}
.lightbox-close {
    position: absolute;
    top: 10px;
    right: 14px;
    font: bold 28px/1 var(--font-ui);
    color: var(--white);
    background: none;
    border: 0;
    cursor: pointer;
}

/* ---------- 11. Homepage ---------- */
/* The homepage keeps its slowly changing background colors */
body.home { animation: home-colors 40s infinite; }
body.home::before { display: none; }
@keyframes home-colors {
    0%   { background-color: #007882; }
    20%  { background-color: #2980b9; }
    40%  { background-color: #c0392b; }
    60%  { background-color: #8e44ad; }
    80%  { background-color: #0652dd; }
    100% { background-color: #007882; }
}
@media (prefers-reduced-motion: reduce) { body.home { animation: none; background-color: #007882; } }

.home-header { display: flex; align-items: center; gap: 30px; padding: 0 0 20px; }
.home-header .header-video { flex: 0 1 500px; margin-left: 30px; }
.home-title { flex: 1 1 380px; text-align: center; }
.home-logo { display: block; margin: 0 auto 10px; max-width: 100%; }
.home-tagline {
    font: bold 14px/20px var(--font-ui);
    color: var(--peach);
    text-shadow: 1px 2px rgba(0, 0, 0, 0.19);
    margin: 15px 0 18px;
}
.home-name {
    font: bold 18px var(--font-ui);
    color: #00fa9a;
    text-shadow: 1px 2px rgba(0, 0, 0, 0.45);
    margin: 0;
}

/* The 12 computer monitors (links to each section) */
.monitors ul {
    list-style: none;
    margin: 10px 0 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px 0;
}
.monitors a {
    display: block;
    text-align: center;
    text-decoration: none;
    padding-bottom: 20px;
}
.monitors img { display: block; margin: 0 auto; }
.monitor-label {
    display: block;
    font: bold 14px var(--font-ui);
    color: var(--peach);
    text-shadow: 1px 2px rgba(0, 0, 0, 0.19);
}
.monitors a:hover .monitor-label, .monitors a:focus .monitor-label { color: var(--green); }

/* Recent Highlights */
.highlights {
    max-width: 600px;
    margin: 0 auto;
    padding: 30px 0;
    text-align: center;
    font: 15px/20px var(--font-body);
    color: #fff799;
}
.highlights h2 { font: bold 18px var(--font-ui); color: #00fa9a; text-shadow: 1px 2px rgba(0, 0, 0, 0.45); margin: 0 0 12px; }
.highlights-intro { margin: 0 0 30px; }
.news h3 { font: bold 15px var(--font-ui); color: var(--peach); text-shadow: 1px 2px rgba(0, 0, 0, 0.19); margin: 0 0 10px; }
.news p { margin: 0 0 14px; }
.news { margin-bottom: 30px; }

/* Homepage footer */
.home-footer { max-width: 550px; margin: 0 auto; padding: 30px 0; }
.home-award { display: flex; align-items: flex-start; gap: 20px; margin-bottom: 40px; }
.home-award img { flex: 0 0 auto; }
.home-award p {
    margin: 0;
    font: bold 12px/20px var(--font-ui);
    color: #00fa9a;
    text-align: justify;
    text-shadow: 1px 2px rgba(0, 0, 0, 0.19);
}
.home-footer .copyright { text-align: center; color: #fff; }

/* ==========================================================
   TABLETS (narrower than a PC screen)
   ========================================================== */
@media (max-width: 991px) {
    .site-header   { flex-wrap: wrap; }
    .monitors ul   { grid-template-columns: repeat(3, 1fr); }
    .home-header .header-video { margin-left: 0; }
    .header-video  { flex: 1 1 60%; }
    .header-intro  { flex: 1 1 55%; padding-top: 10px; }
    .header-image  { flex: 1 1 35%; }
    .header-side   { flex: 1 1 100%; display: flex; align-items: center; justify-content: space-between; margin-top: 12px; }
    .logo { margin: 0; }
    .drop-menu { position: absolute; right: 0; top: 100%; z-index: 100; min-width: 230px; text-align: left; }
}

/* ==========================================================
   PHONES
   ========================================================== */
@media (max-width: 640px) {
    .page { margin-top: 10px; padding: 0 12px; }

    /* Logo and menu bar first, then video, then quote */
    .header-side   { order: -1; margin: 0 0 12px; }
    .header-video  { flex: 1 1 100%; padding: 10px; }
    .header-intro  { flex: 1 1 100%; padding: 0 0 10px; }
    .header-title  { font-size: 26px; margin-bottom: 14px; }
    .header-quote  { font-size: 15px; }
    .header-image  { flex: 1 1 100%; max-width: 320px; margin: 14px auto 0; padding: 0; }
    .header-image.pair { max-width: 100%; justify-content: center; }
    .header-image.pair img { flex: 1 1 0; }
    .logo { width: 140px; }

    .content { font-size: 17px; line-height: 1.5; text-align: left; padding-top: 20px; }
    .content p { text-indent: 30px; }
    .about { font-size: 16px; text-align: left; }

    .title-1 { font-size: 23px; }
    .title-2 { font-size: 26px; }

    /* Pictures get big and the caption goes underneath */
    .fig { flex-direction: column; gap: 12px; }
    .fig .box img { width: 100%; max-width: 420px; }
    .fig .box + .box { margin-left: 0; }
    .subtitle { font-size: 22px; }
    .text-columns { flex-direction: column; gap: 0; }
    .pdf-embed { display: none; }   /* phones can't show PDFs inside a page; the button opens it */
    .fig .box { width: 100%; display: flex; justify-content: center; }
    .caption, .fig.stack .caption { flex: none; font-size: 13px; text-align: left; max-width: 420px; }

    .gallery { gap: 24px 30px; }

    /* Homepage on phones */
    .home-header { flex-direction: column; gap: 16px; }
    .home-header .header-video { flex: none; margin-left: 0; width: 100%; }
    .home-title { flex: none; order: -1; }
    .monitors ul { grid-template-columns: repeat(2, 1fr); }
    .monitors img { width: 100%; max-width: 160px; }
    .monitor-label { font-size: 13px; }
    .highlights { text-align: left; font-size: 16px; line-height: 1.5; }
    .highlights h2, .highlights-intro, .news h3 { text-align: center; }
    .home-award { flex-direction: column; align-items: center; }
    .home-award p { text-align: left; }
}
