:root {
    --text: #1a2744;
    --background: #fafaf7;
    --accent-dark: #1a2744;
    --accent: #5B8BD2;
    --accent-light: #c8d8f0;
    --text-light: #2e4080;
    --foam: #f0f4ff;
    --wave-mid: #c8d8f0;
    --wave-deep: #8aaad4;
    --radius: 4px;
    --white: #fff;
    --titlefont: Fraunces;
    
        
    --text-size: 16px;

    --minimum-img-width: 150px;
    --maximum-img-width: 400px;
    --maximum-columns: 4;
    --image-background: #fff;
    --column-gap: var(--spacing);

    --max-width: 800px;
    --spacing: 16px;
    --border-radius: 4px;
    --underline: wavy var(--accent-light);
    --border: 1px dashed #8aaad4;

    --halfspacing: calc(var(--spacing) / 2);
    --doublespacing: calc(var(--spacing) * 2);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    max-width: 100%;
    scrollbar-color: var(--accent);
    -ms-overflow-style: none;
    box-decoration-break:clone
}

body {
   background-size: cover;
   background-position: center;
    min-height: 100vh;
    overflow-x: hidden;
    overflow-y: fixed;
    padding: var(--spacing) 5%;
    background-color: var(--background);
    color: var(--text);
    font-family: "Fira Code", monospace;
    font-size: var(--text-size);
    line-height: 1.6;
    background-repeat: no-repeat;
    background-attachment: fixed;
}


