:root {
  --ink: #16141f;
  --ink-soft: #3d3a48;
  --muted: #6b6675;
  --paper: #faf8f4;
  --paper-2: #efe9de;
  --white: #fffcf7;
  --line: rgba(22, 20, 31, 0.1);
  --violet: #4c2a6a;
  --violet-deep: #2f1844;
  --gold: #f6ac00;
  --gold-soft: #ffd45e;
  --shadow: 0 20px 50px rgba(47, 24, 68, 0.08);
  --serif: "Cormorant Garamond", "Noto Serif TC", Georgia, serif;
  --sans: "Outfit", "Noto Sans TC", system-ui, sans-serif;
  --max: 1180px;
}

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

html {
  scroll-behavior: smooth;
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.65;
  letter-spacing: 0.01em;
  overflow-x: hidden;
  -webkit-tap-highlight-color: rgba(183, 25, 57, 0.16);
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea,
select {
  font: inherit;
}

.eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
}

.container {
  width: min(var(--max), calc(100% - 40px));
  margin-inline: auto;
}

.site-notice {
  position: relative;
  z-index: 5;
  background: #b71939;
  color: #fff;
  font-size: 0.82rem;
  font-weight: 500;
  padding-top: env(safe-area-inset-top);
}

.site-notice .notice-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  min-height: 46px;
  flex-wrap: wrap;
  padding: 8px 0;
}

.site-notice p {
  margin: 0;
}

.notice-copy {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  min-width: 0;
}

.site-notice .official-link {
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.45);
  padding: 3px 8px;
  white-space: nowrap;
  line-height: 1.35;
  text-decoration: none;
}

.site-notice .official-link:hover {
  background: #fff;
  color: #b71939;
}

.notice-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.nav-toggle {
  border: 1px solid rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  cursor: pointer;
  min-height: 30px;
  padding: 0 12px;
  font-weight: 600;
}

.nav-toggle:hover {
  background: #fff;
  color: #b71939;
}

.notice-nav {
  background: #00517d;
  border-top: 0;
}

.site-notice.is-collapsed .notice-nav {
  display: none;
}

.notice-nav .nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 2px;
  min-height: 44px;
}

.notice-nav .nav a:not(.btn),
.notice-nav .nav button.nav-link {
  color: #fff;
  padding: 10px 8px;
  font-size: 0.86rem;
}

.notice-nav .nav > a:not(.btn):hover,
.notice-nav .nav .nav-link:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
}

.notice-nav .nav > a:not(.btn).active,
.notice-nav .nav .nav-link.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.notice-nav .nav-apply {
  padding: 6px 0;
}

.notice-nav .lang-switch {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.75);
  background: transparent;
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-weight: 600;
  min-height: 34px;
  padding: 0 12px;
  white-space: nowrap;
}

.notice-nav .lang-switch:hover {
  background: #fff;
  color: #00517d;
}

.notice-nav .btn-action {
  background: #b71939;
  color: #fff;
}

.notice-nav .btn-action:hover {
  background: #8e122c;
  color: #fff;
}

.notice-nav .nav a.active::after,
.notice-nav .nav .nav-link.active::after {
  background: #f6ac00;
}

.notice-nav .nav .drop .submenu {
  background: #fff;
  color: #16141f;
  border: 1px solid rgba(22, 20, 31, 0.16);
  box-shadow: 0 16px 36px rgba(22, 20, 31, 0.22);
  z-index: 60;
}

.notice-nav .nav .drop .submenu a {
  color: #16141f;
  background: transparent;
}

.notice-nav .nav .drop .submenu .submenu-page:hover {
  background: #efe4cc;
  color: #00517d;
}

.brand-logo {
  width: 148px;
  height: 148px;
  object-fit: contain;
  flex-shrink: 0;
}

.header {
  position: sticky;
  top: 0;
  z-index: 40;
  overflow: visible;
  background: rgba(246, 242, 234, 0.96);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}

.header-brand {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 164px;
  padding-top: 8px;
  padding-bottom: 8px;
  overflow: hidden;
}

.brand {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
}

.brand-logo-link {
  display: flex;
  flex-shrink: 0;
  border-radius: 50%;
}

