/*
Theme Name: Bismonte
Theme URI: https://mariebismonte.com
Author: Marie Bismonte
Author URI: https://mariebismonte.com
Description: A minimal portfolio theme for multidisciplinary artist Marie Bismonte. Visual grid homepage, clean project pages, quiet design that lets the work lead.
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: bismonte
*/

/* ===== RESET & BASE ===== */

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

:root {
  --white: #FAFAFA;
  --off-white: #F5F4F0;
  --black: #1A1A1A;
  --gray-dark: #3D3D3D;
  --gray-mid: #6B6B6B;
  --gray-light: #B0B0B0;
  --gray-rule: #E0DFDB;
  --accent: #2C2C2C;
  --font-display: 'DM Serif Display', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', monospace;
  --max-width: 1200px;
  --max-width-narrow: 740px;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--black);
  background-color: var(--white);
}

a {
  color: var(--black);
  text-decoration: none;
  border-bottom: 1px solid var(--gray-light);
  transition: border-color 0.2s ease;
}

a:hover {
  border-bottom-color: var(--black);
}

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


/* ===== SITE HEADER ===== */

.site-header {
  padding: 2.5rem 2rem 2rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.site-header__inner {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.site-title {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: var(--black);
}

.site-title a {
  border-bottom: none;
  color: var(--black);
}

.site-title a:hover {
  border-bottom: none;
}

.site-nav {
  display: flex;
  gap: 2rem;
  align-items: baseline;
}

.site-nav a {
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gray-mid);
  border-bottom: none;
  transition: color 0.2s ease;
}

.site-nav a:hover,
.site-nav a.current {
  color: var(--black);
}

.site-header__rule {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  border: none;
  border-top: 1px solid var(--gray-rule);
}

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  color: var(--black);
}

.nav-toggle svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  stroke-width: 1.5;
  fill: none;
}


/* ===== PROJECT GRID (Homepage) ===== */

.project-grid {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2.5rem 2rem 4rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.project-card {
  position: relative;
  overflow: hidden;
  background: var(--off-white);
  transition: transform 0.3s ease;
}

.project-card:hover {
  transform: translateY(-2px);
}

.project-card a {
  display: block;
  border-bottom: none;
}

.project-card__image {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  display: block;
  transition: opacity 0.3s ease;
}

.project-card:hover .project-card__image {
  opacity: 0.92;
}

.project-card__info {
  padding: 1rem 0.25rem;
}

.project-card__title {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 400;
  color: var(--black);
  line-height: 1.3;
  margin-bottom: 0.25rem;
}

.project-card__meta {
  font-size: 0.75rem;
  color: var(--gray-mid);
  letter-spacing: 0.03em;
}

.project-card__type {
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--gray-light);
  margin-top: 0.35rem;
}


/* ===== PAGE CONTENT (Project pages, About, etc.) ===== */

.page-content {
  max-width: var(--max-width-narrow);
  margin: 0 auto;
  padding: 3rem 2rem 5rem;
}

.page-content h1 {
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 1.5rem;
  color: var(--black);
}

.page-content h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 400;
  line-height: 1.3;
  margin-top: 3rem;
  margin-bottom: 1rem;
  color: var(--black);
}

.page-content h3 {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
  color: var(--black);
}

.page-content h4 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 400;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  color: var(--black);
}

.page-content p {
  margin-bottom: 1.25rem;
  color: var(--gray-dark);
}

.page-content em {
  font-style: italic;
}

.page-content strong {
  font-weight: 600;
  color: var(--black);
}

.page-content blockquote {
  border-left: 2px solid var(--gray-rule);
  padding-left: 1.25rem;
  margin: 2rem 0;
  color: var(--gray-mid);
  font-style: italic;
}

.page-content img {
  margin: 2rem auto;
  max-width: 100%;
  height: auto;
}

/* Constrain tall/portrait images (like zine covers) to a reasonable height */
.page-content img[src*="Cover"],
.page-content img[src*="cover"],
.page-content img[src*="Front"],
.page-content img[src*="Issue"] {
  max-height: 500px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
}

/* When multiple images appear consecutively, display them in a row */
.page-content p > img {
  display: inline-block;
  vertical-align: top;
}

/* WordPress gallery blocks and columns */
.page-content .wp-block-gallery,
.page-content .gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin: 2rem 0;
}

.page-content .wp-block-gallery img,
.page-content .gallery img {
  margin: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* WordPress image blocks that sit side by side */
.page-content .wp-block-columns {
  display: flex;
  gap: 1rem;
  margin: 2rem 0;
}

.page-content .wp-block-columns .wp-block-column {
  flex: 1;
}

.page-content .wp-block-columns img {
  margin: 0;
  width: 100%;
  object-fit: cover;
}

.page-content hr {
  border: none;
  border-top: 1px solid var(--gray-rule);
  margin: 3rem 0;
}

.page-content a {
  border-bottom-color: var(--gray-light);
}

.page-content a:hover {
  border-bottom-color: var(--black);
}

/* Wide images that break out of the narrow column */
.page-content .wide-image {
  max-width: var(--max-width);
  margin-left: calc(-1 * (var(--max-width) - var(--max-width-narrow)) / 2);
  width: var(--max-width);
}

/* Image gallery within project pages */
.page-content .gallery-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin: 2rem 0;
}

.page-content .gallery-row img {
  margin: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}


/* ===== OTHER WORKS PAGE ===== */

.works-page {
  max-width: var(--max-width);
  padding: 3rem 2rem 5rem;
}

