/* 神戸大学代数セミナー — seminar-specific styles, November 2026.
   Keep this stylesheet independent from the personal website.
   Color variables, page header, announcements, year ribbons and talks are
   defined once each; mobile adaptations are grouped at the end. */

:root {
  color-scheme: light;
  --ink: #4e4352;
  --muted: #786e77;
  --link: #785a81;
  --outline: #e6dbe4;
  --ivory: #fdf9f8;
  --focus: #9370a5;
  --eyebrow: #76576f;
  --microheading: #725671;
  --date-color: #73566f;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: linear-gradient(180deg, #fffaf8 0%, #fdf8fc 56%, #fffbf9 100%);
  color: var(--ink);
  font-family: "Hiragino Kaku Gothic ProN", "Yu Gothic", "Noto Sans CJK JP", system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.72;
}
a { color: var(--link); text-decoration-color: #b3a1ba; text-underline-offset: .21em; }
a:hover { text-decoration-color: currentColor; }
a:focus-visible, summary:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 4px;
  border-radius: 6px;
}

/* Header and in-page navigation */
.seminar-header {
  position: relative;
  overflow: hidden;
  background: linear-gradient(117deg, #f6e8ee 4%, #fff7f1 74%);
  border-bottom: 1px solid #efdfdf;
}
.header-inner, .nav-inner, .main-content { max-width: 1050px; margin-inline: auto; }
.header-inner { padding: 41px 32px; }
.eyebrow {
  margin: 0 0 13px;
  font-size: 11px;
  line-height: 1.5;
  font-weight: 700;
  letter-spacing: .16em;
  color: var(--eyebrow);
}
.eyebrow span { margin-inline: .8em; color: #795b74; }
.header-content { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
h1 {
  margin: 0;
  font-size: clamp(30px, 4.2vw, 46px);
  line-height: 1.36;
  font-weight: 580;
  letter-spacing: .045em;
  color: #6a566c;
}
.title-english {
  margin: 4px 0 0;
  font-family: Georgia, "Times New Roman", serif;
  font-style: italic;
  font-size: 19px;
  color: #795b74;
}
.header-decoration { position: relative; width: 140px; height: 116px; flex: none; opacity: .8; }
.header-decoration i { display: block; position: absolute; border: 2px solid #d3afc4; border-radius: 48% 52% 51% 49%; }
.header-decoration i:nth-child(1) { width: 83px; height: 83px; left: 14px; top: 7px; background: #edd9e7aa; transform: rotate(27deg); }
.header-decoration i:nth-child(2) { width: 76px; height: 76px; left: 51px; top: 24px; background: #f7e3d5bb; transform: rotate(-22deg); }
.header-decoration i:nth-child(3) { width: 24px; height: 24px; left: 61px; top: 49px; background: #fff8f8; }
.section-nav { background: #fffefa; border-bottom: 1px solid #eee1e7; }
.nav-inner { display: flex; flex-wrap: wrap; column-gap: 32px; row-gap: 6px; padding: 15px 32px; }
.section-nav a { color: #6e5c76; font-size: 13.5px; text-decoration: none; border-bottom: 1px solid #c4b2cb; padding: 1px 0; }
.section-nav a:hover { color: #4e385c; border-color: currentColor; }

/* Upcoming seminar and basic information */
.main-content { min-width: 0; padding: 38px 32px 65px; }
section { scroll-margin-top: 22px; }
.section-header { margin: 0 0 20px; }
.section-number {
  display: block;
  margin: 0 0 4px;
  color: var(--microheading);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: .16em;
}
h2 { margin: 0; font-size: 24px; line-height: 1.45; font-weight: 650; letter-spacing: .035em; }
.essentials { margin-bottom: 56px; }
.upcoming {
  position: relative;
  margin-bottom: 26px;
  padding: 25px 29px 27px;
  background: linear-gradient(100deg, #fff0e7 0%, #fff7f3 55%, #fffcfc 100%);
  border: 1px solid #efdcd9;
  border-radius: 8px 30px 30px 30px;
}
.upcoming::before {
  content: "";
  display: block;
  position: absolute;
  width: 28px;
  height: 28px;
  background: #dfc5d8;
  left: -8px;
  top: -8px;
  border-radius: 50% 50% 12px 50%;
  transform: rotate(25deg);
}
.upcoming .section-number { color: #795b74; }
.upcoming h2 { color: #6a5268; font-size: 26px; }
.upcoming p { margin: 0; line-height: 1.65; }
/* This class is only added while there is no forthcoming seminar. */
.upcoming.is-empty { padding-top: 16px; padding-bottom: 17px; }
.information { border-top: 1px dashed #d8c4ce; padding: 19px 8px 4px; }
.information h2 { color: #6c616c; font-size: 19px; }
.info-grid { display: grid; grid-template-columns: 65px minmax(0, 1fr); gap: 6px 15px; margin: 0; font-size: 14px; }
.info-grid dt { font-weight: 750; color: #785c76; }
.info-grid dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }

/* Records, fiscal-year ribbons and expandable talk abstracts */
.records-section { margin-bottom: 50px; }
.records-section > .section-header {
  display: flex;
  gap: 9px 16px;
  align-items: baseline;
  flex-wrap: wrap;
  margin-bottom: 22px;
  border-bottom: 2px solid #eadbe6;
  padding-bottom: 9px;
}
.records-section > .section-header .section-number { margin: 0; color: #73566f; }
.records-section h2 { color: #6b506d; }
.subperiod { font-size: 12px; font-weight: 450; color: var(--muted); letter-spacing: 0; margin-left: 11px; }
.year-list { display: flex; flex-direction: column; gap: 16px; }
.year-group {
  min-width: 0;
  border: 1px solid #e9dce7;
  border-radius: 28px 10px 28px 10px;
  overflow: hidden;
  background: #fffdfc;
  box-shadow: 0 7px 21px #7047650d;
}
.year-group > summary {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  user-select: none;
  list-style: none;
  position: relative;
  padding: 0 17px 0 0;
  min-height: 58px;
  background: #fffdfc;
  overflow: hidden;
}
.year-group > summary::-webkit-details-marker { display: none; }
.year-group:nth-child(3n + 1) > summary { background: #f8f1fa; }
.year-group:nth-child(3n + 2) > summary { background: #fff2ef; }
.year-group:nth-child(3n + 3) > summary { background: #f8f3f3; }
.year-group > summary:hover { filter: brightness(.989); }
.year-group[open] > summary { border-bottom: 1px solid #eddde6; }
.year-label {
  position: relative;
  align-self: stretch;
  width: 172px;
  display: flex;
  align-items: center;
  flex: none;
  margin: 0; /* h3 uses the same position as the former span. */
  padding: 5px 12px 5px 22px;
  font: italic 24px/1.2 Georgia, serif;
  letter-spacing: .015em;
  color: #705571;
  background: #ecdce9;
  border-radius: 0 32px 32px 0;
  white-space: nowrap;
}
.year-group:nth-child(3n + 2) .year-label { background: #f5dfd7; }
.year-group:nth-child(3n + 3) .year-label { background: #e7e0ec; }
.year-count { margin-left: auto; flex: none; font-size: 12.5px; font-weight: 650; color: #776875; white-space: nowrap; }
/* The native <details> state controls the small end chevron. */
.year-group > summary::after {
  content: '›';
  display: block;
  flex: none;
  width: 16px;
  text-align: center;
  color: #73566f;
  font: normal 23px/1.1 Georgia, serif;
}
.year-group[open] > summary::after { content: '∨'; font-size: 14px; font-weight: 700; }
.year-events { padding: 5px 28px 15px 30px; min-width: 0; background: #fffdfc; }
.talk {
  position: relative;
  display: grid;
  grid-template-columns: minmax(140px, 164px) minmax(0, 1fr);
  column-gap: 23px;
  border-bottom: 1px solid #f0ebf0;
  padding: 20px 8px 23px 26px;
}
.talk:last-child { border-bottom: 0; }
.talk::before {
  content: "";
  position: absolute;
  top: 31px;
  left: 0;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #c7a9c5;
  box-shadow: 0 0 0 4px #f7eef4;
}
.talk::after { content: ""; position: absolute; left: 4px; top: 43px; bottom: 0; border-left: 1px dashed #e6d4e5; }
.talk:last-child::after { display: none; }
.talk-date {
  grid-column: 1;
  grid-row: 1 / span 5;
  padding: 2px 0;
  color: var(--date-color);
  font-size: 12.7px;
  font-weight: 650;
  line-height: 1.6;
}
.talk-date .date-day, .talk-date .date-clock { display: block; }
.talk h4 { grid-column: 2; font-size: 16.7px; line-height: 1.47; font-weight: 680; margin: 0 0 7px; overflow-wrap: anywhere; }
.talk-speaker { grid-column: 2; font-size: 14px; margin: 0 0 2px; }
.talk-venue { grid-column: 2; color: var(--muted); font-size: 12.8px; margin: 2px 0 0; }
.talk-venue span { margin-right: .8em; font-size: 12px; }
.abstract-details { grid-column: 2; margin-top: 11px; }
.abstract-details > summary {
  display: inline-flex;
  align-items: center;
  list-style: none;
  cursor: pointer;
  gap: 7px;
  font-size: 13.2px;
  font-weight: 580;
  color: #795b82;
  text-decoration: underline;
  text-underline-offset: .2em;
  text-decoration-color: #c4aac9;
}
.abstract-details > summary::-webkit-details-marker { display: none; }
.abstract-details > summary::before { content: '+'; font: 20px/1 Georgia, serif; color: #775c83; }
.abstract-details[open] > summary::before { content: '−'; }
.abstract-body {
  margin-top: 11px;
  background: #fff8fb;
  border-left: 3px solid #d6b7ce;
  border-radius: 0 10px 10px 0;
  padding: 15px 17px;
  font-size: 13.5px;
  line-height: 1.82;
  overflow-wrap: anywhere;
}

/* Footer */
.seminar-footer { border-top: 1px solid var(--outline); padding: 25px 32px 38px; background: #fff9fb; }
.footer-inner { max-width: 986px; margin: auto; font-size: 12.5px; color: var(--muted); }
.footer-inner p { margin: 0 0 5px; }

/* Responsive layout */
@media (max-width: 750px) {
  .header-inner { padding-right: 22px; padding-left: 22px; }
  .nav-inner { padding: 12px 22px; column-gap: 22px; }
  .main-content { padding: 28px 22px 45px; }
  .talk { grid-template-columns: 125px minmax(0, 1fr); column-gap: 18px; }
}
@media (max-width: 540px) {
  .header-inner { padding: 41px 18px; }
  h1 { font-size: 30px; letter-spacing: .015em; white-space: normal; }
  .eyebrow { font-size: 9.5px; letter-spacing: .09em; margin-bottom: 12px; }
  .header-decoration { display: none; }
  .title-english { font-size: 16px; }
  .nav-inner { padding: 11px 18px; column-gap: 16px; }
  .section-nav a { font-size: 12.5px; }
  .main-content { padding: 24px 16px 36px; }
  .essentials { margin-bottom: 56px; }
  .upcoming { padding: 21px 20px; border-radius: 7px 24px 24px 24px; }
  .upcoming.is-empty { padding: 14px 20px 15px; }
  .upcoming h2 { font-size: 23px; }
  .information h2 { font-size: 19px; }
  .records-section { margin-bottom: 37px; }
  .records-section > .section-header { flex-direction: column; align-items: flex-start; gap: 3px; }
  .records-section h2 { font-size: 22px; }
  .subperiod { margin-left: 6px; }
  .year-list { gap: 12px; }
  .year-group { border-radius: 21px 8px 21px 8px; }
  .year-group > summary { padding-right: 9px; min-height: 51px; gap: 7px; }
  .year-label { width: 116px; padding: 5px 9px 5px 12px; font-size: 19px; border-radius: 0 22px 22px 0; }
  .year-count { font-size: 12.5px; }
  .year-group > summary::after { width: 13px; font-size: 21px; }
  .year-group[open] > summary::after { font-size: 13px; }
  .year-events { padding: 4px 14px 12px 17px; }
  .talk { display: block; padding: 18px 0 20px 16px; }
  .talk::before { width: 7px; height: 7px; left: 0; top: 25px; }
  .talk::after { left: 3px; top: 36px; }
  .talk-date { margin-bottom: 8px; font-size: 12px; }
  .talk h4 { font-size: 15.7px; }
  .talk-speaker { font-size: 13.5px; }
  .talk-venue { font-size: 12.4px; }
  .abstract-body { padding: 12px 14px; font-size: 13px; }
  .info-grid { font-size: 13.5px; }
}
/* Only narrow phones: prevent the trailing ー from wrapping. */
@media (max-width: 359px) {
  h1 { font-size: 24.5px; letter-spacing: 0; }
  .year-label { width: 102px; padding-left: 9px; font-size: 18px; }
  .year-count { font-size: 10px; }
  .year-group > summary::after { width: 11px; font-size: 19px; }
  .year-group[open] > summary::after { font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
