/* =========================================================
   SOG Home — lean faculty layout (MUNI-inspired, UEH brand)
   Header search lives in header.css (all pages).
   ========================================================= */

/* ---------- Study strip (quick links) ---------- */
.study-strip {
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.study-strip__grid {
  display: grid;
  grid-template-columns: 1fr;
}

@media (min-width: 900px) {
  .study-strip__grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.study-strip__link {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
  min-width: 0;
  padding: 1.35rem 0.5rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.22rem, 1.55vw, 1.62rem);
  line-height: 1.15;
  letter-spacing: 0.01em;
  white-space: nowrap;
  color: var(--blue);
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  box-shadow: none;
  transition:
    background 0.4s var(--ease-soft),
    color 0.4s var(--ease-soft),
    border-color 0.4s var(--ease-soft),
    box-shadow 0.45s,
    transform 0.45s var(--ease-out);
}

@media (min-width: 720px) {
  .study-strip__link {
    border-bottom: 0;
    border-right: 1px solid var(--line);
    min-height: 88px;
  }
  .study-strip__link:last-child {
    border-right: 0;
  }
}

.study-strip__link:hover,
.study-strip__link:focus-visible {
  box-shadow: 0 0 0 1px rgba(90, 200, 255, 0.45), 0 0 14px rgba(90, 200, 255, 0.28);
  z-index: 1;
}

/* ---------- News (no section title) ---------- */
.news-section {
  padding: clamp(2.5rem, 5vw, 4rem) 0;
  background: var(--paper);
}

.news-layout {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 960px) {
  .news-layout {
    grid-template-columns: 1.15fr 1fr;
    gap: 1.5rem;
    align-items: stretch;
  }
}

.news-feature {
  display: flex;
  flex-direction: column;
  color: inherit;
  height: 100%;
  text-decoration: none !important;
  border: 0;
  box-shadow: none;
  transition: none;
}

.news-feature:hover,
.news-feature:focus-visible {
  opacity: 1;
  transform: none;
  box-shadow: none;
  border: 0;
  outline: none;
}

.news-feature__img {
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: var(--sand);
}

.news-feature__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease);
}

.news-feature:hover .news-feature__img img {
  transform: scale(1.03);
}

.news-feature__body {
  padding: 1.25rem 1.1rem 1rem;
  flex: 1;
}

.news-feature__title {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.5vw, 1.75rem);
  line-height: 1.25;
  color: #28418c;
  margin-bottom: 0.65rem;
  padding-bottom: 0.15em;
  text-decoration: none;
  background-image: linear-gradient(var(--blue), var(--blue));
  background-repeat: no-repeat;
  background-position: left bottom;
  background-size: 0 1.5px;
  transition:
    color 0.25s,
    background-size 0.35s var(--ease);
}

.news-feature:hover .news-feature__title,
.news-feature:focus-visible .news-feature__title {
  color: var(--blue);
  background-size: 100% 1.5px;
}

.news-feature__desc {
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.news-side {
  display: grid;
  gap: 1rem;
}

@media (min-width: 600px) {
  .news-side {
    grid-template-columns: 1fr 1fr;
  }
}

.news-card {
  display: flex;
  flex-direction: column;
  color: inherit;
  padding-bottom: 0.85rem;
  text-decoration: none !important;
  border: 0;
  box-shadow: none;
  transition: none;
}

.news-card:hover,
.news-card:focus-visible {
  opacity: 1;
  transform: none;
  box-shadow: none;
  border: 0;
  outline: none;
}

.news-card__img {
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: var(--sand);
}

.news-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease);
}

.news-card:hover .news-card__img img {
  transform: scale(1.04);
}

.news-card__title {
  font-family: var(--font-display);
  font-size: 1rem;
  line-height: 1.4;
  color: #28418c;
  margin: 0.9rem 1rem 0.15rem;
  padding: 0 0 0.15em;
  text-decoration: none;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  background-image: linear-gradient(var(--blue), var(--blue));
  background-repeat: no-repeat;
  background-position: left bottom;
  background-size: 0 1.5px;
  transition:
    color 0.25s,
    background-size 0.35s var(--ease);
}

