/* CSS Variables */
:root {
  --bg: #F7F5F2;
  --surface: #FFFFFF;
  --text: #14171A;
  --muted: #5B6672;
  --border: #E5E0D8;
  --accent: #7A1E2D;
  --accent2: #19324A;
  --highlight: #C7A46B;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.7;
  font-size: 16px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.3;
  color: var(--text);
}

h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
}

h2 {
  font-size: 2rem;
  margin-bottom: 1.5rem;
}

h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

h4 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

p {
  margin-bottom: 1rem;
  color: var(--text);
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.3s ease;
  border-bottom: 1px solid transparent;
}

a:hover {
  color: var(--accent2);
  border-bottom: 1px solid var(--accent);
}

/* Header */
header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  max-width: 1400px;
  margin: 0 auto;
}

nav .logo {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--accent);
}

nav ul {
  display: flex;
  list-style: none;
  gap: 2rem;
}

nav ul li a {
  color: var(--text);
  font-weight: 500;
  border-bottom: 2px solid transparent;
  transition: all 0.3s ease;
}

nav ul li a:hover {
  color: var(--accent);
  border-bottom: 2px solid var(--accent);
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text);
}

/* Ticker Strip */
.ticker-strip {
  background: var(--accent2);
  color: white;
  padding: 0.8rem 2rem;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 2rem;
  max-width: 1400px;
  margin: 0 auto;
}

.ticker-label {
  font-weight: 700;
  min-width: 100px;
}

.ticker-items {
  display: flex;
  gap: 2rem;
}

.ticker-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  animation: scroll 30s linear infinite;
}

/* Container */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* Main Content */
main {
  min-height: 80vh;
}

/* HERO */
.hero {
  position: relative;
  height: 500px;
  margin-bottom: 3rem;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.hero-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  height: 100%;
  gap: 2rem;
  align-items: center;
}

.hero-text h1 {
  color: var(--text);
}

.hero-text p {
  font-size: 1.1rem;
  color: var(--muted);
}

.hero-meta {
  display: flex;
  gap: 1rem;
  margin: 1.5rem 0;
  font-size: 0.9rem;
  color: var(--muted);
}

.hero-category {
  background: var(--accent);
  color: white;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: 2px;
  display: inline-block;
}

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

.cta-link {
  display: inline-block;
  color: var(--accent);
  font-weight: 700;
  margin-top: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--accent);
  transition: all 0.3s ease;
}

.cta-link:hover {
  color: var(--accent2);
  border-bottom-color: var(--accent2);
}

/* Breaking News */
.breaking-section {
  margin-bottom: 3rem;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  border-bottom: 2px solid var(--accent);
  padding-bottom: 1rem;
}

.section-header h2 {
  margin: 0;
}

.view-all {
  color: var(--accent);
  font-weight: 700;
  text-decoration: underline;
}

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

.breaking-card {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 1rem;
  transition: all 0.3s ease;
  cursor: pointer;
}

.breaking-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.breaking-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  margin-bottom: 1rem;
}

.breaking-label {
  background: var(--accent);
  color: white;
  padding: 0.3rem 0.8rem;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: 2px;
  margin-bottom: 0.5rem;
  display: inline-block;
}

.breaking-card h4 {
  margin: 0.5rem 0;
  line-height: 1.4;
}

.breaking-time {
  font-size: 0.85rem;
  color: var(--muted);
}

/* Grid Sections */
.grid-2x3 {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2rem;
  margin-bottom: 3rem;
}

.main-card {
  background: var(--surface);
  border: 1px solid var(--border);
  overflow: hidden;
}

.main-card img {
  width: 100%;
  height: 300px;
  object-fit: cover;
}

.main-card-content {
  padding: 2rem;
}

.main-card-content h3 {
  margin-bottom: 0.5rem;
}

.main-card-content p {
  color: var(--muted);
  font-size: 0.95rem;
}

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

.side-card {
  background: var(--surface);
  border: 1px solid var(--border);
  overflow: hidden;
}

.side-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
}

.side-card-content {
  padding: 1rem;
}

.side-card-content h4 {
  margin: 0 0 0.5rem 0;
  font-size: 0.95rem;
  line-height: 1.3;
}

.side-card-content p {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0;
}

/* Topic Card Grid */
.topic-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-bottom: 3rem;
}

.topic-card {
  background: var(--surface);
  border: 1px solid var(--border);
  overflow: hidden;
}

.topic-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.topic-card-content {
  padding: 1.5rem;
}

.topic-card h4 {
  margin: 0 0 0.5rem 0;
  line-height: 1.4;
}

.topic-card p {
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 1rem;
}

.topic-card .read-more {
  color: var(--accent);
  font-weight: 700;
  font-size: 0.9rem;
}

/* Popular Section */
.popular-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.popular-item {
  display: flex;
  gap: 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 1rem;
  transition: all 0.3s ease;
}

.popular-item:hover {
  transform: translateX(5px);
}

.popular-item img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  flex-shrink: 0;
}

.popular-content {
  flex: 1;
}

.popular-content h4 {
  margin: 0 0 0.5rem 0;
  line-height: 1.3;
}

.popular-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--muted);
}

/* Latest News */
.latest-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.latest-item {
  background: var(--surface);
  border: 1px solid var(--border);
  overflow: hidden;
}

