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

html,
body {
  height: 100%;
  font-family: 'Source Sans Pro', sans-serif;
}

.home-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(135deg, #1a3a5c 0%, #0d5c8c 50%, #0a7abf 100%);
}

/* ── TOP NAVBAR ── */
.top-nav {
  background: rgba(0, 0, 0, 0.25);
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  backdrop-filter: blur(4px);
}

.top-nav .brand {
  color: #fff;
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-decoration: none;
}

.top-nav .brand:hover {
  color: #a8d8f0;
  text-decoration: none;
}

/* ── HERO SECTION ── */
.hero-section {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 16px;
}

.hero-card {
  display: flex;
  flex-direction: row;
  width: 100%;
  max-width: 900px;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.35);
}

/* ── LEFT PANEL ── */
.hero-left {
  flex: 1;
  background: linear-gradient(160deg, #1a3a5c 0%, #0d5c8c 100%);
  color: #fff;
  padding: 52px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-left .tagline {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #a8d8f0;
  margin-bottom: 12px;
}

.hero-left h1 {
  font-size: 1.8rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 20px;
}

.hero-left p {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.7;
  margin-bottom: 32px;
}

/* ── RIGHT PANEL (Actions) ── */
.hero-right {
  width: 360px;
  flex-shrink: 0;
  padding: 52px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background-color: #fff;
}

.hero-right .logo-area {
  text-align: center;
  margin-bottom: 40px;
}

.hero-right .logo-area .logo-icon {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  box-shadow: 0 8px 24px rgba(10, 122, 191, 0.35);
}

.portals-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.portals-list li {
  margin-bottom: 16px;
}

.portals-list a {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #333;
  text-decoration: none;
  font-size: 0.9rem;
  padding: 12px 16px;
  border-radius: 8px;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.portals-list a:hover {
  background: #fff;
  border-color: #0d5c8c;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(13, 92, 140, 0.15);
  color: #0d5c8c;
}

.portals-list a .icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(13, 92, 140, 0.1);
  color: #0d5c8c;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.2s;
}

.portals-list a:hover .icon {
  background: #0d5c8c;
  color: #fff;
}

.portals-list a .icon i {
  font-size: 1rem;
}

.portals-list a .info .label {
  font-weight: 700;
  font-size: 0.95rem;
  display: block;
  margin-bottom: 2px;
}

.portals-list a .info .sub {
  font-size: 0.75rem;
  color: #666;
}

/* ── FOOTER ── */
.home-footer {
  text-align: center;
  padding: 16px;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.5);
}

/* ── MESSAGES (Django) ── */
.messages-wrapper {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 9999;
  max-width: 340px;
}

.messages-wrapper .alert {
  border-radius: 8px;
  font-size: 0.88rem;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .hero-card {
    flex-direction: column;
    max-width: 440px;
    margin: 0 auto;
  }

  .hero-left {
    padding: 36px 28px;
  }

  .hero-right {
    width: 100%;
    padding: 36px 28px;
  }

  .hero-left h1 {
    font-size: 1.4rem;
  }

  .top-nav .nav-links {
    display: none; /* Hide nav links on mobile if preferred, or keep them */
  }

  .hero-section {
    padding: 24px 12px;
  }
}
