/* ============================================
   PILAR BELTRÁN — pilarbeltran.info
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Bodoni+Moda:ital,opsz,wght@0,6..96,400;0,6..96,700;1,6..96,400&family=Inter:wght@400;700&family=Cormorant+Upright:wght@300;400;500&family=IBM+Plex+Serif:ital,wght@0,300;0,400;1,300&family=DM+Sans:wght@300;400;500&display=swap');

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

:root {
  --black: #000000;
  --white: #ffffff;
  --gray: #888888;
  --border: #cccccc;
  --transition: 0.35s ease;
}

html { font-size: 18px; }

body {
  font-family: 'IBM Plex Serif', serif;
  font-weight: 300;
  background: var(--white);
  color: var(--black);
  line-height: 1.5;
}

a {
  color: var(--black);
  text-decoration: underline;
}

a:hover { opacity: 0.6; }

/* ── Site header ─────────────────────────── */
.site-header {
  padding: 28px 40px 0;
}

.site-header-top {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.site-logo {
  font-family: 'Bodoni 72', 'Bodoni 72 Book', 'Bodoni Moda', 'Bodoni MT', serif;
  font-size: 2rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--black);
  display: inline-block;
  margin-bottom: 0;
  border-bottom: 1px solid var(--black);
  padding-bottom: 10px;
  cursor: default;
  position: relative;
}

.site-logo .logo-default,
.site-logo .logo-hover {
  display: block;
  transition: opacity 0.4s ease;
}

.site-logo .logo-hover {
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0;
  white-space: nowrap;
}

.site-logo:hover .logo-default {
  opacity: 0;
}

.site-logo:hover .logo-hover {
  opacity: 1;
}

.logo-simbolo {
  display: inline-block;
  height: 0.9em;
  width: auto;
  vertical-align: top;
  margin-left: 4px;
  position: relative;
  top: 0.26em;
  opacity: 0.85;
  mix-blend-mode: multiply;
  cursor: default;
}

.simbolo-preview {
  position: fixed;
  z-index: 999;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.25s ease;
  background: transparent;
  mix-blend-mode: multiply;
}

.simbolo-preview.visible {
  opacity: 1;
}

.simbolo-preview img {
  width: 240px;
  height: auto;
  display: block;
  background: transparent;
  mix-blend-mode: multiply;
  filter: contrast(1.1);
}

/* ── Language switcher ───────────────────── */
.lang-switcher {
  display: flex;
  gap: 16px;
  padding: 6px 0 10px;
}

.lang-switcher a {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 0.75rem;
  color: var(--gray);
  text-decoration: none;
  letter-spacing: 0.05em;
}

.lang-switcher a.active,
.lang-switcher a:hover {
  color: var(--black);
}

/* ── Top nav ─────────────────────────────── */
.top-nav {
  display: flex;
  justify-content: flex-end;
  align-items: flex-end;
  gap: 28px;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--black);
  padding-bottom: 10px;
}

