@import url('variables.css');
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Merriweather:wght@400;700&display=swap');

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

html {
  scroll-behavior: smooth;
}

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

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

a {
  color: var(--secondary);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--secondary-light);
  text-decoration: underline;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.3;
  color: var(--primary);
  margin-bottom: 1rem;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p {
  margin-bottom: 1rem;
}

ul, ol {
  margin-bottom: 1rem;
  padding-left: 1.5rem;
}

li {
  margin-bottom: 0.5rem;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 4rem 0;
}

.section-alt {
  background-color: var(--bg-soft);
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title h2 {
  margin-bottom: 0.5rem;
}

.section-title .subtitle {
  color: var(--text-muted);
  font-size: 1.1rem;
}

/* Header & Navigation */
.site-header {
  background-color: var(--primary);
  color: white;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: white;
  text-decoration: none;
}

.logo:hover {
  color: white;
  text-decoration: none;
}

.logo-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--secondary) 0%, var(--accent) 100%);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.logo-icon img {
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
}

.logo-text span {
  display: block;
  font-size: 0.75rem;
  font-family: var(--font-body);
  font-weight: 400;
  opacity: 0.85;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.main-nav a {
  color: rgba(255, 255, 255, 0.9);
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
}

.main-nav a:hover,
.main-nav a.active {
  color: white;
  background-color: rgba(255, 255, 255, 0.1);
  text-decoration: none;
}

.dropdown {
  position: relative;
}

.dropdown-toggle {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.dropdown-toggle::after {
  content: '▾';
  font-size: 0.75rem;
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  background-color: white;
  min-width: 200px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 0.5rem 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.2s ease;
}

.dropdown:hover .dropdown-menu,
.dropdown.open .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-menu a {
  color: var(--text);
  display: block;
  padding: 0.6rem 1rem;
  font-size: 0.9rem;
  border-radius: 0;
}

.dropdown-menu a:hover {
  background-color: var(--bg-soft);
  color: var(--secondary);
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem;
}

/* Hero */
.hero {
  background: linear-gradient(135deg, rgba(10, 36, 99, 0.85) 0%, rgba(0, 109, 119, 0.8) 100%), url('../images/singapore-bg.jpg');
  background-size: cover;
  background-position: center;
  color: white;
  padding: 6rem 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: radial-gradient(circle at 20% 80%, rgba(255,255,255,0.08) 0%, transparent 40%),
                    radial-gradient(circle at 80% 20%, rgba(255,255,255,0.05) 0%, transparent 40%);
  pointer-events: none;
}

.hero .container {
  position: relative;
  z-index: 1;
}

.hero-badge {
  display: inline-block;
  background-color: var(--accent);
  color: var(--primary);
  padding: 0.4rem 1rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 0.85rem;
  margin-bottom: 1.5rem;
  letter-spacing: 0.05em;
}

.hero h1 {
  color: white;
  font-size: 3rem;
  margin-bottom: 1rem;
}

.hero .tagline {
  font-size: 1.35rem;
  opacity: 0.95;
  margin-bottom: 2rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.hero-meta {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
}

.hero-meta span {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.75rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: all 0.2s ease;
  border: 2px solid transparent;
  cursor: pointer;
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.btn-primary {
  background-color: var(--accent);
  color: var(--primary);
  border-color: var(--accent);
}

.btn-primary:hover {
  background-color: var(--accent-light);
  border-color: var(--accent-light);
  color: var(--primary);
}

.btn-secondary {
  background-color: transparent;
  color: white;
  border-color: rgba(255, 255, 255, 0.5);
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: white;
}

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

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

/* Page Banner */
.page-banner {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: white;
  padding: 4rem 0;
  text-align: center;
}

.page-banner h1 {
  color: white;
  margin-bottom: 0.5rem;
}

.page-banner p {
  opacity: 0.9;
  font-size: 1.1rem;
  margin-bottom: 0;
}

/* Cards */
.card {
  background-color: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2rem;
  height: 100%;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.card h3 {
  color: var(--primary);
  margin-bottom: 1rem;
}

.grid {
  display: grid;
  gap: 1.5rem;
}

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

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

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

/* Timeline */
.timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background-color: var(--border);
  transform: translateX(-50%);
}

.timeline-item {
  position: relative;
  padding: 1.5rem 0;
  width: 50%;
}

.timeline-item:nth-child(odd) {
  padding-right: 2.5rem;
  text-align: right;
}

.timeline-item:nth-child(even) {
  margin-left: 50%;
  padding-left: 2.5rem;
}

.timeline-item::before {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  background-color: var(--accent);
  border: 3px solid white;
  border-radius: 50%;
  top: 1.75rem;
  box-shadow: var(--shadow);
}

.timeline-item:nth-child(odd)::before {
  right: -8px;
}

.timeline-item:nth-child(even)::before {
  left: -8px;
}

.timeline-date {
  font-weight: 700;
  color: var(--secondary);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.timeline-title {
  font-weight: 700;
  color: var(--primary);
  margin: 0.25rem 0;
}

.timeline-desc {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* News list */
.news-list {
  max-width: 800px;
  margin: 0 auto;
}

.news-item {
  display: flex;
  gap: 1.5rem;
  padding: 1.5rem;
  background-color: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 1rem;
  transition: transform 0.2s ease;
}

.news-item:hover {
  transform: translateX(4px);
}

.news-date {
  flex-shrink: 0;
  width: 80px;
  text-align: center;
}

.news-date .day {
  display: block;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--secondary);
  line-height: 1;
}

.news-date .month {
  display: block;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-transform: uppercase;
}

.news-content h4 {
  margin-bottom: 0.5rem;
}

.news-content p {
  margin-bottom: 0;
  color: var(--text-muted);
}

/* Tables */
.table-responsive {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  background-color: white;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  margin-bottom: 1.5rem;
}

th, td {
  padding: 1rem 1.25rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

th {
  background-color: var(--primary);
  color: white;
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

tr:hover {
  background-color: var(--bg-soft);
}

/* Committee */
.committee-section {
  margin-bottom: 3rem;
}

.committee-section h3 {
  border-bottom: 2px solid var(--accent);
  padding-bottom: 0.5rem;
  display: inline-block;
  margin-bottom: 1.5rem;
}

.committee-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.5rem;
}

.committee-card {
  background-color: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.5rem;
  text-align: center;
}

.committee-avatar {
  width: 80px;
  height: 80px;
  background-color: var(--bg-soft);
  border-radius: 50%;
  margin: 0 auto 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--secondary);
  font-size: 1.75rem;
  font-weight: 700;
  overflow: hidden;
}

.committee-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.committee-card h4 {
  margin-bottom: 0.25rem;
}

.committee-card .role {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 0;
}

/* Keynotes */
.keynote-card {
  display: flex;
  gap: 2rem;
  background-color: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2rem;
  margin-bottom: 2rem;
}

.keynote-photo {
  flex-shrink: 0;
  width: 150px;
  height: 150px;
  background-color: var(--bg-soft);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 3rem;
}

.keynote-info h3 {
  margin-bottom: 0.25rem;
}

.keynote-info .affiliation {
  color: var(--secondary);
  font-weight: 600;
  margin-bottom: 1rem;
}

/* Forms */
.form-group {
  margin-bottom: 1.25rem;
}

label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
}

input[type="text"],
input[type="email"],
textarea,
select {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(0, 109, 119, 0.1);
}

textarea {
  resize: vertical;
  min-height: 120px;
}

/* Footer */
.site-footer {
  background-color: var(--primary);
  color: rgba(255, 255, 255, 0.8);
  padding: 3rem 0 1.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-brand h3 {
  color: white;
  margin-bottom: 0.5rem;
}

.footer-brand p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
}

.footer-links h4 {
  color: white;
  font-size: 1rem;
  margin-bottom: 1rem;
}

.footer-links ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
}

.footer-links a:hover {
  color: white;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.6);
}

/* Back to top */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 44px;
  height: 44px;
  background-color: var(--secondary);
  color: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-lg);
  z-index: 999;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background-color: var(--secondary-light);
  transform: translateY(-3px);
}

