body {
    background: var(--bg);
    color: var(--ink);
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
  }

body.page-no-hero header {
    background: rgba(26,26,24,0.55);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
  }

footer {
    background: var(--ink);
    color: rgba(255,255,255,0.85);
    padding: var(--sp-100) 0 var(--sp-25);
  }

.footer-bottom a:hover,
  .footer-bottom a.active-legal {
    color: rgba(255,255,255,0.9);
    border-bottom-color: rgba(255,255,255,0.6);
  }

@media (max-width: 860px) {
    .about { grid-template-columns: 1fr; gap: var(--sp-50); }
    .about-text { padding-left: 0; }
    .about::before { display: none; }
    .projects-grid { grid-template-columns: 1fr; }
    .hero-row { grid-template-columns: 1fr; gap: var(--sp-50); }
    .hero-title-col, .hero-meta-col { padding: 0; text-align: left; }
    .hero-title { font-size: 30px; }
    .hero-gutter { display: none; }
  }

.bio-grid {
    display: grid;
    grid-template-columns: 0.85fr 1.15fr;
    gap: var(--sp-100);
    align-items: start;
  }

.portrait-photo {
    width: 100%;
    aspect-ratio: 4 / 5;
    overflow: hidden;
    background: var(--panel);
  }

.portrait-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
  }

.portrait-placeholder {
    width: 100%;
    aspect-ratio: 4 / 5;
    border: 1px dashed var(--line);
    background: var(--panel);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 10px;
    color: var(--ink-soft);
    text-align: center;
    padding: 20px;
  }

.portrait-placeholder svg { width: 40px; height: 40px; opacity: 0.5; }

.portrait-placeholder span {
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
  }

.bio-text p {
    font-size: 15px;
    line-height: 1.9;
    color: var(--ink-soft);
    font-weight: 300;
    max-width: 560px;
  }

.bio-text p + p { margin-top: var(--sp-25); }

.edu-list { margin-top: var(--sp-100); border-top: 1px solid var(--line); }

.skills-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: var(--sp-50);
  }

.skill-tag {
    border: 1px solid var(--line);
    padding: 10px 18px;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-soft);
    transition: border-color 0.25s ease, color 0.25s ease;
  }

.skill-tag:hover {
    border-color: var(--ink);
    color: var(--ink);
  }

.edu-item {
    display: flex;
    justify-content: space-between;
    padding: var(--sp-25) 0;
    border-bottom: 1px solid var(--line);
    gap: var(--sp-50);
  }

.edu-year {
    font-size: calc(12px + 2pt);
    letter-spacing: 0.1em;
    color: var(--ink-soft);
    white-space: nowrap;
    padding-top: 3px;
  }

.edu-title {
    font-size: 16px;
    font-weight: 300;
    color: var(--ink-soft);
    text-align: right;
    white-space: nowrap;
  }

.edu-title b, .edu-title strong { font-weight: 400; color: var(--ink); }

.edu-link {
    color: inherit;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
  }

.edu-link:hover { border-bottom-color: var(--ink); }

.pull-quote {
    font-family: 'Montserrat', sans-serif;
    font-weight: 200;
    font-size: 32px;
    line-height: 1.5;
    color: var(--ink);
    max-width: 780px;
    text-align: center;
    margin: 0 auto;
  }

.cta-center { text-align: center; padding: var(--sp-100) 0; }

.quotes-carousel {
    position: relative;
    background: var(--panel);
    overflow: hidden;
    transition: height 0.6s ease;
  }

.quote-mark { display: none; }

.quote-slide {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: var(--sp-75) var(--sp-100);
    opacity: 0;
    transition: opacity 1s ease;
  }

.quote-slide.active { opacity: 1; }

.quote-inner {
    position: relative;
  }

.quote-slide p {
    position: relative;
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    font-weight: 500;
    font-size: 30px;
    line-height: 1.25;
    color: var(--ink);
    max-width: 720px;
    text-align: center;
  }

.quote-slide p::before,
  .quote-slide p::after {
    position: absolute;
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    font-size: 170px;
    line-height: 1;
    color: var(--beige);
    pointer-events: none;
  }

.quote-slide p::before {
    content: '\201C';
    top: -70px;
    left: -60px;
  }

.quote-slide p::after {
    content: '\201D';
    bottom: -110px;
    right: -60px;
  }

.quote-slide span {
    display: block;
    margin-top: var(--sp-50);
    font-family: 'Montserrat', sans-serif;
    font-size: 16px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--ink-soft);
    text-align: center;
  }

@media (max-width: 860px) {
    .quote-slide { padding: var(--sp-50) var(--sp-25); }
    .quote-slide p { font-size: 22px; }
    .quote-mark { font-size: 80px; left: var(--sp-25); }
  }

@media (max-width: 860px) {
    /* Падинг над "За контакт" - намален наполовина на мобилни устройства. */
    footer { padding-top: 50px; }

    .bio-grid { grid-template-columns: 1fr; gap: var(--sp-50); }
    .edu-item { flex-direction: column; gap: 6px; }
    .edu-title { text-align: left; white-space: normal; }
    .pull-quote { font-size: 24px; }
  }

.legal-section {
    padding-bottom: var(--sp-50);
    margin-bottom: var(--sp-50);
    border-bottom: 1px solid var(--line);
  }

.legal-section:last-child { border-bottom: none; }

.legal-index {
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    font-size: 13px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--ink);
    margin-bottom: var(--sp-25);
  }

.legal-text p {
    font-size: 15px;
    line-height: 1.9;
    color: var(--ink-soft);
    font-weight: 300;
  }

.legal-text p + p { margin-top: var(--sp-25); }

.legal-updated {
    font-size: 12px;
    letter-spacing: 0.08em;
    color: var(--ink-soft);
    margin-bottom: var(--sp-75);
  }