.top-nav a {
  font-family: 'Bodoni 72', 'Bodoni 72 Book', 'Bodoni Moda', 'Bodoni MT', serif;
  font-size: 1.55rem;
  font-weight: 400;
  color: var(--black);
  text-decoration: none;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.top-nav a:hover {
  text-decoration: none;
  opacity: 0.5;
}

.top-nav a.active {
  text-decoration: none;
  background-image: radial-gradient(circle, var(--black) 1.5px, transparent 1.5px);
  background-size: 6px 1px;
  background-position: 0 100%;
  background-repeat: repeat-x;
  padding-bottom: 3px;
}

/* ── Page content ────────────────────────── */
.page-content {
  max-width: 1100px;
  margin: 0 auto;
  padding: 40px 40px 80px;
}

/* ── Section title (big heading) ─────────── */
.section-heading {
  font-family: 'Bodoni 72', 'Bodoni 72 Book', 'Bodoni Moda', 'Bodoni MT', serif;
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  margin-bottom: 28px;
}

/* ── Greeting ────────────────────────────── */
.greeting {
  font-family: 'Cormorant Upright', serif;
  font-weight: 400;
  font-size: 4.375rem; /* 70px */
  line-height: 1;
  margin-bottom: 20px !important;
}

/* ── About layout ────────────────────────── */
.about-intro {
  margin-bottom: 40px;
  overflow: visible;
}

.about-intro::after {
  content: '';
  display: table;
  clear: both;
}

.about-intro-text p {
  clear: none;
}

.about-photo {
  float: right;
  width: 46%;
  display: block;
  margin: 48px 0 24px 40px;
}

.about-intro-text {
  font-size: 0.97rem;
  line-height: 1.75;
  overflow: visible;
}

.about-intro-text p {
  margin-bottom: 14px;
  text-align: justify;
}

.about-intro-text p:last-child {
  margin-bottom: 0;
}

/* ── Subsection (contemporary dance, poetry, etc.) ── */
.subsection {
  margin-top: 60px;
  padding-top: 0;
}

.subsection-title {
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 16px;
  text-transform: lowercase;
}



.subsection-content {
  font-size: 0.97rem;
  line-height: 1.75;
  text-align: justify;
}

.subsection-content p {
  margin-bottom: 14px;
}

/* ── Works Grid ──────────────────────────── */
/*
  Full 20-row layout as specified
*/
.works-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: 220px;
  gap: 32px;
}

.works-item {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-self: stretch;
}

.works-item img {
  width: 100%;
  flex: 1;
  min-height: 0;
  height: 0;
  display: block;
  object-fit: cover;
  transition: opacity 0.25s;
}

.works-item img:hover { opacity: 0.85; }

.works-item-title {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 0.68rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--black);
  margin-top: 6px;
  flex-shrink: 0;
  line-height: 1.4;
}

.wi-1 { grid-column: 1; grid-row: 1; }
.wi-2 { grid-column: 2/4; grid-row: 1; }
.wi-3 { grid-column: 1/3; grid-row: 2/4; }
.wi-4 { grid-column: 3; grid-row: 2/4; }
.wi-5 { grid-column: 1; grid-row: 4; }
.wi-6 { grid-column: 2; grid-row: 4; }
.wi-7 { grid-column: 3; grid-row: 4; }
.wi-8 { grid-column: 1/3; grid-row: 5; }
.wi-9 { grid-column: 3; grid-row: 5; }
.wi-10 { grid-column: 1; grid-row: 6/8; }
.wi-11 { grid-column: 2/4; grid-row: 6; }
.wi-12 { grid-column: 2/4; grid-row: 7/9; }
.wi-13 { grid-column: 1; grid-row: 8; }
.wi-14 { grid-column: 1/3; grid-row: 9; }
.wi-15 { grid-column: 3; grid-row: 9/11; }
.wi-16 { grid-column: 1; grid-row: 10; }
.wi-17 { grid-column: 2; grid-row: 10; }
.wi-18 { grid-column: 1/3; grid-row: 11/13; }
.wi-19 { grid-column: 3; grid-row: 11; }
.wi-20 { grid-column: 3; grid-row: 12; }
.wi-21 { grid-column: 1; grid-row: 13/15; }
.wi-22 { grid-column: 2/4; grid-row: 13; }
.wi-23 { grid-column: 2; grid-row: 14; }
.wi-24 { grid-column: 3; grid-row: 14; }
.wi-25 { grid-column: 1; grid-row: 15; }
.wi-26 { grid-column: 2; grid-row: 15; }
.wi-27 { grid-column: 3; grid-row: 15; }
.wi-28 { grid-column: 1/3; grid-row: 16; }
.wi-29 { grid-column: 3; grid-row: 16; }
.wi-30 { grid-column: 1; grid-row: 17/19; }
.wi-31 { grid-column: 2/4; grid-row: 17/19; }
.wi-32 { grid-column: 1; grid-row: 19; }
.wi-33 { grid-column: 2; grid-row: 19; }
.wi-34 { grid-column: 3; grid-row: 19; }
.wi-35 { grid-column: 1/3; grid-row: 20; }
.wi-36 { grid-column: 3; grid-row: 20; }
.wi-37 { grid-column: 1; grid-row: 21; }
.wi-38 { grid-column: 2; grid-row: 21; }
.wi-39 { grid-column: 3; grid-row: 21; }

