:root {
  --ciawu-red: #c8102e;
  --ciawu-blue: #003f7f;
}

* {
  box-sizing: border-box;
}

/* Full height layout */
html,
body {
  height: 100%;
}

body {
  font-family: Arial, sans-serif;
  margin: 0;
  background: #f3f4f6;
  color: #111827;
  display: flex;
  flex-direction: column;
}

/* Top bar */
.topbar {
  background: var(--ciawu-blue);
  color: #ffffff;
  padding: 10px 0;
}

.topbar-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 130px;
}

.topbar-logo {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.topbar-logo img {
  width: 46px;
  height: 46px;
  object-fit: contain;
}

.topbar-text h1 {
  margin: 0;
  font-size: 1.25rem;
  letter-spacing: 0.03em;
}

.topbar-text p {
  margin: 2px 0 0 0;
  font-size: 0.8rem;
  opacity: 0.9;
}

/* Main container */
main.container {
  max-width: 1500px;
  margin: 0 auto;
  padding: 24px 20px;
  flex: 1 0 auto;
  text-align: left; /* default for all content */
}

/* Intro: only block centered */
.page-intro {
  margin-top: 16px;
  margin-bottom: 8px;
  text-align: center;
}

.page-intro h2 {
  margin: 0 0 6px 0;
  font-size: 1.25rem;
  color: var(--ciawu-blue);
}

.page-intro p {
  margin: 0;
  font-size: 0.9rem;
  color: #4b5563;
}

/* Section titles */
h3.section-title {
  margin-top: 28px;
  margin-bottom: 10px;
  font-size: 1.05rem;
  color: #111827;
}

.section-underline {
  width: 50px;
  height: 3px;
  background: var(--ciawu-red);
  border-radius: 999px;
  margin-bottom: 12px;
}

/* Cards */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}

.card {
  display: block;
  padding: 16px 18px;
  border-radius: 10px;
  background: #ffffff;
  text-decoration: none;
  color: #111827;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  border: 1px solid #e5e7eb;
  position: relative;
  text-align: left;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 10px;
  border: 2px solid transparent;
  pointer-events: none;
}

.card h4 {
  margin: 0 0 6px 0;
  font-size: 1.0rem;
}

.card p {
  margin: 0;
  font-size: 0.9rem;
  color: #4b5563;
}

.card.tag-admin::after {
  content: "Admin";
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 0.65rem;
  padding: 2px 6px;
  border-radius: 999px;
  background: var(--ciawu-red);
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.06);
  border-color: var(--ciawu-blue);
}

.card:hover::before {
  border-color: rgba(0,0,0,0.03);
}

/* Card content with icon */
.card-content {
  display: flex;
  align-items: center;
  gap: 10px;
}

.card-icon {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: #f3f4f6;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.card-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Footer pinned to bottom */
.footer-note {
  margin-top: 24px;
  font-size: 0.8rem;
  color: #6b7280;
}

.footer {
  background: var(--ciawu-red);
  color: #ffffff;
  margin-top: 32px;
  padding: 10px 0;
  flex-shrink: 0;
}

.footer-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 20px;
  font-size: 0.8rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
}

.footer-inner span {
  opacity: 0.95;
}

section {
  margin-top: 24px;
  margin-bottom: 24px;
}