.latest-item img {
  width: 100%;
  height: 120px;
  object-fit: cover;
}

.latest-item-content {
  padding: 1rem;
}

.latest-item-content h4 {
  margin: 0 0 0.5rem 0;
  font-size: 0.95rem;
  line-height: 1.3;
}

.latest-time {
  font-size: 0.8rem;
  color: var(--muted);
}

.load-more-btn {
  display: block;
  width: 100%;
  padding: 1rem;
  background: var(--accent2);
  color: white;
  border: none;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.3s ease;
  margin-bottom: 3rem;
}

.load-more-btn:hover {
  background: var(--accent);
}

/* Gallery */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  height: 250px;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.gallery-item:hover img {
  transform: scale(1.05);
}

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.9);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
}

.lightbox-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  color: white;
  font-size: 2rem;
  cursor: pointer;
  background: none;
  border: none;
}

/* Contact Form */
.contact-form {
  max-width: 600px;
  background: var(--surface);
  padding: 2rem;
  border: 1px solid var(--border);
  margin-bottom: 3rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--text);
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.8rem;
  border: 1px solid var(--border);
  font-family: inherit;
  font-size: 1rem;
  color: var(--text);
}

.form-group textarea {
  resize: vertical;
  min-height: 150px;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(122, 30, 45, 0.1);
}

.form-check {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.form-check input[type="checkbox"] {
  width: auto;
  margin-top: 0.3rem;
}

.form-check label {
  margin: 0;
  font-weight: normal;
  font-size: 0.95rem;
}

.form-btn {
  background: var(--accent);
  color: white;
  padding: 0.8rem 2rem;
  border: none;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.3s ease;
}

.form-btn:hover {
  background: var(--accent2);
}

/* Article Page */
.article-header {
  margin-bottom: 3rem;
}

.breadcrumbs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.breadcrumbs a {
  color: var(--accent);
}

.article-meta {
  display: flex;
  gap: 1.5rem;
  margin: 1rem 0;
  font-size: 0.9rem;
  color: var(--muted);
}

.article-featured {
  width: 100%;
  height: 400px;
  object-fit: cover;
  margin-bottom: 2rem;
}

.article-content {
  max-width: 900px;
}

.article-content h2 {
  margin-top: 2rem;
}

.article-content h3 {
  margin-top: 1.5rem;
}

.callout {
  background: var(--surface);
  border-left: 4px solid var(--accent);
  padding: 1.5rem;
  margin: 2rem 0;
}

.callout-title {
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.article-table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
}

.article-table th,
.article-table td {
  border: 1px solid var(--border);
  padding: 0.8rem;
  text-align: left;
}

.article-table th {
  background: var(--accent2);
  color: white;
  font-weight: 700;
}

.related-articles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin: 3rem 0;
}

/* Footer */
footer {
  background: var(--text);
  color: white;
  padding: 3rem 2rem;
  margin-top: 4rem;
  border-top: 2px solid var(--accent);
}

footer .container {
  max-width: 1400px;
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h4 {
  color: white;
  margin-bottom: 1rem;
}

.footer-section ul {
  list-style: none;
}

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

.footer-section ul li a {
  color: #ccc;
  transition: color 0.3s ease;
}

.footer-section ul li a:hover {
  color: var(--highlight);
  border-bottom: none;
}

.footer-contact {
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  font-size: 0.85rem;
  color: #ccc;
}

/* Cookie Banner */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--accent2);
  color: white;
  padding: 1rem 2rem;
  display: none;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  z-index: 999;
}

.cookie-banner.active {
  display: flex;
}

.cookie-banner p {
  margin: 0;
  font-size: 0.9rem;
}

.cookie-banner button {
  background: var(--highlight);
  color: var(--text);
  border: none;
  padding: 0.5rem 1rem;
  cursor: pointer;
  font-weight: 700;
  white-space: nowrap;
}

.cookie-banner button:hover {
  background: #d4b999;
}

/* Responsive */
@media (max-width: 768px) {
  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.5rem;
  }

  nav {
    padding: 1rem;
  }

  nav ul {
    display: none;
  }

  nav.active ul {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    background: var(--surface);
    padding: 1rem;
    gap: 1rem;
    border-bottom: 1px solid var(--border);
  }

  .mobile-menu-btn {
    display: block;
  }

  .hero-content {
    grid-template-columns: 1fr;
  }

  .ticker-strip {
    flex-direction: column;
    gap: 0.5rem;
  }

  .breaking-grid {
    grid-template-columns: 1fr;
  }

  .grid-2x3 {
    grid-template-columns: 1fr;
  }

  .side-grid {
    grid-template-columns: 1fr;
  }

  .topic-grid {
    grid-template-columns: 1fr;
  }

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

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

  .related-articles {
    grid-template-columns: 1fr;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 1rem;
  }

  .container {
    padding: 0 1rem;
  }
}

@media (max-width: 480px) {
  h1 {
    font-size: 1.5rem;
  }

  h2 {
    font-size: 1.25rem;
  }

  nav ul {
    gap: 1rem;
  }

  .breaking-grid {
    grid-template-columns: 1fr;
  }

  .gallery-grid {
    grid-template-columns: 1fr;
  }

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