body.home {
    background-image: url('waves.png');
    overflow: hidden;
    height: 100vh;
    padding-bottom: 0;
}
h1:has(+ nav) {
    margin-bottom: var(--halfspacing);
    font-family: 'Fraunces', serif;
}

        .hero-title {
            position: absolute;
            top: 16%;
            left: 50%;
            transform: translate(-50%, -50%);
            text-align: center;
            z-index: 10;
        }
 
        .hero-title h1 {
            font-family: 'Fraunces', serif;
            font-size: clamp(1.8rem, 6vw, 3rem);
            color: var(--text);
            line-height: 1.1;
            letter-spacing: 0.02em;
            white-space: nowrap;
             margin-bottom: 0;
        }
 
        .hero-title .subtitle {
            font-family: "Fira Code", monospace;
            font-style: italic;
            font-size: 1rem;
            color: var(--text-light);
            margin-top: 6px;
            letter-spacing: 0.05em;
            margin-bottom: 0;
        }
        .nav-grid {
            position: absolute;
            display: flex;
            left: 50%;
            top: 30%;
            transform: translateX(-50%);
            max-width: 480px;
            flex-wrap: wrap;
            gap: 6px;
            justify-content: center;
            z-index: 10;
        }
 
        .nav-btn {
            background: var(--wave-mid);
            border: 1px dashed var(--text);
            color: var(--text);
            font-family: "Fira Code", monospace;
            font-style: italic;
            font-size: 0.95rem;
            padding: 7px 22px;
            border-radius: 20px;
            text-decoration: none;
            cursor: pointer;
            backdrop-filter: blur(4px);
            transition: background 0.2s, color 0.2s;
            white-space: nowrap;
        }
 
        .nav-btn:hover {
            background: var(--text);
            color: var(--foam);
            border-color: var(--text);
        }
        .main-wrap {
            max-width: 860px;
            margin: 0 auto;
            padding: 32px var(--spacing);
            display: grid;
            grid-template-columns: 1fr 260px;
            gap: 28px;
            align-items: start;
        }
 
        @media (max-width: 640px) {
            .main-wrap {
                grid-template-columns: 1fr;
            }
        }
        .sidebar {
            display: flex;
            flex-direction: column;
            gap: 16px;
        }
        
        .wave-hero {
        position: relative;
        height: 100vh;
        }
        .currently-box {
            border: var(--border);
            border-radius: var(--radius);
            background: var(--foam);
            overflow: hidden;
        }
 
        .currently-box .box-header {
            background: var(--text);
            color: var(--foam);
            font-family: 'IM Fell English', serif;
            font-style: italic;
            font-size: 0.9rem;
            padding: 6px 12px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            flex-wrap: wrap;
            row-gap: 2px;
        }
 
        .currently-box .box-header span {
            font-size: 0.75rem;
            opacity: 0.7;
            font-style: normal;
            font-family: monospace;
        }
 
        .currently-scroll {
            max-height: 200px;
            overflow-y: auto;
            padding: 12px;
            display: grid;
            grid-template-columns: 90px 1fr;
            column-gap: 10px;
            row-gap: 0;
            scrollbar-width: thin;
            scrollbar-color: var(--wave-deep) var(--foam);
        }

        .currently-item {
            display: grid;
            grid-template-columns: subgrid;
            grid-column: 1 / -1;
            align-items: baseline;
            padding: 6px 0;
            border-bottom: 1px dotted var(--wave-mid);
            font-size: 0.88rem;
        }

        .currently-item:last-child {
            border-bottom: none;
        }

        .currently-item .label {
            color: var(--accent);
            font-style: italic;
            font-size: 0.8rem;
        }

        .currently-item .value {
            color: var(--text);
            line-height: 1.4;
        }
        .ltexts-box {
            border: var(--border);
            border-radius: var(--radius);
            background: var(--white);
            overflow: hidden;
        }
 
        .ltexts-box .box-header {
            background: var(--accent);
            color: var(--foam);
            font-family: 'IM Fell English', serif;
            font-style: italic;
            font-size: 0.9rem;
            padding: 6px 12px;
        }
 
        .ltexts-box .ltexts-inner {
            padding: 10px 12px;
            display: flex;
            flex-direction: column;
            gap: 6px;
        }
 
        .ltexts-box a {
            color: var(--text-light);
            text-decoration: none;
            font-size: 0.88rem;
            border-bottom: 1px dotted var(--wave-mid);
            padding-bottom: 4px;
            transition: color 0.15s;
        }
 
        .ltexts-box a:hover {
            color: var(--accent);
        }
 
        .ltexts-box a::before {
            content: "→ ";
            color: var(--wave-deep);
        }

        .gb-btn {
            display: inline-block;
            background: var(--foam);
            border: 1px dashed var(--text);
            color: var(--text);
            font-family: "Fraunces", serif;
            font-style: italic;
            font-size: 0.85rem;
            padding: 5px 16px;
            border-radius: 20px;
            text-decoration: none;
            transition: background 0.2s;
        }
 
        .gb-btn:hover {
            background: var(--text);
            color: var(--foam);
        }

header {
    text-align: center;
    padding-bottom: var(--spacing);
    font-family: 'Fraunces', serif;

}

.about-hero {
    position: relative;
    min-height: 100vh;
    height: auto;
    width: 100vw;
    max-width: 100vw;
    display: flex;
    flex-direction: column;
    background-image: url('waves.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    margin-top: calc(-1 * var(--spacing));
    margin-bottom: var(--doublespacing);
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    border-bottom: var(--border);
}

.about-banner {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    row-gap: 4px;
    width: 100%;
    background: var(--accent);
    border-bottom: var(--border);
    padding: 10px 5%;
    z-index: 10;
    flex-shrink: 0;
}

.about-banner .brand-mini {
    font-family:'Fraunces', serif;
    font-size: 1rem;
    color: var(--white);
    text-decoration: none;
    opacity: 0.85;
}

.about-banner .brand-mini:hover {
    opacity: 1;
    color: var(--foam);
}

.about-banner .banner-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 18px;
}

.about-banner .banner-nav a {
    color: var(--foam);
    text-decoration: none;
    font-style: italic;
    font-size: 0.95rem;
    opacity: 0.85;
}