.section-intro {
  font-size: 0.88rem;
  line-height: 1.75;
  text-align: justify;
  margin-bottom: 28px;
  max-width: 580px;
}

/* ── Collective Projects Grid ────────────── */
.collective-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: 220px;
  gap: 32px;
}

.ci {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-self: stretch;
}

.ci img {
  width: 100%;
  flex: 1;
  min-height: 0;
  height: 0;
  display: block;
  object-fit: cover;
  transition: opacity 0.25s;
}

.ci img:hover { opacity: 0.85; }

/*
  Layout key:
  [1col]      = 1 column, 1 row
  [2col]      = 2 columns, 1 row
  [1x2col]    = 1 column, 2 rows tall
  [2colx2row] = 2 columns, 2 rows tall

  r1:  [1col] [2col         ]           → 1+2
  r2:  [2colx2row    ] [1x2col]         → 3+4
  r3:  (continuation of r2)
  r4:  [1col] [1col] [1col]             → 5+6+7
  r5:  [2col         ] [1col]           → 8+9
  r6:  [1x2col] [2col        ]          → 10+11
  r7:  (ci-10 cont)  [2colx2row]        → 12 starts (cols 2-3, rows 7-8)
  r8:  [1col] [1col] (ci-12 cont)       → 13+14
  r9:  [2col         ]  [1x2col]        → 15+16
  r10: [1col] [1col] (ci-16 cont)       → 17+18
  r11: [2colx2row    ] [1col]           → 19+20
  r12: (ci-19 cont)   [1col]            → 21
  r13: [1x2col] [2col        ]          → 22+23
  r14: (ci-22 cont)  [1col] [1col]      → 24+25
  r15: [1col] [1col] [1col]             → 26+27+28
  r16: [2col         ] [1col]           → 29+30
  r17: [1x2col] [2colx2row   ]          → 31+32
  r18: (both cont)
  r19: [1col] [1col] [1col]             → 33+34+35
  r20: [2col         ] [1col]           → 36+37
*/

/* Collective Projects — 15 items, 6 rows */
/* Collective Projects — 15 items, Works-style layout */
/* Collective Projects — 15 items */
/* Collective Projects — 40 items, 20-row layout */
.ci-1 { grid-column: 1; grid-row: 1; }
.ci-2 { grid-column: 2; grid-row: 1; }
.ci-3 { grid-column: 3; grid-row: 1; }
.ci-4 { grid-column: 1; grid-row: 2; }
.ci-5 { grid-column: 2/4; grid-row: 2; }
.ci-6 { grid-column: 1/3; grid-row: 3/5; }
.ci-7 { grid-column: 3; grid-row: 3; }
.ci-8 { grid-column: 3; grid-row: 4/6; }
.ci-9 { grid-column: 1; grid-row: 5; }
.ci-10 { grid-column: 2; grid-row: 5; }
.ci-11 { grid-column: 1/3; grid-row: 6; }
.ci-12 { grid-column: 3; grid-row: 6; }
.ci-13 { grid-column: 1; grid-row: 7; }
.ci-14 { grid-column: 2; grid-row: 7/9; }
.ci-15 { grid-column: 3; grid-row: 7; }
.ci-16 { grid-column: 1; grid-row: 8/10; }
.ci-17 { grid-column: 3; grid-row: 8; }
.ci-18 { grid-column: 2; grid-row: 9; }
.ci-19 { grid-column: 3; grid-row: 9; }
.ci-20 { grid-column: 1; grid-row: 10; }
.ci-21 { grid-column: 2/4; grid-row: 10/12; }
.ci-22 { grid-column: 1; grid-row: 11; }
.ci-23 { grid-column: 1; grid-row: 12; }
.ci-24 { grid-column: 2; grid-row: 12; }
.ci-25 { grid-column: 3; grid-row: 12; }
.ci-26 { grid-column: 1/3; grid-row: 13; }
.ci-27 { grid-column: 3; grid-row: 13/15; }
.ci-28 { grid-column: 1; grid-row: 14; }
.ci-29 { grid-column: 2; grid-row: 14; }
.ci-30 { grid-column: 1/3; grid-row: 15/17; }
.ci-31 { grid-column: 3; grid-row: 15; }
.ci-32 { grid-column: 3; grid-row: 16; }
.ci-33 { grid-column: 1; grid-row: 17; }
.ci-34 { grid-column: 2/4; grid-row: 17; }
.ci-35 { grid-column: 1; grid-row: 18/20; }
.ci-36 { grid-column: 2/4; grid-row: 18; }
.ci-37 { grid-column: 2; grid-row: 19; }
.ci-38 { grid-column: 3; grid-row: 19; }
.ci-39 { grid-column: 1/3; grid-row: 20; }
.ci-40 { grid-column: 3; grid-row: 20; }