.works-page h1 {
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 2.5rem;
}

.works-section {
  margin-bottom: 1rem;
}

.works-section h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 400;
  margin-top: 0;
  margin-bottom: 0.25rem;
}

.works-meta {
  font-size: 0.8125rem;
  color: var(--gray-mid);
  margin-bottom: 1.5rem;
  letter-spacing: 0.02em;
}

.works-section p {
  max-width: var(--max-width-narrow);
  margin-bottom: 1.25rem;
  color: var(--gray-dark);
  line-height: 1.75;
  font-size: 0.9375rem;
}

.works-page hr {
  border: none;
  border-top: 1px solid var(--gray-rule);
  margin: 3rem 0;
}

/* 3-column grid for Naiomi, Bryan & Manu, Cartimar */
.works-grid--3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin: 2rem 0;
}

.works-figure {
  margin: 0;
  overflow: hidden;
}

.works-figure img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  display: block;
  margin: 0;
}

.works-figure figcaption {
  font-size: 0.8rem;
  color: var(--gray-mid);
  font-style: italic;
  text-align: center;
  margin-top: 0.5rem;
}

/* 4-column grid with tall right column for Women Who Raised Me */
.works-grid--4tall {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 1rem;
  margin: 2rem 0;
}

.works-col-pair {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.works-col-pair .works-figure img {
  height: 200px;
}

.works-col-tall {
  display: flex;
}

.works-col-tall .works-figure {
  width: 100%;
}

.works-col-tall .works-figure img {
  height: 100%;
  min-height: 415px;
}

/* Bryan & Manu and Cartimar get slightly taller images */
.works-section:nth-of-type(3) .works-figure img,
.works-section:nth-of-type(4) .works-figure img {
  height: 300px;
}

/* Responsive */
@media (max-width: 900px) {
  .works-grid--4tall {
    grid-template-columns: 1fr 1fr;
  }

  .works-col-tall {
    grid-column: span 2;
  }

  .works-col-tall .works-figure img {
    min-height: 300px;
    height: 300px;
  }
}

@media (max-width: 640px) {
  .works-grid--3 {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .works-grid--4tall {
    grid-template-columns: 1fr;
  }

  .works-col-tall {
    grid-column: span 1;
  }

  .works-figure img {
    height: 250px !important;
  }

  .works-col-tall .works-figure img {
    min-height: 250px;
    height: 250px;
  }

  .works-page h1 {
    font-size: 1.75rem;
  }
}


/* ===== ABOUT PAGE ===== */

.about-layout {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 3rem 2rem 5rem;
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 4rem;
  align-items: start;
}

.about-image img {
  width: 100%;
  object-fit: cover;
}

/* Hide any small logo/icon images embedded in the About page content */
.about-text img {
  display: none;
}

.about-text h1 {
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 1.5rem;
}

.about-text p {
  font-size: 0.9375rem;
  margin-bottom: 1.25rem;
  color: var(--gray-dark);
  line-height: 1.75;
}

.about-text h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 400;
  line-height: 1.3;
  margin-bottom: 1rem;
  color: var(--black);
}

.about-contact {
  margin-top: 3rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--gray-rule);
}

.about-contact p {
  font-size: 0.9375rem;
  color: var(--gray-dark);
  line-height: 1.75;
}

.contact-links {
  list-style: none;
  padding: 0;
  margin-top: 1.5rem;
}

.contact-links li {
  display: flex;
  align-items: baseline;
  gap: 1.5rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--gray-rule);
}

.contact-links li:last-child {
  border-bottom: none;
}

.contact-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gray-mid);
  min-width: 5.5rem;
}

.contact-links a {
  font-size: 0.9375rem;
  color: var(--black);
  border-bottom: 1px solid var(--gray-light);
}

.contact-links a:hover {
  border-bottom-color: var(--black);
}


/* ===== SITE FOOTER ===== */

.site-footer {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem;
  border-top: 1px solid var(--gray-rule);
}

.site-footer__inner {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.site-footer__copy {
  font-size: 0.75rem;
  color: var(--gray-light);
  letter-spacing: 0.02em;
}

.site-footer__links {
  display: flex;
  gap: 1.5rem;
}

.site-footer__links a {
  font-size: 0.75rem;
  color: var(--gray-light);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: none;
  transition: color 0.2s ease;
}

.site-footer__links a:hover {
  color: var(--black);
}


/* ===== RESPONSIVE ===== */

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

  .about-layout {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .about-image {
    max-width: 400px;
  }
}

@media (max-width: 640px) {
  .site-header__inner {
    flex-direction: column;
    gap: 1rem;
  }

  .site-nav {
    display: none;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
    padding-top: 0.5rem;
  }

  .site-nav.is-open {
    display: flex;
  }

  .nav-toggle {
    display: block;
    position: absolute;
    top: 2.5rem;
    right: 2rem;
  }

  .site-header {
    position: relative;
  }

  .project-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 1.5rem 1.5rem 3rem;
  }

  .project-card__image {
    aspect-ratio: 3 / 4;
  }

  .page-content {
    padding: 2rem 1.5rem 3rem;
  }

  .page-content h1 {
    font-size: 1.75rem;
  }

  .site-header {
    padding: 2rem 1.5rem 1.5rem;
  }

  .site-footer {
    padding: 1.5rem;
  }

  .site-footer__inner {
    flex-direction: column;
    gap: 1rem;
  }

  .page-content .wide-image {
    max-width: 100%;
    margin-left: 0;
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    animation: none !important;
  }
}