.about-banner .banner-nav a:hover {
    opacity: 1;
    color:var(--white);
    text-decoration: underline;
}

.about-banner .banner-nav::after {
    content: none;
}
.about-content {
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--doublespacing);
    padding: var(--doublespacing) 5% 64px;
    max-width: 1100px;
    margin: 0 auto;
    z-index: 10;
}

.about-columns {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
    gap: var(--doublespacing);
    width: 100%;
}

.about-text-box {
    flex: 1 1 420px;
    max-width: 640px;
    background: var(--white);
    border: var(--border);
    border-radius: var(--radius);
    padding: var(--spacing) var(--doublespacing);
}

.about-text-box .about-title {
    font-family: 'Fraunces', serif;
    text-align:left;
    font-size: 1rem;
    color: var(--accent);
    margin: 0 0 var(--halfspacing);
}

.about-content .about-side {
    width: 360px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: var(--halfspacing);
    padding: var(--spacing);
    background: var(--background);
    border: var(--border);
    border-radius: var(--radius);
}

.about-photo {
    aspect-ratio: 1 / 1;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--wave-mid);
    border: 1px dashed var(--text);
    border-radius: var(--radius);
    color: var(--text-light);
    font-style: italic;
}

.about-side .currently-box {
    background: var(--white);
}

@media (max-width: 640px) {
    .about-banner {
        grid-template-columns: 1fr;
        justify-items: center;
        gap: 4px;
        text-align: center;
    }

    .about-banner .brand-mini {
        grid-column: 1;
        justify-self: center;
    }

    .about-content {
        padding: var(--doublespacing) 5%;
    }

    .about-columns {
        flex-direction: column;
    }

    .about-text-box {
        max-width: 100%;
    }

    .about-content .about-side {
        width: 100%;
        max-width: 320px;
        margin: 0 auto;
    }
}

nav {
    padding-top: var(--spacing)
}

main, header, footer {
    max-width: var(--max-width);
    margin: 0 auto;
}

footer {    text-align: center;
            font-size: 0.8rem;
            color: var(--text-light);
            padding: 24px var(--spacing) 32px;
            font-style: italic;
            border-top: var(--border);
            margin-top: 16px;
            background-color: var(--background);
        }

        body.home footer {
            position: fixed;
            bottom: 0;
            left: 0;
            right: 0;
            margin-top: 0;
            padding: 8px var(--spacing) 10px;
            font-size: 0.7rem;
            background: rgba(250, 250, 247, 0.75);
            backdrop-filter: blur(4px);
            border-top: 1px dashed var(--text);
            z-index: 5;
        }
 
        footer a {
            color: var(--accent);
            text-decoration: none;
        }
 
        footer a:hover {
            text-decoration: underline;
        }

/* element styling */
a {
    color: var(--accent);
    text-decoration: underline var(--underline);
    text-underline-offset:.15em
}

a:hover {
    color: var(--accent-dark);
}

nav a {
    padding: 5px;
    margin: 5px;
}

#to-top a {
    position: fixed;
    right: var(--spacing);
    bottom: var(--spacing);
    font-size: 50px;
    text-decoration: none;
    color: var(--accent-light);
}

b {
    color: var(--accent-dark)
}

i {
    color: var(--accent)
}

mark {
    background-color: var(--accent-light);
    padding: 1px 2px;
    border-radius:var(--border-radius)
}

code {
    font-size:.9em;
    padding:1px 3px;
    font-family:monospace;
    color:var(--accent-dark)
}

u {
    text-decoration-color: var(--accent-dark)
}
ol, ul {
    margin:var(--spacing);
}
li {
    padding-left:var(--halfspacing);
    margin:var(--halfspacing) auto;
}
li > ul {
    padding-left: var(--spacing);
    margin:auto;
    font-size:.9em;
}
li::marker {
    color: var(--accent);
}
blockquote {
    padding-left:var(--doublespacing);
    margin:var(--doublespacing);
    border-left: var(--border);
    color:var(--accent-dark)
}