/* Utility classes */
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.mt-2 { margin-top: 2rem; }
.mb-2 { margin-bottom: 2rem; }
.lead {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.highlight-box {
  background-color: var(--bg-soft);
  border-left: 4px solid var(--accent);
  padding: 1.5rem;
  border-radius: 0 var(--radius) var(--radius) 0;
  margin-bottom: 1.5rem;
}

.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 600;
}

.badge-primary {
  background-color: rgba(0, 109, 119, 0.1);
  color: var(--secondary);
}

.badge-accent {
  background-color: rgba(201, 162, 39, 0.15);
  color: var(--accent);
}

/* Responsive */
@media (max-width: 900px) {
  .menu-toggle {
    display: block;
  }

  .main-nav {
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    background-color: var(--primary);
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem 1.5rem;
    gap: 0;
    display: none;
    box-shadow: var(--shadow-lg);
  }

  .main-nav.active {
    display: flex;
  }

  .main-nav a {
    display: block;
    width: 100%;
    padding: 0.75rem 0;
    border-radius: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .dropdown {
    width: 100%;
  }

  .dropdown-menu {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    background-color: rgba(0, 0, 0, 0.15);
    display: none;
    padding-left: 1rem;
    min-width: auto;
  }

  .dropdown.open .dropdown-menu {
    display: block;
  }

  .dropdown-menu a {
    color: rgba(255, 255, 255, 0.85);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero .tagline {
    font-size: 1.1rem;
  }

  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  .timeline::before {
    left: 0;
  }

  .timeline-item,
  .timeline-item:nth-child(even) {
    width: 100%;
    margin-left: 0;
    padding-left: 2rem;
    padding-right: 0;
    text-align: left;
  }

  .timeline-item:nth-child(odd)::before,
  .timeline-item:nth-child(even)::before {
    left: -8px;
    right: auto;
  }

  .keynote-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

@media (max-width: 600px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
  .section { padding: 2.5rem 0; }
  .hero { padding: 4rem 0; }
  .hero-actions { flex-direction: column; align-items: center; }
  .btn { width: 100%; max-width: 300px; }
}