.brand-logo-link:focus-visible {
  outline: 2px solid #00517d;
  outline-offset: 3px;
}

.brand-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.15;
}

.brand-name-wrap {
  position: relative;
  display: inline-block;
  width: fit-content;
  max-width: 100%;
  isolation: isolate;
  overflow: visible;
}

.brand-name-wrap::before {
  content: "";
  position: absolute;
  left: 2%;
  right: 2%;
  top: -85%;
  bottom: 48%;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 22% 88%, rgba(255, 210, 80, 0.36), transparent 52%),
    radial-gradient(ellipse at 50% 100%, rgba(255, 140, 30, 0.3), transparent 58%),
    radial-gradient(ellipse at 78% 86%, rgba(183, 25, 57, 0.24), transparent 54%);
  filter: blur(10px);
  animation: brand-ember 1.15s ease-in-out infinite alternate;
}

.brand-fire {
  position: absolute;
  left: -2%;
  top: -110%;
  width: 104%;
  height: 155%;
  pointer-events: none;
  z-index: 0;
}

.brand-text em {
  position: relative;
  z-index: 1;
  font-style: normal;
  font-size: clamp(1.75rem, 3.6vw, 2.4rem);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #b71939;
  font-weight: 700;
  line-height: 1.1;
  white-space: nowrap;
  text-shadow: 0 -4px 10px rgba(255, 190, 60, 0.22), 0 0 2px rgba(255, 255, 255, 0.16);
}

@keyframes brand-ember {
  from {
    opacity: 0.32;
    transform: scaleX(0.92) translateY(2px);
  }
  to {
    opacity: 0.68;
    transform: scaleX(1.08) translateY(-6px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .brand-name-wrap::before {
    animation: none;
  }
}

.brand-text strong {
  font-family: var(--serif);
  font-size: clamp(1.4rem, 3vw, 2.05rem);
  font-weight: 600;
}

.nav-bar {
  display: none;
}

.nav-apply {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
}

.nav-apply .btn {
  min-height: 34px;
  padding: 0 14px;
  font-size: 0.84rem;
}

.mobile-group {
  display: grid;
  gap: 2px;
  padding-top: 10px;
}

.mobile-group span {
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 600;
}

.mobile-group a {
  padding: 4px 0 4px 8px;
}

.nav .drop {
  position: relative;
}

.submenu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 260px;
  background: #fff;
  border: 1px solid rgba(22, 20, 31, 0.16);
  box-shadow: 0 16px 36px rgba(22, 20, 31, 0.22);
  padding: 8px 0;
  z-index: 60;
}

.drop.is-open .submenu {
  display: grid;
}

.submenu-page {
  display: block;
  padding: 10px 16px;
  font-size: 0.88rem;
}

.submenu-page:hover {
  background: #f6f2ea;
  color: #00517d;
}

.nav a:not(.btn),
.nav button.nav-link {
  background: none;
  border: 0;
  cursor: pointer;
  padding: 12px 11px;
  color: var(--ink-soft);
  font-size: 0.92rem;
  letter-spacing: 0.01em;
  position: relative;
}

.nav a:not(.btn):hover,
.nav a:not(.btn).active,
.nav button.nav-link:hover,
.nav .nav-link:hover {
  color: var(--violet);
}

.nav a:not(.btn).active::after,
.nav .nav-link.active::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 2px;
  height: 1px;
  background: var(--gold);
}

.inpage-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 28px;
  margin: 36px 0 0;
}

.inpage-nav a,
a.text-link {
  color: var(--ink-soft);
  padding: 4px 0;
  position: relative;
  font-size: 0.95rem;
}

.inpage-nav a:hover,
a.text-link:hover {
  color: var(--violet);
  text-decoration: underline;
  text-underline-offset: 6px;
  text-decoration-thickness: 1px;
}

.inpage-nav a.active,
a.text-link.active {
  color: var(--ink);
}

.inpage-nav a.active::after,
a.text-link.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--gold);
}

.inpage-nav a.active:hover,
a.text-link.active:hover {
  text-decoration: none;
}

