/*
Theme Name: Marie Lorenz Portfolio
Theme URI: https://marielorenz.com
Author: Built for Marie Lorenz
Description: A gallery-style portfolio theme modeled on the original marielorenz.com — a persistent 3-column frame (top bar, a left rail linking to the current project, a right rail listing every past project by year) with a center column that shows either the landing image or the project you clicked on. Built as a classic WordPress theme using a "Projects" custom post type, so new work can be added straight from the native WordPress block editor.
Version: 2.0
Requires at least: 5.9
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: LICENSE
Text Domain: marielorenz
*/

/* ---------- Reset / base ---------- */
* { box-sizing: border-box; }

:root {
    --ml-bg: #ffffff;
    --ml-text: #111111;
    --ml-muted: #6b6b6b;
    --ml-accent: #111111;
    --ml-border: #e2e2e2;
    --ml-rail-bg: #cfcfcf;
    --ml-rail-text: #1a1a1a;
    --ml-font: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
    --ml-script-font: "Tangerine", cursive;

    /* Shared column template — the top bar's inner content lines up with
       this same grid, so the bar reads as exactly the center column's
       width even though the bar itself spans the full page. */
    --ml-col-template: minmax(140px, 1fr) minmax(300px, 680px) minmax(180px, 320px);
}

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

body {
    margin: 0;
    padding: 0;
    background: var(--ml-bg);
    color: var(--ml-text);
    font-family: var(--ml-font);
    font-size: 16px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--ml-text);
    text-decoration: none;
    border-bottom: 1px solid transparent;
}
a:hover,
a:focus {
    border-bottom-color: currentColor;
}

img { max-width: 100%; height: auto; display: block; }

ul { list-style: none; margin: 0; padding: 0; }

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    margin: 0 0 0.5em;
}

p { margin: 0 0 1.2em; }

.screen-reader-text {
    position: absolute;
    width: 1px; height: 1px;
    overflow: hidden;
    clip: rect(1px,1px,1px,1px);
}

/* ---------- Frame ---------- */
.ml-frame {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ---------- Top bar (full width; inner content matches the center column) ---------- */
.ml-topbar {
    background: var(--ml-bg);
    border-bottom: 1px solid var(--ml-border);
}
.ml-topbar-inner {
    display: grid;
    grid-template-columns: var(--ml-col-template);
    padding: 22px 0 18px;
}
.ml-topbar-content {
    grid-column: 2;
    display: flex;
    align-items: baseline;
    gap: 22px;
    flex-wrap: wrap;
}

.ml-logo {
    display: block;
}
.ml-logo img {
    max-width: 140px;
    border-radius: 4px;
}
.ml-logo-text {
    font-family: var(--ml-script-font);
    font-size: 58px;
    line-height: 1;
    font-weight: 700;
    letter-spacing: normal;
    text-transform: none;
}

.ml-nav ul {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}
.ml-nav a {
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 12px;
}

/* ---------- Column grid ---------- */
.ml-columns {
    flex: 1 1 auto;
    display: grid;
    grid-template-columns: var(--ml-col-template);
    align-items: stretch;
}

.ml-col-left,
.ml-col-right {
    background: var(--ml-rail-bg);
    color: var(--ml-rail-text);
    padding: 30px 22px;
}

.ml-col-center {
    background: var(--ml-bg);
    padding: 0;
}

.ml-rail-label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #444;
    margin-bottom: 10px;
}

/* Left rail: current project */
.ml-rail-current {
    display: inline-block;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.35;
    color: var(--ml-rail-text);
}

/* Right rail: past projects — a flat list of titles, newest first */
.ml-past-projects {
    display: flex;
    flex-direction: column;
    gap: 7px;
}
.ml-past-projects li {
    font-size: 13px;
    line-height: 1.4;
}

/* ---------- Landing image (homepage center column) ---------- */
.ml-landing-image {
    width: 100%;
    height: auto;
    display: block;
}
.ml-landing-placeholder {
    padding: 32px 28px;
    color: var(--ml-muted);
    font-size: 14px;
}

/* ---------- Single project / generic page (center column) ---------- */
.ml-project,
.ml-page {
    padding: 22px 28px 64px;
}

.ml-project-title {
    font-size: 22px;
    font-weight: 700;
    text-align: left;
    text-transform: none;
    letter-spacing: normal;
    margin: 0 0 10px;
}
.ml-project-year {
    font-weight: 400;
    color: var(--ml-muted);
}

.ml-project-content,
.ml-page-content {
    text-align: left;
    font-size: 13px;
    line-height: 1.4;
}
.ml-project-content a,
.ml-page-content a {
    border-bottom-color: currentColor;
}
.ml-project-content p,
.ml-page-content p {
    max-width: none;
    margin: 0;
}
/* The last line of the notation block is usually the "Project Site" link —
   give it a little breathing room above (separating it from the tight
   title/venue/year block) and below (before the image starts). */
.ml-project-content p:last-of-type {
    margin-top: 12px;
    margin-bottom: 16px;
}
.ml-project-content figure,
.ml-project-content img,
.ml-project-featured-image img {
    width: 100%;
    height: auto;
    margin: 0 0 14px;
    display: block;
}

.ml-page-content h4 {
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-size: 13px;
    color: var(--ml-muted);
    margin-top: 28px;
}
.ml-page-content ul { margin: 0 0 1.2em; }
.ml-page-content li {
    padding: 4px 0;
    border-bottom: 1px solid var(--ml-border);
}

/* ---------- Contact ---------- */
.ml-contact-email {
    font-size: 16px;
    margin-top: 8px;
}
.ml-contact-email a {
    border-bottom-color: currentColor;
}

/* ---------- Footer (full width, below the frame) ---------- */
.ml-site-footer {
    text-align: center;
    padding: 20px 0 28px;
    color: var(--ml-muted);
    font-size: 12px;
    border-top: 1px solid var(--ml-border);
}

/* ---------- Responsive: stack the 3 columns ---------- */
@media (max-width: 860px) {
    :root {
        --ml-col-template: 1fr;
    }
    .ml-topbar-content {
        grid-column: 1;
        padding: 0 20px;
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    .ml-columns {
        grid-template-columns: 1fr;
    }
    .ml-col-center { order: 1; }
    .ml-col-left { order: 2; }
    .ml-col-right { order: 3; }
    .ml-logo-text { font-size: 48px; }
}