.news-card:hover .news-card__title,
.news-card:focus-visible .news-card__title {
  color: var(--blue);
  background-size: 100% 1.5px;
}

.news-more,
.section-more {
  display: flex;
  justify-content: flex-end;
  margin-top: 1.5rem;
}

.news-more a,
.section-more a {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--blue);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.news-more a:hover,
.section-more a:hover {
  color: var(--earth);
}

/* ---------- Events ---------- */
.events-section {
  position: relative;
  background:
    radial-gradient(ellipse 70% 55% at 15% 0%, rgba(64, 140, 255, 0.18), transparent 55%),
    radial-gradient(ellipse 50% 40% at 90% 80%, rgba(90, 200, 255, 0.1), transparent 50%),
    #28418c;
  color: #fff;
  padding: clamp(2.75rem, 5vw, 4.25rem) 0;
  overflow: hidden;
}

.events-section::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(90, 200, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(90, 200, 255, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.55), transparent 90%);
  opacity: 0.7;
}

.events-section .container {
  position: relative;
  z-index: 1;
}

.events-section .section-title {
  color: #fff;
  max-width: none;
  margin-bottom: 1.75rem;
  text-shadow: 0 0 28px rgba(90, 200, 255, 0.25);
}

.events-grid {
  display: grid;
  gap: 2rem 2.75rem;
}

@media (min-width: 700px) {
  .events-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1100px) {
  .events-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Text blocks only — no card chrome (MUNI datebox pattern) */
.event-card {
  position: relative;
  background: transparent;
  border: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-height: 100%;
  box-shadow: none;
  backdrop-filter: none;
}

.event-card::before {
  content: none;
}

.event-card:hover,
.event-card:focus-within {
  border: 0;
  background: transparent;
  box-shadow: none;
  transform: none;
}

.event-card__date {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  color: #7ec8ff;
  letter-spacing: 0.02em;
  line-height: 1.2;
  margin-bottom: 0.15rem;
}

.event-card__title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  line-height: 1.35;
  color: #fff;
}

.event-card__title a {
  color: inherit;
  text-decoration: none !important;
  background-image: linear-gradient(var(--earth), var(--earth));
  background-repeat: no-repeat;
  background-position: left bottom;
  background-size: 0 1.5px;
  padding-bottom: 0.12em;
  transition:
    color 0.25s,
    background-size 0.35s var(--ease);
}

.event-card__title a:hover,
.event-card__title a:focus-visible,
.event-card:focus-within .event-card__title a {
  color: var(--earth);
  background-size: 100% 1.5px;
}

.event-card__meta {
  font-size: 0.82rem;
  color: rgba(200, 220, 255, 0.78);
}