.card h3 .text-link {
  font: inherit;
  color: inherit;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.ext-icon,
.file-icon {
  width: 0.85em;
  height: 0.85em;
  margin-left: 0.35em;
  vertical-align: -0.08em;
  flex-shrink: 0;
}

.ext-link,
.resource-link {
  color: var(--violet);
  display: inline-flex;
  align-items: center;
  gap: 2px;
  flex-wrap: wrap;
}

.ext-link:hover,
.resource-link:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.ext-hint {
  font-size: 0.82rem;
  color: var(--muted);
  margin: 0 0 8px;
}

.ext-card {
  display: block;
  padding: 28px;
  color: inherit;
}

.ext-card h3 {
  display: block;
}

.ext-card:hover {
  border-color: var(--gold);
}

.resource-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

.resource-link {
  color: var(--ink-soft);
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.resource-link .file-type {
  display: inline-block;
  margin-left: 6px;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  font-weight: 600;
  color: var(--gold);
}

.card .resource-link {
  margin-top: 12px;
}

.site-notice .ext-icon {
  width: 0.75em;
  height: 0.75em;
}

.footer .ext-link {
  color: inherit;
}

.prose .ext-link,
.prose .resource-link {
  color: var(--violet);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.btn-outline.apply-zh {
  min-height: 36px;
  padding: 0 14px;
  font-size: 0.88rem;
}

.btn-primary.header-apply,
.header-actions .btn-primary {
  min-height: 36px;
  padding: 0 14px;
  font-size: 0.88rem;
}

.icon-btn,
.menu-btn {
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--ink);
  cursor: pointer;
  height: 36px;
  padding: 0 12px;
}

.icon-btn {
  width: 36px;
  padding: 0;
}

.btn,
.nav-toggle,
.lang-switch,
.filter-bar button {
  touch-action: manipulation;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: 0.2s ease;
  white-space: nowrap;
}

.btn-primary {
  background: var(--violet);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--violet-deep);
}

.btn-action {
  background: #b71939;
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.btn-action:hover {
  background: #8e122c;
  color: #fff;
  text-decoration: none;
}

.btn-action-secondary {
  background: transparent;
  border-color: #b71939;
  color: #b71939;
  font-weight: 600;
}

.btn-action-secondary:hover {
  background: #b71939;
  color: #fff;
  text-decoration: none;
}

.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin: 16px 0 8px;
}

.header-actions .btn-action-secondary {
  min-height: 36px;
  padding: 0 14px;
  font-size: 0.84rem;
}

.btn-ghost {
  border-color: rgba(255, 252, 247, 0.35);
  color: var(--white);
}

.btn-ghost:hover {
  background: rgba(255, 252, 247, 0.08);
}

.btn-outline {
  border-color: var(--violet);
  color: var(--violet);
  background: transparent;
}

.btn-outline:hover {
  background: var(--violet);
  color: var(--white);
}

.menu-btn,
.mobile-nav {
  display: none;
}

.hero {
  position: relative;
  min-height: 82vh;
  display: grid;
  align-items: end;
  color: #12324a;
  overflow: hidden;
  background: #fff3c4;
}

.hero-media {
  position: absolute;
  inset: 0;
  background: #e7eef3;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 42%;
  filter: saturate(1.08) contrast(1.02) brightness(1.04);
}

.hero-cross {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.hero-cross .fjcu-cross-svg {
  position: absolute;
  right: 2%;
  top: 48%;
  transform: translateY(-50%);
  width: min(58vw, 640px);
  height: auto;
  opacity: 0.5;
  filter: drop-shadow(0 16px 36px rgba(246, 172, 0, 0.4));
}

main {
  position: relative;
}

.fjcu-cross-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}

.fjcu-cross-bg .fjcu-cross-svg {
  position: absolute;
  right: -6%;
  top: 8%;
  width: min(52vw, 560px);
  height: auto;
  opacity: 0.07;
}

main > *:not(.fjcu-cross-bg) {
  position: relative;
  z-index: 1;
}

.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  background:
    linear-gradient(115deg, rgba(246, 172, 0, 0.38) 0%, rgba(183, 25, 57, 0.12) 28%, rgba(0, 81, 125, 0.16) 58%, rgba(255, 248, 232, 0.55) 100%),
    linear-gradient(180deg, rgba(246, 172, 0, 0.18) 0%, rgba(255, 252, 247, 0.9) 100%);
}

