:root {
  --white: #ffffff;
  --bg-soft: #f6f8fc;
  --bg-soft-2: #eef2fb;
  --ink: #0b1220;
  --ink-soft: #475066;
  --ink-faint: #8891a5;
  --blue-900: #0c2461;
  --blue-700: #17429c;
  --blue-600: #1e4fd8;
  --blue-500: #3b6bf0;
  --blue-glow: rgba(30, 79, 216, 0.28);
  --blue-glow-soft: rgba(30, 79, 216, 0.12);
  --gold: #f2b100;
  --gold-deep: #d99400;
  --gold-soft: #ffe6a3;
  --border: #e4e9f4;
  --shadow-soft: 0 10px 30px rgba(12, 36, 97, 0.08);
  --shadow-lift: 0 20px 45px rgba(12, 36, 97, 0.16);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --nav-height: 60px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
}

body {
  font-family: "Poppins", sans-serif;
  color: var(--ink);
  background: linear-gradient(180deg, var(--bg-soft) 0%, #fdfefe 100%);
  line-height: 1.6;
  min-height: 100vh;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.site-header {
  background: linear-gradient(135deg, var(--blue-900) 0%, var(--blue-700) 100%);
  border-bottom: 4px solid var(--gold);
}

.header-top {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 12px;
  padding: 24px 20px 18px;
  text-align: center;
  position: relative;
}

.header-logo-circle {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  border: 3px solid var(--gold);
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 50%;
}

.logo-placeholder-text {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--gold);
  letter-spacing: 0.08em;
}

.header-text {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.college-name {
  font-size: clamp(1.4rem, 4vw, 2.2rem);
  font-weight: 800;
  letter-spacing: 0.1em;
  color: var(--white);
  text-transform: uppercase;
  line-height: 1.1;
}

.college-tagline {
  font-size: 0.72rem;
  font-weight: 400;
  color: rgba(255,255,255,0.65);
  letter-spacing: 0.04em;
  margin-top: 4px;
}

.dept-name {
  font-size: 1rem;
  font-weight: 600;
  color: var(--gold-soft);
  margin-top: 6px;
}

.portal-name {
  font-size: clamp(1.1rem, 2.3vw, 1.5rem);
  font-weight: 700;
  margin-top: 4px;
  color: var(--gold);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.main-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 0 16px 16px;
  flex-wrap: wrap;
}

.nav-link {
  padding: 8px 14px;
  border-radius: 999px;
  color: rgba(255,255,255,0.92);
  font-weight: 500;
  transition: background 0.2s ease, color 0.2s ease;
}

.nav-link:hover,
.nav-link.active-link {
  background: rgba(255,255,255,0.14);
  color: var(--white);
}

.alumni-section-logo {
  display: flex;
  justify-content: center;
  margin-bottom: 24px;
}

.alumni-section-logo-img {
  width: 150px;
  height: 150px;
  object-fit: contain;
  border-radius: 50%;
}

.hero {
  position: relative;
  padding: 72px 20px 48px;
  overflow: hidden;
  background: radial-gradient(circle at top left, rgba(30,79,216,0.16), transparent 30%),
    linear-gradient(135deg, var(--bg-soft-2), var(--white));
}

.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.45;
  pointer-events: none;
}

.hero-glow-1 {
  width: 260px;
  height: 260px;
  background: rgba(30,79,216,0.18);
  top: -80px;
  right: -40px;
}

.hero-glow-2 {
  width: 220px;
  height: 220px;
  background: rgba(242,177,0,0.18);
  left: -60px;
  bottom: -60px;
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 860px;
  margin: 0 auto;
  text-align: center;
}

.eyebrow {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue-600);
  background: var(--blue-glow-soft);
  padding: 7px 14px;
  border-radius: 999px;
  margin-bottom: 16px;
}

.hero h2 {
  font-size: clamp(2rem, 4.6vw, 3.1rem);
  font-weight: 800;
  color: var(--blue-900);
  margin-bottom: 16px;
}

.hero p {
  max-width: 720px;
  margin: 0 auto 28px;
  color: var(--ink-soft);
  font-size: 1rem;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 999px;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--blue-600), var(--blue-700));
  color: var(--white);
  box-shadow: 0 10px 22px var(--blue-glow);
}

.btn-secondary {
  background: var(--white);
  color: var(--blue-700);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
}

