/* ===== DDU v2 — Mockup-faithful premium redesign ===== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

:root {
  --primary: #C84B1A;
  --primary-hover: #E05A28;
  --primary-light: #FBE9E7;
  --accent: #FF7043;
  --dark: #1a1a1a;
  --dark-nav: #2D2D2D;
  --maroon: #8B1A1A;
  --bg: #f4f4f2;
  --surface: #fff;
  --text: #1a1a1a;
  --text-secondary: #555;
  --text-muted: #999;
  --border: #e8e4e1;
  --border-light: #f0f0f0;
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --shadow-sm: 0 1px 3px rgba(0,0,0,.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,.08);
  --shadow-lg: 0 8px 30px rgba(0,0,0,.12);
  --radius: 8px;
  --transition: .25s ease;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { display: block; max-width: 100%; }

/* ---------- Container ---------- */
.container { max-width: 1260px; margin: 0 auto; padding: 0 24px; }

/* ---------- Topbar ---------- */
.topbar {
  background: var(--maroon);
  color: rgba(255,255,220,.9);
  font-size: .6875rem;
  padding: 6px 0;
  letter-spacing: .02em;
}
.topbar .container { display: flex; justify-content: space-between; align-items: center; }
.topbar-links { display: flex; gap: 6px; }
.topbar-links a {
  color: rgba(255,255,220,.85);
  padding: 2px 8px;
  border-radius: 3px;
  transition: var(--transition);
}
.topbar-links a:hover { background: rgba(255,255,255,.15); color: #fff; }

/* ---------- Main Nav ---------- */
.nav-wrapper {
  background: var(--surface);
  position: sticky; top: 0; z-index: 100;
  border-bottom: 3px solid var(--primary);
  box-shadow: 0 2px 8px rgba(0,0,0,.07);
}
.main-nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0;
  position: relative;
}
.nav-logo {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 0;
  text-decoration: none;
}
.logo-box {
  width: 44px; height: 44px;
  background: var(--primary);
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 900; font-size: .875rem;
  letter-spacing: -1px;
  flex-shrink: 0;
}
.logo-text .uni { font-size: .8125rem; font-weight: 700; color: var(--text); line-height: 1.2; }
.logo-text .sub { font-size: .6875rem; color: #777; font-weight: 500; }

.nav-links { display: flex; gap: 0; }
.nav-link {
  padding: 16px 12px;
  font-size: .8125rem; font-weight: 600;
  color: #333;
  border-bottom: 3px solid transparent;
  white-space: nowrap;
  transition: var(--transition);
}
.nav-link:hover, .nav-link.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.nav-search {
  display: flex; align-items: center; gap: 0;
  border: 1px solid #e0e0e0; border-radius: 6px;
  overflow: hidden;
}
.nav-search input {
  border: none; padding: 7px 12px; font-size: .8125rem;
  width: 150px; outline: none; font-family: var(--font);
  background: transparent;
}
.nav-search button {
  background: var(--primary); color: #fff; border: none;
  padding: 7px 12px; font-size: .8125rem; cursor: pointer;
  font-family: var(--font); font-weight: 600;
  transition: var(--transition);
}
.nav-search button:hover { background: var(--primary-hover); }

/* ---------- Secondary Nav ---------- */
.secondary-nav {
  background: var(--dark-nav);
  overflow-x: auto;
}
.secondary-nav .container { display: flex; gap: 0; }
.snav-item {
  padding: 10px 16px;
  font-size: .75rem; font-weight: 500;
  color: #ccc;
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  transition: var(--transition);
}
.snav-item:hover, .snav-item.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 420px;
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 60%, #0f3460 100%);
  overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  opacity: .3;
}
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to right, rgba(10,10,20,.85) 40%, rgba(10,10,20,.2) 100%);
}
.hero .container {
  position: relative; z-index: 2;
  display: flex; align-items: center; justify-content: space-between;
  min-height: 420px;
  padding-top: 40px; padding-bottom: 40px;
}
.hero-content { max-width: 55%; }
.hero-badge {
  display: inline-block;
  background: var(--primary); color: #fff;
  font-size: .6875rem; padding: 4px 14px;
  border-radius: 4px; margin-bottom: 14px;
  font-weight: 700; letter-spacing: .05em;
  text-transform: uppercase;
  animation: pulse-glow 2s ease-in-out infinite;
}
@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(200,75,26,.4); }
  50% { box-shadow: 0 0 0 8px rgba(200,75,26,0); }
}
.hero-title {
  font-size: 2.75rem; font-weight: 800; color: #fff;
  line-height: 1.15; margin-bottom: 12px;
  letter-spacing: -.02em;
}
.hero-title span { color: var(--accent); }
.hero-sub {
  font-size: 1rem; color: #ccd; line-height: 1.7;
  margin-bottom: 24px; max-width: 480px;
}
.hero-btns { display: flex; gap: 12px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 10px 22px; border-radius: 6px;
  font-weight: 700; font-size: .8125rem;
  cursor: pointer; border: none;
  font-family: var(--font);
  transition: all var(--transition);
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-hover); box-shadow: 0 4px 16px rgba(200,75,26,.35); }
.btn-outline { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.7); }
.btn-outline:hover { background: #fff; color: var(--dark); border-color: #fff; }

/* Notice Box */
.hero-notice {
  width: 280px; flex-shrink: 0;
  background: rgba(255,255,255,.97);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(0,0,0,.3);
}
.notice-header {
  background: var(--primary); color: #fff;
  padding: 8px 14px;
  font-size: .8125rem; font-weight: 700;
  display: flex; justify-content: space-between; align-items: center;
}
.notice-close { cursor: pointer; opacity: .7; font-size: 1rem; }
.notice-close:hover { opacity: 1; }
.notice-item {
  padding: 10px 14px;
  font-size: .75rem; color: #333;
  border-bottom: 1px solid var(--border-light);
  display: flex; align-items: flex-start; gap: 8px;
  transition: var(--transition);
  cursor: pointer;
}
.notice-item:hover { background: var(--primary-light); color: var(--primary); }
.notice-item:last-child { border: none; }
.notice-dot {
  width: 7px; height: 7px;
  background: var(--primary); border-radius: 50%;
  margin-top: 4px; flex-shrink: 0;
}

/* Carousel dots */
.hero-dots {
  position: absolute; bottom: 16px; left: 30px; z-index: 3;
  display: flex; gap: 6px;
}
.dot { width: 10px; height: 10px; border-radius: 50%; background: rgba(255,255,255,.35); cursor: pointer; transition: var(--transition); }
.dot.active { background: var(--accent); width: 28px; border-radius: 5px; }

/* ---------- Stats ---------- */
.stats-section {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.stats-grid {
  display: grid; grid-template-columns: repeat(5, 1fr);
}
.stat {
  padding: 24px 16px; text-align: center;
  border-right: 1px solid var(--border-light);
  transition: transform var(--transition);
}
.stat:last-child { border-right: none; }
.stat:hover { transform: translateY(-2px); }
.stat-icon { font-size: 1.75rem; margin-bottom: 6px; }
.stat-num {
  font-size: 1.75rem; font-weight: 800; color: var(--primary);
  line-height: 1;
}
.stat-label {
  font-size: .75rem; color: #666; margin-top: 4px;
  line-height: 1.4;
}

/* ---------- Content Row (Leadership + Quote) ---------- */
.content-row {
  display: grid; grid-template-columns: 1fr 1fr;
  background: var(--surface); margin-top: 8px;
}
.about-section {
  padding: 32px;
  border-right: 1px solid var(--border-light);
}
.section-tag {
  font-size: .6875rem; font-weight: 700;
  color: var(--primary);
  letter-spacing: .08em; text-transform: uppercase;
  margin-bottom: 8px;
}
.section-title {
  font-size: 1.375rem; font-weight: 800;
  color: var(--text); line-height: 1.3;
  margin-bottom: 14px;
}
.president-card {
  display: flex; gap: 16px; margin-top: 16px;
}
.president-img {
  width: 80px; height: 100px;
  border-radius: 6px;
  flex-shrink: 0;
  overflow: hidden;
  object-fit: cover;
}
.president-img-placeholder {
  width: 80px; height: 100px;
  border-radius: 6px;
  background: linear-gradient(135deg, #c8d8e8, #a0b8cc);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  font-size: 2rem; color: #7a95aa;
}
.pres-name { font-size: .9375rem; font-weight: 700; }
.pres-role { font-size: .75rem; color: var(--primary); margin-bottom: 8px; font-weight: 500; }
.pres-text { font-size: .8125rem; color: var(--text-secondary); line-height: 1.6; }
.btn-small {
  font-size: .75rem; padding: 6px 14px;
  background: var(--primary); color: #fff;
  border: none; border-radius: 5px;
  cursor: pointer; margin-top: 10px;
  font-family: var(--font); font-weight: 600;
  display: inline-block;
  transition: var(--transition);
}
.btn-small:hover { background: var(--primary-hover); }

/* Quote */
.quote-section {
  background: var(--primary); padding: 32px;
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; justify-content: center;
}
.quote-bg {
  position: absolute; top: -24px; left: -8px;
  font-size: 10rem; color: rgba(255,255,255,.08);
  font-family: Georgia, serif; line-height: 1;
  pointer-events: none;
}
.quote-text {
  font-size: 1.0625rem; color: #fff;
  line-height: 1.8; font-style: italic;
  position: relative; z-index: 1;
}
.quote-author {
  margin-top: 16px;
  font-size: .9375rem; font-weight: 700;
  color: #FFD0C0;
}

/* ---------- Quick Links ---------- */
.quick-links {
  background: var(--surface);
  padding: 32px;
  margin-top: 8px;
}
.ql-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 12px; margin-top: 16px;
}
.ql-item {
  border: 1px solid #f0e8e5; border-radius: var(--radius);
  padding: 20px 12px; text-align: center;
  cursor: pointer; transition: all var(--transition);
}
.ql-item:hover {
  border-color: var(--primary);
  background: var(--primary-light);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.ql-icon {
  font-size: 1.75rem; color: var(--primary);
  margin-bottom: 8px;
  transition: transform var(--transition);
}
.ql-item:hover .ql-icon { transform: scale(1.15); }
.ql-label { font-size: .8125rem; color: #444; font-weight: 600; }
.ql-sub { font-size: .6875rem; color: #888; margin-top: 3px; }

/* ---------- Gallery ---------- */
.gallery {
  padding: 32px;
  background: var(--surface);
  margin-top: 8px;
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px; margin-top: 16px;
}
.gal-item {
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 1.2;
  position: relative;
  cursor: pointer;
}
.gal-item:first-child {
  grid-column: span 2; grid-row: span 2;
  aspect-ratio: auto;
}
.gal-item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .4s ease;
}
.gal-item:hover img { transform: scale(1.06); }
.gal-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 2rem; color: rgba(255,255,255,.6);
}
.gal-item .gal-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.35) 0%, transparent 60%);
  opacity: 0; transition: opacity var(--transition);
}
.gal-item:hover .gal-overlay { opacity: 1; }