hr {
    width: 100%;
    border: none;
}

img {
   vertical-align: middle;
   max-width:100%;
}

.box {
    padding: var(--spacing);
    border: var(--border);
    margin: var(--spacing) auto;
    border-radius: var(--border-radius);
    break-inside:avoid;
}

.flex {
    display: flex;
    flex-flow: row wrap;
    gap: var(--halfspacing) var(--spacing)
}

.flex > * {
    flex: 1 2 200px;
    margin:0 auto;
}

.center {
    text-align: center;
}

hr::after,
nav::after,
footer::before {
    content: "\a0 \a0";
    text-align-last: justify;
    width: 50%;
    margin: var(--spacing) auto;
    display: table;
    text-decoration: underline var(--underline);
    text-decoration-thickness: .1em
}

h1,
h2,
h3,
h4 {
    font-family: var(--titlefont);
    margin: 1.5em auto;
    text-align: center;
    line-height: 1.3em;
}

h1 {
    font-size: 2em;
    
}
   h1 a {
      text-decoration: none;
      color:var(--accent);
    }

h2 {
    font-size: 1.5em;
    margin: 1em auto;
    color: var(--accent);

}

h3 {
    color: var(--background);
    background: var(--accent)
}

h4 {
    color: var(--accent-dark);
    background: var(--accent-light);
    font-weight: normal;
}

#gallery {
    margin: var(--doublespacing) auto;
    display: block;
    text-align: center;
    line-height: 1.2em;
    font-size: .9em;
}
#gallery.columns {
    columns: var(--minimum-img-width) var(--maximum-columns);
    gap: var(--column-gap);
}

#gallery img {
    margin: var(--spacing) auto;
    max-width: min(var(--maximum-img-width), 100%);
    display:block;
    background-color:var(--image-background)
}

#gallery img:first-of-type {
  margin-top: 0;
}

figure {
    margin: var(--spacing) auto;
    break-inside: avoid;
}

#gallery img:hover {
    border-radius: var(--border-radius);
    cursor: pointer;
    outline: var(--border)
}

#lightbox {
    border: none;
    outline: none;
}
#lightbox img {
  max-height:90vh;
  max-width:90vw;
}

::backdrop {
    backdrop-filter: blur(2px) brightness(80%);
}

#gallery:has(~ #lightbox:popover-open) {
    pointer-events: none;
}
@media only screen and (min-width: 600px) {
    #lightbox button {
        display: none;
    }
} 
@media only screen and (max-width: 600px) {
    #lightbox button {
        display: block;
        width:30px;
        height:30px;
        margin:10px auto;
    }
}

.projects-main {
    max-width: 1100px;
    margin: 0 auto;
    padding: var(--doublespacing) 5%;
}

.page-title {
    font-family: 'Fraunces', serif;
    color: var(--accent);
    text-align: center;
    margin-bottom: var(--doublespacing);
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing);
}

@media (max-width: 860px) {
    .project-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .project-grid {
        grid-template-columns: 1fr;
    }
}
.project-card {
    display: flex;
    flex-direction: column;
    background: var(--white);
    border: var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    text-decoration: none;
    color: var(--text);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

a.project-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(26, 39, 68, 0.15);
}

.project-card .project-thumb {
    aspect-ratio: 4 / 3;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--wave-mid);
    border-bottom: 1px dashed var(--text);
    color: var(--text-light);
    font-style: italic;
    overflow: hidden;
}