.hero-content {
  position: relative;
  z-index: 4;
  padding: 108px 0 72px;
  max-width: 980px;
}

.hero .eyebrow {
  font-size: 0.84rem;
  letter-spacing: 0.28em;
  background: #f6ac00;
  color: #3a2800;
  padding: 6px 12px;
}

.hero h1 {
  font-family: var(--serif);
  font-size: clamp(3.6rem, 9.2vw, 6.6rem);
  line-height: 0.94;
  font-weight: 600;
  margin: 10px 0 18px;
  color: #00517d;
  letter-spacing: -0.03em;
  max-width: 14ch;
}

.hero h1::after {
  content: "";
  display: block;
  width: 96px;
  height: 6px;
  margin-top: 16px;
  background: linear-gradient(90deg, #f6ac00 0%, #b71939 100%);
}

.hero p.lead {
  font-size: clamp(1.2rem, 2.4vw, 1.65rem);
  line-height: 1.4;
  color: #3d2f14;
  max-width: 56ch;
  margin: 0;
}

.hero ul {
  padding-left: 1.1rem;
  color: rgba(255, 252, 247, 0.86);
  max-width: 58ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

.hero-actions .btn-action {
  box-shadow: 0 10px 24px rgba(183, 25, 57, 0.28);
}

.hero-actions .btn-action-secondary {
  background: #fff8e0;
  border-color: #f6ac00;
  color: #7a5500;
}

.hero-actions .btn-action-secondary:hover {
  background: #f6ac00;
  border-color: #f6ac00;
  color: #3a2800;
}

.hero .btn-primary {
  background: #b71939;
}

.hero .btn-primary:hover {
  background: #8e122c;
}

.hero .btn-outline {
  background: rgba(255, 252, 247, 0.9);
  border-color: #00517d;
  color: #00517d;
}

.hero .btn-outline:hover {
  background: #00517d;
  color: #fff;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: #00517d;
  color: var(--white);
  border-top: 6px solid #f6ac00;
}

.stat {
  padding: 28px 24px;
  border-right: 1px solid rgba(255, 252, 247, 0.08);
}

.stat:last-child {
  border-right: 0;
}

.stat b {
  display: block;
  font-family: var(--serif);
  font-size: 2rem;
  font-weight: 600;
  color: #f6ac00;
}

.stat span {
  color: rgba(255, 252, 247, 0.72);
  font-size: 0.9rem;
}

.section {
  padding: 88px 0;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 24px;
  margin-bottom: 36px;
}

#regulations,
#scholarships,
#structure {
  scroll-margin-top: 150px;
}

.section h2,
.page-hero h1,
.prose h2,
.prose h3 {
  font-family: var(--serif);
  font-weight: 600;
  letter-spacing: -0.02em;
}

.section h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin: 8px 0 0;
}

.grid-3,
.grid-2,
.faculty-grid,
.news-grid,
.gallery-grid {
  display: grid;
  gap: 22px;
}

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

.grid-2 {
  grid-template-columns: 1.1fr 0.9fr;
}