.role-preview {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(255,255,255,0.8);
  border: 1px solid rgba(30,79,216,0.16);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(10px);
}

.role-chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--blue-700);
  background: var(--blue-glow-soft);
}

.role-help {
  font-size: 0.9rem;
  color: var(--ink-soft);
}

.toolbar {
  max-width: 1200px;
  margin: -18px auto 24px;
  padding: 0 20px;
}

.search-card,
.filter-row {
  background: rgba(255,255,255,0.95);
  border: 1px solid rgba(228,233,244,0.96);
  box-shadow: var(--shadow-soft);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(14px);
}

.search-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  margin-bottom: 16px;
}

.search-card input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  color: var(--ink);
}

.search-icon {
  color: var(--ink-faint);
}

.filter-row {
  display: flex;
  gap: 10px;
  padding: 12px;
  overflow-x: auto;
}

.filter-pill {
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 600;
  color: var(--ink-soft);
  background: var(--bg-soft);
  transition: all 0.2s ease;
  white-space: nowrap;
}

.filter-pill.active,
.filter-pill:hover {
  color: var(--white);
  background: linear-gradient(135deg, var(--blue-600), var(--blue-700));
}

.posts-section {
  max-width: 1200px;
  margin: 0 auto 70px;
  padding: 0 20px;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  margin-bottom: 24px;
}

.section-heading h3 {
  font-size: 1.35rem;
  color: var(--blue-900);
}

.result-summary {
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.post-card {
  position: relative;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.post-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lift);
}

.post-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: var(--blue-glow-soft);
  color: var(--blue-700);
}

.post-logo {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--blue-600), var(--gold));
  color: var(--white);
  display: grid;
  place-items: center;
  font-weight: 700;
  flex-shrink: 0;
}

.post-title {
  font-size: 1.05rem;
  color: var(--blue-900);
  line-height: 1.35;
}

.post-company,
.post-meta,
.post-description {
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.post-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.post-description {
  min-height: 70px;
}

.post-footer {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.action-btn {
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 600;
  border: 1px solid var(--border);
  background: var(--bg-soft);
  color: var(--blue-700);
  transition: all 0.2s ease;
}

.action-btn:hover {
  background: var(--blue-glow-soft);
}

.action-btn.primary {
  background: linear-gradient(135deg, var(--blue-600), var(--blue-700));
  color: var(--white);
  border-color: transparent;
}

.post-actions-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
}

.post-actions-row .action-btn {
  flex: 1;
}

.empty-state {
  text-align: center;
  padding: 32px;
  border: 1px dashed var(--border);
  border-radius: var(--radius-lg);
  background: rgba(255,255,255,0.9);
}

.fab {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue-600), var(--blue-700));
  color: var(--white);
  font-size: 1.7rem;
  box-shadow: var(--shadow-lift);
  z-index: 20;
}

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(11, 18, 32, 0.65);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 20px;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease;
  z-index: 30;
}

.modal-overlay.open {
  opacity: 1;
  visibility: visible;
}

.modal {
  width: min(640px, 100%);
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-lift);
  margin: auto;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 12px;
  margin-bottom: 18px;
}

.modal-label {
  color: var(--blue-600);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.modal-close {
  font-size: 1.7rem;
  line-height: 1;
  color: var(--ink-faint);
}

.post-form {
  display: grid;
  gap: 12px;
}

.post-form label {
  font-weight: 600;
  color: var(--ink);
}

.post-form input,
.post-form select,
.post-form textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 11px 12px;
  background: var(--bg-soft);
  color: var(--ink);
}

.post-form textarea {
  resize: vertical;
}

.form-error {
  min-height: 18px;
  color: #c33a3a;
  font-size: 0.9rem;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 4px;
}

.site-footer {
  text-align: center;
  padding: 24px 20px 36px;
  color: var(--ink-soft);
  border-top: 1px solid var(--border);
  background: rgba(255,255,255,0.7);
}

@media (max-width: 900px) {
  .posts-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  .header-top {
    padding-left: 20px;
    padding-right: 20px;
  }

  .alumni-section-logo-img { width: 145px; height: 145px; }

  .section-heading {
    flex-direction: column;
    align-items: flex-start;
  }

  .posts-grid {
    grid-template-columns: 1fr;
  }

  .toolbar {
    margin-top: -6px;
  }

  .modal {
    padding: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