.event-card__desc {
  font-size: 0.88rem;
  color: rgba(230, 236, 248, 0.82);
  line-height: 1.45;
  margin-top: 0.25rem;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.events-section .section-more a {
  color: #9fd4ff;
  text-shadow: 0 0 14px rgba(90, 200, 255, 0.35);
  transition: color 0.25s, text-shadow 0.25s;
}

.events-section .section-more a:hover {
  color: #fff;
  text-shadow: 0 0 20px var(--glow-cyan);
}

.events-section .section-more {
  margin-top: 1.5rem;
}

/* Listing page: light paper + same borderless text blocks */
.events-section.section-paper {
  background:
    linear-gradient(180deg, rgba(40, 65, 140, 0.03), transparent 120px),
    var(--paper);
  color: var(--ink);
}

.events-section.section-paper::before {
  display: none;
}

.events-section.section-paper .section-title {
  color: #28418c;
  text-shadow: none;
}

.events-section.section-paper .event-card__date {
  color: var(--blue);
}

.events-section.section-paper .event-card__title {
  color: #28418c;
}

.events-section.section-paper .event-card__title a {
  background-image: linear-gradient(var(--earth), var(--earth));
}

.events-section.section-paper .event-card__title a:hover,
.events-section.section-paper .event-card__title a:focus-visible,
.events-section.section-paper .event-card:focus-within .event-card__title a {
  color: var(--earth);
}

.events-section.section-paper .event-card__meta {
  color: var(--muted);
}

.events-section.section-paper .event-card__desc {
  color: var(--muted);
}

/* ---------- Research home ---------- */
.research-home {
  padding: clamp(2.75rem, 5vw, 4.25rem) 0;
  background: var(--paper);
}

.research-home .section-title {
  margin-bottom: 1.75rem;
  color: #28418c;
}

.research-home-grid {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 800px) {
  .research-home-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.research-home-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  background: var(--parchment);
  overflow: hidden;
  color: inherit;
  height: 100%;
  transition: transform 0.35s var(--ease), border-color 0.3s;
}

.research-home-card:hover {
  transform: translateY(-4px);
  border-color: rgba(40, 65, 140, 0.28);
}

.research-home-card__img {
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.research-home-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.research-home-card__body {
  padding: 1.15rem 1.2rem 1.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}

.research-home-card__meta {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--earth);
}

.research-home-card__title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  line-height: 1.35;
  color: #28418c;
}

.research-home-card__desc {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---------- Stats strip ---------- */
.stats-home {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background:
    radial-gradient(ellipse 65% 80% at 12% 50%, rgba(64, 140, 255, 0.22), transparent 58%),
    radial-gradient(ellipse 50% 70% at 88% 40%, rgba(90, 200, 255, 0.12), transparent 52%),
    radial-gradient(ellipse 40% 50% at 50% 120%, rgba(165, 120, 101, 0.14), transparent 55%),
    #28418c;
  color: #fff;
  padding: clamp(2.25rem, 4vw, 3.25rem) 0;
}

.stats-home::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(90, 200, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(90, 200, 255, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  opacity: 0.65;
}

.stats-home-grid {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(2, 1fr);
}

@media (min-width: 900px) {
  .stats-home-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
  }
}

.stats-home-item {
  text-align: center;
  padding: 0.5rem;
}

.stats-home-item strong {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 3.5vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
  margin-bottom: 0.35rem;
}

.stats-home-item span {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.35;
}

/* ---------- Partners ---------- */
.partners-section {
  padding: clamp(2.5rem, 5vw, 3.75rem) 0;
  background: var(--paper);
}

.partners-section .section-title {
  margin-bottom: 0.5rem;
  color: #28418c;
}

.partners-lead {
  color: var(--muted);
  max-width: 52ch;
  margin-bottom: 1.75rem;
}

.partners-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  align-items: center;
  justify-content: flex-start;
  margin-bottom: 1.5rem;
}

.partner-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.65rem 1rem;
  border: 1px solid var(--line);
  background: var(--parchment);
  font-size: 0.88rem;
  font-weight: 600;
  color: #28418c;
}

/* ---------- Lean contact ---------- */
.contact-lean {
  padding: clamp(2.5rem, 5vw, 3.5rem) 0;
  background: var(--parchment);
  border-top: 1px solid var(--line);
}

.contact-lean-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 800px) {
  .contact-lean-grid {
    grid-template-columns: 1.2fr 1fr;
    align-items: end;
  }
}

.contact-lean .section-title {
  margin-bottom: 0.75rem;
}

.contact-lean-list {
  display: grid;
  gap: 0.65rem;
  margin-top: 1rem;
}

.contact-lean-list a,
.contact-lean-list span {
  color: var(--ink);
  font-size: 0.98rem;
}

.contact-lean-list a:hover {
  color: var(--blue);
}

/* Footer styles live in sections.css (global footer.php) */

/* Hero leaner on home */
.hero-home .hero-title {
  max-width: 18ch;
}

.hero-home .hero-lead {
  max-width: 40ch;
}