.card,
.news-item,
.faculty-card,
.partner-card {
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.card {
  padding: 28px;
}

body[data-page="home"] {
  background: #fff8e8;
}

body[data-page="home"] .card {
  border-top: 4px solid #f6ac00;
}

.card,
.news-card,
.news-item,
.faculty-card,
.faculty-row,
.faculty-section,
.partner-card,
.ext-card {
  cursor: pointer;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

@media (hover: hover) and (pointer: fine) {
  .card:hover,
  .news-card:hover,
  .news-item:hover,
  .faculty-card:hover,
  .faculty-row:hover,
  .partner-card:hover,
  .ext-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 28px 56px rgba(0, 81, 125, 0.2);
    border-color: #00517d;
  }

  .faculty-section:hover {
    border-color: #f6ac00;
  }

  .faculty-row:hover {
    z-index: 2;
    transform: translateY(-12px);
  }
}

.news-card.pinned:hover {
  border-color: #f6ac00;
}

@media (prefers-reduced-motion: reduce) {
  .card,
  .news-card,
  .news-item,
  .faculty-card,
  .faculty-row,
  .faculty-section,
  .partner-card,
  .ext-card {
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
  }

  .card:hover,
  .news-card:hover,
  .news-item:hover,
  .faculty-card:hover,
  .faculty-row:hover,
  .partner-card:hover,
  .ext-card:hover {
    transform: none;
  }

  .news-icon,
  .news-card:hover .news-icon {
    transform: none;
  }
}

.card h3,
.faculty-card h3,
.partner-card h3,
.news-item h3 {
  font-family: var(--serif);
  font-size: 1.5rem;
  margin: 10px 0;
}

.card p,
.muted,
.faculty-card p,
.news-item p {
  color: var(--ink-soft);
}

.page-hero {
  padding: 72px 0 36px;
  border-bottom: 1px solid var(--line);
}

.page-hero h1 {
  font-size: clamp(2.3rem, 5vw, 4.2rem);
  margin: 10px 0 12px;
}

.page-photo {
  margin: 0 0 36px;
}

.page-photo img {
  width: 100%;
  height: min(420px, 52vw);
  object-fit: cover;
}

.prose .page-photo {
  margin: 8px 0 24px;
}

.prose .page-photo img {
  height: min(280px, 48vw);
}

.breadcrumbs {
  color: var(--muted);
  font-size: 0.85rem;
}

.prose {
  max-width: 760px;
}

.prose p {
  color: var(--ink-soft);
}

.prose ul {
  padding-left: 18px;
  color: var(--ink-soft);
}

.prose li + li {
  margin-top: 8px;
}

.split {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 48px;
  align-items: start;
}

.news-item {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 18px;
  padding: 22px;
}

.news-item time {
  color: var(--gold);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
}

.news-item.pinned {
  border-color: var(--gold);
}

.news-cards {
  display: grid;
  gap: 16px;
  padding-top: 12px;
  overflow: visible;
}

.news-cards-home {
  grid-template-columns: 1fr;
  gap: 12px;
  padding: 18px 0 12px;
  overflow: visible;
}

.news-card {
  position: relative;
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: 22px 24px;
  display: grid;
  gap: 8px;
}

.news-cards-home .news-card {
  grid-template-columns: 48px auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0 16px;
  padding: 14px 18px;
}

.news-cards-home .news-icon {
  margin: 0;
}

.news-cards-home .news-card time {
  white-space: nowrap;
  color: var(--muted);
  font-size: 0.88rem;
}

.news-cards-home .news-card h3 {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.35;
}

.news-cards-home .news-card .text-link,
.news-cards-home .news-card .ext-link {
  white-space: nowrap;
}

.news-card-photo {
  height: 160px;
  object-fit: cover;
  object-position: center;
  background: #efe4cc;
  margin: -22px -24px 8px;
  width: calc(100% + 48px);
  max-width: none;
  transition: transform 0.22s ease;
}

.news-article-image {
  margin: 0 0 28px;
}

.news-article-image img {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  display: block;
  background: #efe4cc;
}

.admin-image-picker {
  display: grid;
  gap: 12px;
  margin-bottom: 28px;
}

.admin-image-preview {
  margin: 0;
  max-width: 360px;
}

.admin-image-preview img,
.admin-news-thumb {
  display: block;
  object-fit: cover;
  background: #efe4cc;
}

.admin-image-preview img {
  width: 100%;
  max-height: 220px;
}

.admin-news-thumb {
  width: 56px;
  height: 42px;
}

.news-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #fff3c4;
  color: #b71939;
  margin-bottom: 4px;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.news-icon svg {
  width: 24px;
  height: 24px;
  display: block;
}

@media (hover: hover) and (pointer: fine) {
  .news-card:hover {
    z-index: 2;
  }

  .news-card.pinned:hover {
    transform: translateY(-14px);
    box-shadow: 0 32px 60px rgba(0, 81, 125, 0.22);
  }

  .news-card:hover .news-icon {
    transform: translateY(-8px) scale(1.14);
    box-shadow: 0 12px 22px rgba(183, 25, 57, 0.18);
  }

  .news-card:hover .news-card-photo {
    transform: scale(1.03);
  }
}

.news-card.pinned {
  border-color: var(--gold);
}

.news-card time {
  color: var(--gold);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  font-weight: 600;
}

.news-card h3 {
  font-family: var(--serif);
  font-size: 1.25rem;
  margin: 0;
  line-height: 1.35;
}

.news-card .ext-link {
  justify-self: start;
  font-weight: 600;
}

.news-source {
  margin-top: 28px;
  color: var(--muted);
  font-size: 0.88rem;
}

.faculty-grid {
  grid-template-columns: repeat(3, 1fr);
}

.faculty-list {
  display: grid;
  gap: 48px;
}

.faculty-section {
  padding: 28px 24px 32px;
  border: 1px solid var(--line);
  background: var(--white);
  box-shadow: var(--shadow);
}

.faculty-section-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  padding-top: 8px;
  overflow: visible;
}