.masonry-item-title {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 0.68rem; font-weight: 400;
  text-transform: uppercase; letter-spacing: .06em;
  color: var(--black); margin-top: 6px;
  line-height: 1.4;
}

/* ── Blog ────────────────────────────────── */
.blog-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.blog-entry {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 36px;
  padding: 40px 0;
  align-items: stretch;
}

.blog-entry img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.blog-entry-body {
  padding-top: 4px;
}

.blog-entry-title {
  font-family: 'Bodoni 72', 'Bodoni 72 Book', 'Bodoni Moda', 'Bodoni MT', serif;
  font-size: 1.05rem;
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0.01em;
  margin-bottom: 6px;
  line-height: 1.3;
}

.blog-entry-date {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 0.72rem;
  font-weight: 400;
  color: var(--black);
  margin-bottom: 14px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.blog-entry-excerpt {
  font-family: 'IBM Plex Serif', serif;
  font-size: 0.97rem;
  font-weight: 300;
  color: var(--black);
  line-height: 1.75;
  text-align: justify;
  display: -webkit-box;
  -webkit-line-clamp: 6;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ── Workshops ───────────────────────────── */
.workshop-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.workshop-entry {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 28px;
  padding: 28px 0;
  border-bottom: 1px solid var(--border);
  align-items: start;
}

.workshop-entry:first-child {
  border-top: 1px solid var(--border);
}

.workshop-entry img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}

.workshop-entry-label {
  font-size: 0.72rem;
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 6px;
}

.workshop-entry-title {
  font-family: 'IBM Plex Serif', serif;
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 10px;
  line-height: 1.3;
}

.workshop-entry-desc {
  font-size: 0.85rem;
  line-height: 1.75;
  color: #333;
  text-align: justify;
}

/* ── Contact ─────────────────────────────── */
.contact-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.contact-item {
  margin-bottom: 20px;
}

.contact-item-label {
  font-size: 0.72rem;
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 4px;
}

.contact-item-value {
  font-size: 0.92rem;
}

/* ── Newsletter ──────────────────────────── */
.newsletter-toggle {
  font-family: 'IBM Plex Serif', serif;
  font-size: 0.92rem;
  font-weight: 300;
  color: var(--black);
  background: none;
  border: none;
  border-bottom: 1px solid var(--black);
  padding: 0 0 2px;
  cursor: pointer;
  transition: opacity 0.2s;
}

.newsletter-toggle:hover { opacity: 0.5; }

.newsletter-form {
  margin-top: 40px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  max-width: 480px;
  overflow: hidden;
  transition: opacity 0.35s ease, transform 0.35s ease;
  opacity: 0;
  transform: translateY(-8px);
}

.newsletter-form.open {
  opacity: 1;
  transform: translateY(0);
}

.newsletter-desc {
  font-size: 0.88rem;
  line-height: 1.7;
  color: #444;
  margin-bottom: 20px;
}

.newsletter-fields {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.newsletter-input {
  font-family: 'IBM Plex Serif', serif;
  font-size: 0.88rem;
  font-weight: 300;
  border: none;
  border-bottom: 1px solid var(--border);
  padding: 6px 0;
  outline: none;
  background: transparent;
  color: var(--black);
  transition: border-color 0.2s;
}

.newsletter-input:focus { border-bottom-color: var(--black); }

.newsletter-submit {
  margin-top: 8px;
  align-self: flex-start;
  font-family: 'IBM Plex Serif', serif;
  font-size: 0.88rem;
  font-weight: 300;
  color: var(--white);
  background: var(--black);
  border: none;
  padding: 8px 24px;
  cursor: pointer;
  transition: opacity 0.2s;
}

.newsletter-submit:hover { opacity: 0.7; }

.newsletter-thanks {
  margin-top: 14px;
  font-size: 0.85rem;
  color: #555;
  font-style: italic;
}

/* ── CV ──────────────────────────────────── */
.cv-header {
  margin-bottom: 40px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.cv-header-name {
  font-family: 'Bodoni 72', 'Bodoni 72 Book', 'Bodoni Moda', serif;
  font-size: 1.6rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.cv-header-info {
  font-size: 0.78rem;
  color: #444;
  line-height: 1.6;
}

.cv-full {
  margin-top: 40px;
}

.cv-cols-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0 40px;
}

.cv-entry-role {
  font-size: 0.78rem;
  color: var(--gray);
  margin-bottom: 2px;
  line-height: 1.4;
}

.fal-tooltip {
  cursor: default;
  position: relative;
  border-bottom: 1px dotted var(--gray);
}

.fal-popup {
  position: fixed;
  z-index: 999;
  background: white;
  border: 1px solid var(--border);
  padding: 6px 12px;
  font-size: 0.72rem;
  font-family: 'IBM Plex Serif', serif;
  font-weight: 300;
  color: var(--black);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
  white-space: nowrap;
}

.fal-popup.visible {
  opacity: 1;
}

.cv-entry-note {
  font-size: 0.75rem;
  color: #888;
  line-height: 1.4;
  margin-bottom: 2px;
  font-style: italic;
}
.cv-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

.cv-group {
  margin-bottom: 32px;
}

.cv-group-title {
  font-family: 'IBM Plex Serif', serif;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--gray);
  border-bottom: 1px solid var(--border);
  padding-bottom: 6px;
  margin-bottom: 14px;
}

.cv-entry {
  margin-bottom: 10px;
}

.cv-entry-year {
  font-size: 0.72rem;
  color: var(--gray);
  margin-bottom: 2px;
}

.cv-entry-desc {
  font-size: 0.85rem;
  line-height: 1.5;
  color: #222;
}

/* ── Link preview tooltip ────────────────── */
.link-preview-tooltip {
  position: fixed;
  z-index: 9999;
  pointer-events: none;
  background: var(--white);
  border: 1px solid var(--border);
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
  width: 280px;
  opacity: 0;
  transition: opacity 0.2s ease;
  overflow: hidden;
}

.link-preview-tooltip.visible {
  opacity: 1;
}

.link-preview-tooltip img {
  width: 100%;
  display: block;
  object-fit: cover;
}

.link-preview-tooltip-title:empty {
  display: none;
}

.link-preview-tooltip-title {
  padding: 8px 10px;
  font-size: 0.72rem;
  color: #444;
  line-height: 1.4;
  font-family: 'IBM Plex Serif', serif;
  font-weight: 300;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Responsive ──────────────────────────── */
@media (max-width: 680px) {
  .site-header,
  .top-nav,
  .page-content {
    padding-left: 20px;
    padding-right: 20px;
  }

  .about-intro {
    grid-template-columns: 1fr;
  }

  .about-photo {
    max-width: 260px;
  }

  .image-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .blog-entry,
  .workshop-entry {
    grid-template-columns: 1fr;
  }

  .contact-block,
  .cv-cols {
    grid-template-columns: 1fr;
  }

  .top-nav {
    justify-content: flex-start;
    gap: 16px;
  }
}