.project-card .project-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-card .project-info {
    padding: var(--halfspacing) var(--spacing) var(--spacing);
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

.project-card .project-title {
    font-family: 'Fraunces', serif;
    font-size: 1.05rem;
    color: var(--accent-dark);
    line-height: 1.25;
}

.project-card .project-desc {
    font-size: 0.85rem;
    color: var(--text-light);
    line-height: 1.4;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: auto;
    padding-top: 6px;
}

.project-tags span {
    font-size: 0.7rem;
    font-family: monospace;
    background: var(--foam);
    border: 1px dashed var(--wave-deep);
    border-radius: 12px;
    padding: 2px 8px;
    color: var(--text-light);
}

.project-detail {
    max-width: 700px;
    margin: 0 auto;
    padding: var(--doublespacing) 5%;
}

.back-link {
    display: inline-block;
    margin-bottom: var(--spacing);
    font-size: 0.9rem;
    color: var(--text-light);
    text-decoration: none;
}

.back-link:hover {
    color: var(--accent);
}
.project-detail-photo {
    aspect-ratio: 16 / 9;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--wave-mid);
    border: 1px dashed var(--text);
    border-radius: var(--radius);
    color: var(--text-light);
    font-style: italic;
    margin-bottom: var(--spacing);
}

.project-detail-title {
    font-family: 'Fraunces', serif;
    color: var(--accent);
    margin-bottom: var(--halfspacing);
}

.project-detail-body {
    background: var(--white);
    border: var(--border);
    border-radius: var(--radius);
    padding: var(--spacing) var(--doublespacing);
    margin-top: var(--spacing);
}

.project-detail-content {
    display: flex;
    align-items: flex-start;
    gap: var(--spacing);
    margin-top: var(--spacing);
}

.project-detail-content .project-detail-body {
    flex: 1;
    margin-top: 0;
}

.project-detail-side-photo {
    flex: 0 0 240px;
    aspect-ratio: 4 / 3;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--wave-mid);
    border: 1px dashed var(--text);
    border-radius: var(--radius);
    color: var(--text-light);
    font-style: italic;
    overflow: hidden;
}

.project-detail-side-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@media (max-width: 640px) {
    .project-detail-content {
        flex-direction: column;
    }

    .project-detail-side-photo {
        flex-basis: auto;
        width: 100%;
    }
}
.skills-section {
    border: var(--border);
    border-radius: var(--radius);
    background: white;              /* solid background = clear delineation */
    overflow: hidden;               /* keeps header corners rounded, like currently-box */
    max-width: 400px;               /* keep it card-sized, not full-width */
}

.skills-section .skills-title {
    background: var(--text);        /* dark header bar, same as .box-header */
    color: var(--foam);
    font-family: 'IM Fell English', serif;
    font-style: italic;
    font-size: 0.9rem;
    padding: 6px 12px;
    margin: 0;
    text-align: left;
}

.skills-category {
    padding: 12px;
    border-bottom: 1px dotted var(--wave-mid);
}

.skills-category:last-child {
    border-bottom: none;
}

.skills-category h3 {
    font-family: 'IM Fell English', serif;
    font-style: italic;
    font-size: 0.8rem;
    color: var(--accent);
    background: none;
    text-align: left;
    margin: 0 0 8px 0;
}

.skills-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;   /* two columns */
    gap: 6px 12px;
}

.skill-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;               /* smaller font, matches .currently-item */
    color: var(--text);
}
@media (max-width: 500px) {
    .skills-grid {
        grid-template-columns: 1fr;   /* stacks to one column on phones */
    }
}
.projects-teaser {
    width: 100%;
    max-width: 640px;
}

.teaser-box {
    display: block;
    text-align: center;
    background: var(--wave-mid);
    border: var(--border);
    border-radius: var(--radius);
    padding: var(--spacing) var(--doublespacing);
    text-decoration: none;
    color: var(--text);
    transition: background 0.2s ease;
}

.teaser-box:hover {
    background: var(--accent-light);
}

.teaser-box p {
    margin-bottom: 4px;
}

.teaser-box .teaser-cta {
    font-family: 'Fraunces', serif;
    color: var(--accent-dark);
    font-size: 1.05rem;
}