.faculty-row {
  position: relative;
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 16px 24px;
  align-items: start;
  padding: 18px;
  border: 1px solid var(--line);
  background: #fffdf6;
  box-shadow: none;
}

.faculty-row:first-child {
  padding-top: 18px;
}

.faculty-schema-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.7rem;
  line-height: 1.35;
  background: var(--white);
}

.faculty-schema-table th,
.faculty-schema-table td {
  border: 1px solid #f0d48a;
  padding: 4px 7px;
  text-align: left;
  vertical-align: top;
  word-break: break-word;
}

.faculty-schema-table thead th {
  background: #f6ac00;
  color: #fff;
  font-weight: 600;
}

.faculty-schema-table tbody th {
  width: 1%;
  white-space: nowrap;
  background: #fff8e8;
  font-family: var(--sans);
  font-weight: 600;
  color: var(--ink);
}

.faculty-details h3 {
  margin-top: 0;
}

.faculty-details h3 {
  font-family: var(--serif);
  font-size: clamp(1.15rem, 2vw, 1.4rem);
  margin: 0 0 6px;
}

.faculty-details .role {
  color: var(--violet);
  font-size: 0.95rem;
  font-weight: 600;
}

.faculty-photo-wrap {
  margin: 0;
  width: 100%;
  max-width: 240px;
}

.faculty-photo {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: top center;
  background: #efe4cc;
  display: block;
}

.faculty-photo-empty {
  background: linear-gradient(180deg, #fff3c4, #efe4cc);
}

.faculty-card {
  padding: 24px;
}

.faculty-card .role {
  color: var(--violet);
  font-size: 0.88rem;
}

.partner-card {
  overflow: hidden;
}

.partner-card img {
  height: 180px;
  width: 100%;
  object-fit: cover;
}

.partner-card div {
  padding: 22px;
}

.gallery-grid {
  grid-template-columns: repeat(4, 1fr);
}

.gallery-grid a {
  display: block;
  overflow: hidden;
  aspect-ratio: 4 / 3;
}

.gallery-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.gallery-grid a:hover img {
  transform: scale(1.05);
}

.timeline {
  border-left: 1px solid var(--gold);
  padding-left: 24px;
}

.timeline article {
  margin-bottom: 28px;
}

.timeline h3 {
  margin: 0 0 6px;
  font-family: var(--serif);
}

.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 32px;
}

form {
  display: grid;
  gap: 14px;
  background: var(--white);
  padding: 28px;
  border: 1px solid var(--line);
}

label {
  display: grid;
  gap: 6px;
  font-size: 0.9rem;
}

input,
textarea,
select {
  border: 1px solid var(--line);
  background: var(--paper);
  padding: 12px 14px;
  color: var(--ink);
}

.search-panel {
  display: none;
  position: absolute;
  right: 20px;
  top: 86px;
  width: min(420px, calc(100% - 40px));
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: 16px;
  z-index: 50;
}

.search-panel.open {
  display: block;
}

.search-panel input {
  width: 100%;
}

.search-results {
  margin-top: 12px;
  display: grid;
  gap: 8px;
}

.search-results a {
  display: block;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  color: var(--violet);
}

.cta-band {
  background: linear-gradient(90deg, #00517d 0%, #0a6aa0 55%, #b8860b 100%);
  color: var(--white);
  border-top: 6px solid #f6ac00;
}

.cta-band .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}

.cta-band h2 {
  margin: 8px 0 0;
  font-family: var(--serif);
  font-size: 2.4rem;
}

