/* ── Material Symbols ── */
.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  vertical-align: middle;
}

/* ── Base typography ── */
body {
  font-family: 'Work Sans', sans-serif;
  background-color: #ffffff;
  color: #1b1c15;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
.serif-font {
  font-family: 'Newsreader', serif;
}

/* ── Utility class used in various places ── */
.marginalia {
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ── Legacy layout helpers (used by detail pages) ── */
.container {
  max-width: 64rem;
  margin: 0 auto;
  padding: 2.5rem 3rem 5rem;
}

.back-link {
  color: #8e4d27;
  text-decoration: none;
  font-size: 0.875rem;
  display: inline-block;
  margin-bottom: 2rem;
}

.back-link:hover {
  text-decoration: underline;
}

header.compact h1 {
  font-family: 'Newsreader', serif;
  font-size: 2.5rem;
  font-weight: 300;
  color: #1b1c15;
  margin-bottom: 0.5rem;
  max-width: 720px;
  overflow-wrap: break-word;
}

.subtitle {
  color: #53433c;
  font-size: 1.1rem;
  font-weight: 300;
  word-break: normal;
  white-space: normal;
  overflow-wrap: break-word;
  display: block;
  max-width: 100%;
}

/* ── Home hero/profile image responsive fix ── */
@media (max-width: 600px) {
  .w-full.h-full.object-cover {
    max-width: 100vw;
    min-width: 200px;
    width: 100%;
    height: auto;
    display: block;
    box-sizing: border-box;
  }

  .w-3\/4.max-w-\[320px\].min-w-\[180px\].aspect-\[4\/5\] {
    min-width: 200px;
    max-width: 100vw;
    width: 100%;
    box-sizing: border-box;
    overflow-x: auto;
  }
}

/* ── Home layout ── */
:root {
  --home-portrait-width: 230px;
}

.home-panel {
  position: relative;
  overflow: hidden;
  background: transparent;
  border: 1px solid rgba(217, 194, 184, 0.32);
  box-shadow: none;
}

.home-panel::before,
.home-panel::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.home-panel-inner {
  position: relative;
}

.cv-box {
  position: relative;
  overflow: hidden;
  border-radius: 0;
  background: #ffffff;
}

.cv-box::before,
.cv-box::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.cv-box.bg-surface-container-low {
  background: rgba(238, 238, 238, 0.82);
}

.cv-box.bg-surface-container-low::before {
  top: -8%;
  right: -6%;
  width: 22%;
  height: 22%;
  background: rgba(86, 100, 43, 0.05);
  clip-path: polygon(26% 0, 100% 0, 78% 100%, 0 68%);
}

.cv-box.bg-surface-container-low::after {
  left: -5%;
  bottom: -8%;
  width: 18%;
  height: 20%;
  background: rgba(217, 138, 95, 0.06);
  clip-path: polygon(0 0, 74% 18%, 100% 100%, 18% 84%);
}

.home-header-grid {
  align-items: stretch;
}

.home-hero-panel {
  min-height: auto;
}

.home-hero-panel::before {
  top: -12%;
  right: -6%;
  width: 24%;
  height: 58%;
  background: linear-gradient(180deg, rgba(217, 138, 95, 0.11) 0%, rgba(217, 138, 95, 0.02) 100%);
  clip-path: polygon(40% 0, 100% 0, 82% 66%, 56% 100%, 0 78%);
}

.home-hero-panel::after {
  left: -4%;
  bottom: -12%;
  width: 18%;
  height: 32%;
  background: linear-gradient(180deg, rgba(86, 100, 43, 0.08) 0%, rgba(86, 100, 43, 0.01) 100%);
  clip-path: polygon(0 30%, 70% 0, 100% 60%, 26% 100%);
}

.home-hero-panel .home-hero-actions {
  padding-top: 0.25rem;
}

.home-portrait-panel {
  display: flex;
  flex-direction: column;
  justify-content: stretch;
  width: 100%;
  max-width: 100%;
  margin-left: 0;
}

.home-portrait-panel::before {
  top: -6%;
  left: -8%;
  width: 26%;
  height: 22%;
  background: rgba(94, 94, 94, 0.06);
  clip-path: polygon(0 18%, 76% 0, 100% 52%, 24% 100%);
}

.home-portrait-frame {
  position: relative;
  flex: 1;
  aspect-ratio: 4 / 5;
  background: rgba(238, 238, 238, 0.82);
}

.home-portrait-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.home-portrait-caption {
  position: absolute;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 0.9rem;
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(8px);
}

.home-profile-panel::before {
  top: -8%;
  right: -6%;
  width: 22%;
  height: 22%;
  background: rgba(86, 100, 43, 0.05);
  clip-path: polygon(26% 0, 100% 0, 78% 100%, 0 68%);
}

.home-profile-panel::after {
  left: -5%;
  bottom: -8%;
  width: 18%;
  height: 20%;
  background: rgba(217, 138, 95, 0.06);
  clip-path: polygon(0 0, 74% 18%, 100% 100%, 18% 84%);
}

.home-profile-panel {
  background: rgba(238, 238, 238, 0.82);
}

.home-profile-copy p {
  max-width: 62ch;
  font-size: 1.02rem;
  line-height: 1.85;
}

.home-profile-footer {
  border-top: 1px solid rgba(217, 194, 184, 0.35);
}

.home-profile-footer-grid,
.professional-connections-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.home-profile-footer .group,
.professional-connections-grid .group {
  position: relative;
  min-height: 100%;
  align-items: flex-start;
  padding: 0.95rem 1rem;
  background: #ffffff;
  border: 1px solid rgba(217, 194, 184, 0.18);
  transition: background-color 180ms ease, border-color 180ms ease;
}

.home-profile-footer .group::before,
.home-explore-list li a::before {
  display: none;
}

.home-profile-footer .group:hover,
.professional-connections-grid .group:hover {
  background: #ffffff;
  border-color: rgba(217, 194, 184, 0.24);
}

.home-explore-panel::before {
  top: -8%;
  right: -6%;
  width: 20%;
  height: 20%;
  background: rgba(94, 94, 94, 0.04);
  clip-path: polygon(22% 0, 100% 0, 100% 66%, 36% 100%, 0 32%);
}

.home-explore-panel::after {
  bottom: -8%;
  left: -8%;
  width: 18%;
  height: 18%;
  background: rgba(86, 100, 43, 0.05);
  clip-path: polygon(0 40%, 68% 0, 100% 62%, 20% 100%);
}

.home-explore-list li a {
  position: relative;
  padding: 0.95rem 1rem;
  background: #ffffff;
  border: 1px solid rgba(217, 194, 184, 0.18);
  transition: background-color 180ms ease, border-color 180ms ease;
}

.home-explore-list li a:hover {
  background: #ffffff;
  border-color: rgba(217, 194, 184, 0.24);
}

/* Remove underline on explore links (including hover/focus/active) */
.home-explore-list li a,
.home-explore-list li a:hover,
.home-explore-list li a:focus,
.home-explore-list li a:active {
  text-decoration: none;
}

/* Also remove underline for elements using the utility class 'no-underline' */
a.no-underline,
a.no-underline:hover,
a.no-underline:focus,
a.no-underline:active {
  text-decoration: none;
}

@media (max-width: 1024px) {

  .home-profile-footer-grid,
  .professional-connections-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  :root {
    --home-portrait-width: 180px;
  }

  .home-panel {
    box-shadow: none;
  }

  .home-portrait-frame,
  .home-profile-footer .group,
  .home-explore-list li a {
    clip-path: none;
  }

  .home-portrait-panel {
    margin: 0 auto;
    width: min(50vw, 100%);
    max-width: 50vw;
  }

  .home-portrait-caption {
    left: 0.75rem;
    right: 0.75rem;
    bottom: 0.75rem;
    padding: 0.65rem 0.75rem;
  }

  .home-profile-copy p {
    font-size: 0.98rem;
  }
}