/* ---------- Faculties ---------- */
.faculties {
  background: var(--dark-nav);
  padding: 20px 0;
  margin-top: 8px;
}
.faculties .container {
  display: flex; gap: 8px;
  flex-wrap: wrap; align-items: center;
}
.fac-label {
  color: #aaa; font-size: .8125rem;
  margin-right: 12px; font-weight: 700;
  letter-spacing: .04em;
}
.fac-chip {
  background: #3d3d3d; color: #ccc;
  padding: 8px 16px; border-radius: 6px;
  font-size: .8125rem; font-weight: 500;
  cursor: pointer; border: 1px solid transparent;
  transition: all var(--transition);
}
.fac-chip:hover, .fac-chip.active {
  background: var(--primary); color: #fff;
  border-color: var(--primary);
}

/* ---------- Footer ---------- */
.footer {
  background: var(--dark);
  color: var(--text-muted);
  padding: 20px 0;
  margin-top: 8px;
}
.footer .container {
  display: flex; justify-content: space-between;
  align-items: center; flex-wrap: wrap; gap: 12px;
}
.footer-copy { color: #666; font-size: .75rem; }
.footer-links { display: flex; gap: 18px; align-items: center; }
.footer-links a { color: var(--text-muted); font-size: .8125rem; transition: var(--transition); }
.footer-links a:hover { color: var(--accent); }
.footer-lang { color: #555; font-size: .75rem; margin-left: 8px; }

/* ====== Page Header (subpages) ====== */
.page-header {
  padding: 56px 0 48px;
  text-align: center;
  position: relative; overflow: hidden;
}
.page-header-title {
  font-size: 2.25rem; font-weight: 800; color: #fff;
  margin-bottom: 8px;
  position: relative; z-index: 2;
}
.page-header-sub {
  font-size: 1.0625rem; color: rgba(255,255,255,.7);
  position: relative; z-index: 2;
}

/* Content sections for inner pages */
.content-area { padding: 40px 0; }
.card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  transition: box-shadow var(--transition);
}
.card:hover { box-shadow: var(--shadow-md); }
.card p { color: var(--text-secondary); line-height: 1.7; font-size: .9375rem; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 32px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 32px; }
.standard-list { padding-left: 1.5rem; margin-bottom: 1rem; }
.standard-list li {
  list-style-type: disc;
  margin-bottom: .5rem;
  color: var(--text-secondary);
  font-size: .9375rem;
}

/* Department cards for subpages */
.dept-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 20px;
  text-align: center;
  transition: all var(--transition);
  cursor: pointer;
  background: var(--surface);
}
.dept-card:hover {
  border-color: var(--primary);
  background: var(--primary-light);
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.dept-card-icon { font-size: 2rem; margin-bottom: 8px; }
.dept-card-title { font-size: 1rem; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.dept-card-sub { font-size: .8125rem; color: var(--text-secondary); }

/* Info-block for subpages */
.info-block { margin-bottom: 24px; }
.info-block h3 {
  font-size: 1.125rem; font-weight: 700;
  color: var(--text); margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--primary-light);
}
.info-block p { color: var(--text-secondary); font-size: .9375rem; line-height: 1.7; }

/* ====== Responsive ====== */
@media (max-width: 1024px) {
  .hero .container { flex-direction: column; align-items: flex-start; gap: 24px; min-height: auto; padding-top: 32px; padding-bottom: 32px; }
  .hero-content { max-width: 100%; }
  .hero-notice { width: 100%; max-width: 360px; }
  .stats-grid { grid-template-columns: repeat(3, 1fr); }
  .stat { border-bottom: 1px solid var(--border-light); }
  .content-row { grid-template-columns: 1fr; }
  .about-section { border-right: none; border-bottom: 1px solid var(--border-light); }
  .ql-grid { grid-template-columns: repeat(3, 1fr); }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .gal-item:first-child { grid-column: span 2; grid-row: span 2; }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-search { border: none; background: transparent; overflow: visible; position: static; }
  .nav-search input {
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    width: 100%;
    background: #fff;
    border: none;
    border-bottom: 2px solid var(--primary);
    padding: 16px 24px;
    box-shadow: 0 8px 24px rgba(0,0,0,.15);
    z-index: 99;
  }
  .nav-search.mobile-active input { display: block; }
  .nav-search button { border-radius: 6px; padding: 8px 14px; }
  
  .hero-title { font-size: 2rem; }
  .hero-notice { display: none; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .ql-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .gal-item:first-child { grid-column: span 2; grid-row: span 1; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .footer .container { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr; }
  .ql-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: 1fr; }
  .gal-item:first-child { grid-column: span 1; }
  .faculties .container { justify-content: center; }
}