.cta-band .btn-action {
  background: #f6ac00;
  color: #3a2800;
}

.cta-band .btn-action:hover {
  background: #fff8e0;
  color: #3a2800;
}

.cta-band .btn-action-secondary {
  border-color: #f6ac00;
  color: #fff8e0;
}

.cta-band .btn-action-secondary:hover {
  background: #f6ac00;
  color: #3a2800;
}

.btn-action .ext-icon {
  color: currentColor;
}

.footer {
  background: #120e18;
  color: rgba(255, 252, 247, 0.78);
  padding: 64px 0 calc(28px + env(safe-area-inset-bottom));
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 40px;
}

.footer h3 {
  color: var(--white);
  font-family: var(--serif);
  font-size: 1.2rem;
}

.footer a:hover {
  color: var(--gold-soft);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 252, 247, 0.08);
  padding-top: 18px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 0.82rem;
}

.notice {
  background: #efe4cc;
  border-left: 3px solid var(--gold);
  padding: 14px 16px;
  color: var(--ink-soft);
  margin: 20px 0;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.filter-bar button {
  border: 1px solid var(--line);
  background: var(--white);
  cursor: pointer;
  padding: 8px 12px;
}

.filter-bar button.active {
  background: var(--violet);
  color: var(--white);
  border-color: var(--violet);
}

@media (max-width: 1100px) {

  .stats,
  .grid-3,
  .grid-2,
  .news-cards-home,
  .split,
  .faculty-grid,
  .faculty-section-grid,
  .gallery-grid,
  .contact-grid,
  .footer-grid,
  .cta-band .container {
    grid-template-columns: 1fr;
    display: grid;
  }

  .news-item {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: 78vh;
  }

  .hero-cross .fjcu-cross-svg {
    right: -22%;
    width: min(110vw, 640px);
    opacity: 0.2;
  }

  .site-notice .notice-row {
    flex-direction: column;
    align-items: flex-start;
    padding: 8px 0;
  }

  .notice-nav .nav-apply {
    margin-left: 0;
  }

  .brand-logo {
    width: 118px;
    height: 118px;
  }

  .header-brand {
    min-height: 134px;
  }

  .admin-shared,
  .admin-bilingual {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .container {
    width: min(var(--max), calc(100% - 24px));
  }

  .notice-nav .nav {
    flex-direction: column;
    align-items: stretch;
    min-height: 0;
    padding: 6px 0 10px;
  }

  .notice-nav .nav a:not(.btn),
  .notice-nav .nav button.nav-link {
    min-height: 44px;
    display: flex;
    align-items: center;
    padding: 10px 4px;
  }

  .nav .drop {
    width: 100%;
  }

  .nav .drop .submenu,
  .notice-nav .nav .drop .submenu {
    display: none;
    position: static;
    min-width: 0;
    box-shadow: none;
    border: 0;
    background: transparent;
    padding: 0 0 8px 4px;
  }

  .nav .drop.is-open .submenu,
  .notice-nav .nav .drop.is-open .submenu {
    display: grid;
  }

  .notice-nav .nav .drop .submenu .submenu-page {
    color: #fff;
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  .notice-nav .nav .drop .submenu .submenu-page:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
  }

  .notice-nav .nav-apply {
    width: 100%;
    justify-content: stretch;
    gap: 10px;
    padding: 4px 0 12px;
  }

  .notice-nav .lang-switch,
  .notice-nav .btn-action {
    min-height: 44px;
    flex: 1;
  }

  .nav-toggle {
    min-height: 44px;
  }

  .hero {
    min-height: 0;
  }

  .hero-content {
    padding: 56px 0 40px;
  }

  .hero h1 {
    font-size: clamp(2.4rem, 13vw, 3.6rem);
    max-width: 12ch;
  }

  .hero p.lead {
    font-size: 1.1rem;
  }

  .hero-actions,
  .action-row {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn,
  .action-row .btn,
  .cta-band .btn {
    width: 100%;
  }

  .faculty-row {
    grid-template-columns: min(160px, 38%) minmax(0, 1fr);
    gap: 12px 14px;
  }

  .faculty-photo-wrap {
    max-width: 160px;
    justify-self: start;
  }

  .news-cards-home .news-card {
    grid-template-columns: 40px minmax(0, 1fr);
    align-items: start;
  }

  .news-cards-home .news-card time,
  .news-cards-home .news-card h3,
  .news-cards-home .news-card .text-link,
  .news-cards-home .news-card .ext-link {
    grid-column: 2;
    white-space: normal;
  }

  .section {
    padding: 56px 0;
  }

  .cta-band h2 {
    font-size: 1.8rem;
  }

  .footer-bottom {
    flex-direction: column;
  }

  input,
  textarea,
  select {
    font-size: 16px;
    max-width: 100%;
  }

  form {
    padding: 20px;
  }

  .brand {
    align-items: center;
    min-width: 0;
  }

  .brand-text {
    min-width: 0;
  }

  .brand-text em,
  .brand-text strong {
    overflow-wrap: anywhere;
    white-space: normal;
  }
}

.auth-card {
  max-width: 520px;
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: 28px;
}

.auth-card .admin-form {
  margin-bottom: 16px;
}

.auth-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  margin: 0;
}

.admin-session {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 24px;
  padding: 12px 16px;
  border: 1px solid var(--line);
  background: #fffdf6;
}

.admin-session p {
  margin: 0;
}

.admin-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.admin-tabs a {
  min-height: 36px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  background: var(--white);
  font-weight: 600;
}

.admin-tabs a.active {
  background: #00517d;
  color: #fff;
  border-color: #00517d;
}

.admin-actions .faculty-move[disabled] {
  opacity: 0.35;
  pointer-events: none;
}

.admin-form {
  margin-bottom: 48px;
}

.admin-shared,
.admin-bilingual {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 28px;
}

.admin-table-wrap {
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border: 1px solid var(--line);
}

.admin-table th,
.admin-table td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.admin-table td strong,
.admin-table td .muted {
  display: block;
}

.admin-actions {
  display: flex;
  gap: 12px;
  white-space: nowrap;
}

.admin-actions button {
  background: none;
  border: 0;
  padding: 0;
  color: #b71939;
  cursor: pointer;
}

.access-icon-btn {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  background: var(--white);
  color: #0b7a3b;
}

.access-icon-btn svg {
  width: 18px;
  height: 18px;
  display: block;
}

.access-icon-btn.access-reject {
  color: #b71939;
}

.access-icon-btn:hover:not(:disabled) {
  border-color: currentColor;
  background: #fff8e8;
}

.access-icon-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.admin-flash.is-error {
  color: #b71939;
}

.admin-status {
  display: inline-block;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 600;
}

.admin-status-published {
  color: #00517d;
}

.admin-status-draft,
.admin-status-waiting {
  color: var(--muted);
}

.admin-status-approved {
  color: #0b7a3b;
}

.admin-status-denied {
  color: #b71939;
}

.admin-flash {
  margin: 0;
  color: #00517d;
  font-weight: 600;
}

.access-confirm {
  margin: 0 0 18px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  background: #fff8e8;
}

.access-confirm strong {
  display: block;
  font-size: 1.05rem;
}

.access-confirm p {
  margin: 6px 0 0;
}

.access-confirm-email {
  font-weight: 600;
}

.access-confirm.is-approved {
  border-color: #0b7a3b;
  background: #e8f6ee;
  color: #0b7a3b;
}

.access-confirm.is-denied {
  border-color: #b71939;
  background: #fdecee;
  color: #b71939;
}

.whatsapp-float {
  position: fixed;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
  z-index: 80;
  width: 58px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #25d366;
  color: #fff;
  border-radius: 50%;
  box-shadow: 0 10px 24px rgba(37, 211, 102, 0.38);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.whatsapp-float:hover,
.whatsapp-float:focus-visible {
  transform: translateY(-5px) scale(1.08);
  box-shadow: 0 16px 30px rgba(37, 211, 102, 0.5);
}

.whatsapp-icon {
  width: 30px;
  height: 30px;
  display: block;
}

@media (prefers-reduced-motion: reduce) {
  .whatsapp-float {
    transition: none;
  }

  .whatsapp-float:hover,
  .whatsapp-float:focus-visible {
    transform: none;
  }
}
