/* Unique Modern Design - Daily Grant Digest */
:root {
  /* Unique Color Palette - Emerald & Coral Theme */
  --primary-color: #ff6b6b;
  --primary-dark: #d90429;
  --primary-light: #ffb3b3;
  --secondary-color: #f97316;
  --accent-color: #ff6b6b;
  --coral-color: #ff6b6b;
  --teal-color: #06b6d4;

  /* Text Colors */
  --text-dark: #0f172a;
  --text-medium: #475569;
  --text-light: #64748b;
  --text-white: #ffffff;

  /* Background Colors */
  --bg-primary: #fff8f8;
  --bg-secondary: #fff0f0;
  --bg-tertiary: #ffe5e5;
  --bg-dark: #1e293b;
  --bg-card: #ffffff;

  /* Unique Gradients */
  --gradient-hero: linear-gradient(135deg, #ffb3b3 0%, #ffe5e5 100%);
  --gradient-card: linear-gradient(145deg, #fff0f0 0%, #fff8f8 100%);
  --gradient-accent: linear-gradient(135deg, #ff6b6b 0%, #f97316 100%);
  --gradient-cool: linear-gradient(135deg, #ffb3b3 0%, #ff6b6b 100%);
  --gradient-warm: linear-gradient(135deg, #ffb3b3 0%, #f97316 100%);
  --gradient-sunset: linear-gradient(135deg, #ffb3b3 0%, #ff6b6b 100%);

  /* Shadows & Effects */
  --shadow-soft: 0 4px 20px rgba(255, 107, 107, 0.08);
  --shadow-medium: 0 8px 30px rgba(255, 107, 107, 0.12);
  --shadow-strong: 0 15px 40px rgba(255, 107, 107, 0.15);
  --shadow-colored: 0 10px 30px rgba(255, 107, 107, 0.12);

  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;

  /* Transitions */
  --transition-quick: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);

  /* Typography */
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 1.875rem;
  --font-size-4xl: 2.25rem;
  --font-size-5xl: 3rem;
}

/* Reset & Base */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  line-height: 1.7;
  color: var(--text-dark);
  background: var(--bg-primary);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-size: var(--font-size-base);
  overflow-x: hidden;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.025em;
  color: var(--text-dark);
}

h1 {
  font-size: var(--font-size-5xl);
}
h2 {
  font-size: var(--font-size-4xl);
}
h3 {
  font-size: var(--font-size-3xl);
}
h4 {
  font-size: var(--font-size-2xl);
}
h5 {
  font-size: var(--font-size-xl);
}
h6 {
  font-size: var(--font-size-lg);
}

p {
  color: var(--text-medium);
  margin-bottom: 1.5rem;
  font-weight: 400;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: var(--transition-quick);
  font-weight: 500;
}

a:hover {
  color: var(--primary-dark);
  transform: translateY(-1px);
}

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

/* Header */
.main-header {
  background: var(--gradient-hero);
  border-bottom: 2px solid var(--primary-light);
  padding: 0.5rem 0;
  box-shadow: 0 2px 8px rgba(255,107,107,0.06);
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.5rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  background: transparent;
}

.logo {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--text-primary);
  font-weight: 700;
  font-size: var(--font-size-xl);
  transition: var(--transition-fast);
}

.logo a:hover {
  transform: translateY(-1px);
  text-decoration: none;
}

.logo-image {
  height: 48px;
  width: auto;
  border-radius: var(--radius-md);
  transition: var(--transition-fast);
  box-shadow: 0 2px 8px rgba(255,107,107,0.08);
}

.logo-small {
  height: 40px !important;
}

.logo a:hover .logo-image {
  transform: scale(1.05);
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
}

.main-nav a {
  color: var(--primary-color);
  font-weight: 700;
  font-size: var(--font-size-base);
  padding: 0.4em 1.2em;
  border-radius: 999px;
  transition: background 0.18s, color 0.18s;
  position: relative;
  background: #ffe5e5;
}

.main-nav a:hover,
.main-nav a.active {
  background: var(--primary-color);
  color: #fff;
}

/* Content Layout */
.content-wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 3rem;
  flex: 1;
}

.main-content {
  min-width: 0;
}

.main-content h1 {
  margin-bottom: 2rem;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-align: center;
}

/* Article Grid */
.main-articles-layout {
  display: flex;
  flex-direction: row;
  gap: 2rem;
  align-items: flex-start;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto 2rem auto;
  padding: 0 2vw;
  box-sizing: border-box;
}

.article-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2.5rem;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.article-card, .enhanced-article-card {
  width: 100%;
  min-width: 0;
  height: auto;
  margin: 0 0 2.5rem 0;
  box-sizing: border-box;
}

.article-card {
  padding: 1.5rem 1.25rem 1.25rem 1.25rem;
  background: #fff;
  border: none;
  border-radius: 28px;
  box-shadow: 0 8px 32px rgba(30, 64, 175, 0.10), 0 1.5px 6px rgba(30, 64, 175, 0.06);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  overflow: hidden;
  transition: box-shadow 0.2s, transform 0.2s;
}

.article-card:hover {
  box-shadow: 0 16px 48px rgba(30, 64, 175, 0.16), 0 2px 8px rgba(30, 64, 175, 0.10);
  transform: translateY(-4px) scale(1.02);
}

.article-image img {
  width: 100%;
  height: 160px;
  aspect-ratio: 2/1;
  object-fit: cover;
  border-radius: 18px;
  margin-bottom: 1.25rem;
}

.article-category {
  background: #e0edff;
  color: #2563eb;
  border-radius: 999px;
  padding: 0.35em 1.1em;
  font-weight: 700;
  font-size: 0.95em;
  display: inline-block;
  margin-bottom: 1em;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.article-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.article-content h2 {
  margin-bottom: 0.5rem;
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1.2;
}

.article-content h2 a {
  color: #2563eb;
  text-decoration: none;
  transition: color 0.18s;
}

.article-content h2 a:hover {
  color: #1d4ed8;
  text-decoration: underline;
}

.article-content p,
.article-summary {
  color: #222e3a;
  margin-bottom: 1.2rem;
  font-size: 1.05rem;
  font-weight: 400;
}

.article-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid #e5e7eb;
}

.article-date {
  color: #64748b;
  font-size: 0.98em;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.continue-reading-btn {
  background: #2563eb;
  color: #fff;
  border-radius: 999px;
  padding: 0.6em 1.6em;
  font-weight: 700;
  font-size: 1.05em;
  border: none;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  box-shadow: 0 2px 8px rgba(37,99,235,0.08);
  letter-spacing: 0.03em;
  display: inline-block;
}

.continue-reading-btn:hover {
  background: #1d4ed8;
  color: #fff;
  box-shadow: 0 4px 16px rgba(37,99,235,0.13);
}

/* Beautiful Sidebar */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.sidebar-section {
  background: var(--gradient-card);
  border-radius: var(--radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-soft);
  border: 2px solid transparent;
  position: relative;
  overflow: hidden;
}

.sidebar-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient-accent);
}

.sidebar-section h3 {
  color: var(--text-dark);
  font-size: var(--font-size-xl);
  font-weight: 800;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.sidebar-section h3 i {
  background: var(--gradient-warm);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-size: var(--font-size-lg);
}

/* Popular Posts */
.popular-posts {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.popular-post {
  display: flex;
  gap: 1rem;
  padding: 1.5rem;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.5);
  transition: var(--transition-smooth);
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(10px);
}

.popular-post:hover {
  background: rgba(255, 255, 255, 0.8);
  transform: translateX(8px) translateY(-2px);
  box-shadow: var(--shadow-medium);
}

.post-number {
  background: var(--gradient-sunset);
  color: var(--text-white);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: var(--font-size-lg);
  flex-shrink: 0;
  box-shadow: var(--shadow-soft);
}

.post-content h4 {
  font-size: var(--font-size-base);
  font-weight: 700;
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.post-content h4 a {
  color: var(--text-dark);
  text-decoration: none;
  transition: var(--transition-quick);
}

.post-content h4 a:hover {
  background: var(--gradient-warm);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.post-date {
  color: var(--text-light);
  font-size: var(--font-size-sm);
  font-weight: 500;
}

/* Category Tags */
.category-tags {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.category-tag {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.6);
  color: var(--text-dark);
  text-decoration: none;
  transition: var(--transition-smooth);
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(10px);
  font-weight: 600;
}

.category-tag:hover {
  background: var(--gradient-cool);
  color: var(--text-white);
  transform: translateX(8px) scale(1.02);
  box-shadow: var(--shadow-medium);
  text-decoration: none;
}

.category-tag i {
  font-size: var(--font-size-lg);
  transition: var(--transition-quick);
}

.tag-count {
  margin-left: auto;
  background: var(--gradient-accent);
  color: var(--text-white);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-md);
  font-size: var(--font-size-xs);
  font-weight: 700;
  box-shadow: var(--shadow-soft);
}

/* Beautiful Footer */
footer {
  background: var(--gradient-card);
  position: relative;
  overflow: hidden;
  margin-top: 4rem;
  color: var(--primary-dark);
  border-top: 2px solid var(--primary-light);
}

footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient-hero);
}

.footer-content {
  max-width: 1400px;
  margin: 0 auto;
  padding: 3rem 2rem 2rem;
  text-align: center;
  position: relative;
  z-index: 1;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 3rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.footer-links a {
  color: var(--primary-color);
  text-decoration: none;
  transition: var(--transition-smooth);
  font-weight: 600;
  font-size: var(--font-size-base);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-md);
}

.footer-links a:hover {
  color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-medium);
  text-decoration: none;
}

.copyright {
  color: var(--primary-dark);
  font-size: var(--font-size-sm);
  line-height: 1.6;
  opacity: 0.8;
}

/* Article Pages Styling */
.full-article {
  background: var(--gradient-card);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-strong);
  margin-bottom: 3rem;
  border: 2px solid transparent;
}

.article-header {
  padding: 3rem 2rem;
  text-align: center;
  background: var(--gradient-hero);
  color: var(--text-white);
  position: relative;
}

.article-header::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 4px;
  background: rgba(255, 255, 255, 0.3);
  border-radius: var(--radius-sm);
}

.article-header .article-category {
  background: rgba(255, 255, 255, 0.2);
  margin: 0 auto 1.5rem;
  backdrop-filter: blur(10px);
}

.article-header h1 {
  color: var(--text-white);
  margin-bottom: 1.5rem;
  background: none;
  -webkit-text-fill-color: inherit;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.article-meta {
  display: flex;
  justify-content: center;
  gap: 2rem;
  font-size: var(--font-size-sm);
  opacity: 0.9;
  font-weight: 600;
}

.article-image-hero {
  height: 400px;
  overflow: hidden;
  position: relative;
}

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

.article-content {
  padding: 3rem 2rem;
}

.article-content h2 {
  color: var(--text-dark);
  margin: 2.5rem 0 1.5rem;
  font-size: var(--font-size-3xl);
  font-weight: 800;
}

.article-content h3 {
  color: var(--text-dark);
  margin: 2rem 0 1rem;
  font-size: var(--font-size-2xl);
  font-weight: 700;
}

.article-content ul,
.article-content ol {
  margin: 1.5rem 0 1.5rem 2rem;
}

.article-content li {
  margin-bottom: 0.75rem;
  color: var(--text-medium);
  line-height: 1.7;
}

.article-tags {
  display: flex;
  gap: 1rem;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 2px solid var(--bg-tertiary);
  flex-wrap: wrap;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .main-articles-layout { flex-direction: column; }
  .article-grid { width: 100%; }
  .popular-posts-sidebar { width: 100%; margin-top: 2rem; max-width: 100%; }
  .article-card { width: 100%; height: auto; }
}

@media (max-width: 768px) {
  .header-container {
    flex-direction: column;
    gap: 1.5rem;
    text-align: center;
    padding: 1rem;
  }

  .main-nav {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
  }

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

  .article-content {
    padding: 2rem 1.5rem;
  }

  .article-header {
    padding: 2rem 1.5rem;
  }

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

  .article-meta {
    flex-direction: column;
    gap: 0.5rem;
  }

  .sidebar-section {
    padding: 1.5rem;
  }
}

@media (max-width: 480px) {
  .content-wrapper {
    padding: 1rem;
  }

  .header-container {
    padding: 0.75rem;
  }

  .article-content {
    padding: 1.5rem 1rem;
  }

  .article-header {
    padding: 1.5rem 1rem;
  }

  .sidebar-section {
    padding: 1rem;
  }

  .main-content h1 {
    font-size: var(--font-size-3xl);
  }
}

@media (max-width: 900px) {
  .article-grid { grid-template-columns: 1fr; }
  .article-image-wrapper { height: 180px; }
}

/* Animations */
@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.article-card {
  animation: slideInUp 0.6s ease-out;
}

.article-card:nth-child(2) {
  animation-delay: 0.1s;
}
.article-card:nth-child(3) {
  animation-delay: 0.2s;
}
.article-card:nth-child(4) {
  animation-delay: 0.3s;
}
.article-card:nth-child(5) {
  animation-delay: 0.4s;
}
.article-card:nth-child(6) {
  animation-delay: 0.5s;
}

/* Focus States */
a:focus,
button:focus {
  outline: 3px solid var(--primary-color);
  outline-offset: 2px;
}

.popular-posts-sidebar {
  width: 40%;
  min-width: 260px;
  max-width: 500px;
}

.enhanced-article-card {
  background: linear-gradient(135deg, #fff0f0 0%, #fff8f8 100%);
  box-shadow: 0 8px 32px rgba(255,107,107,0.10), 0 1.5px 6px rgba(255,107,107,0.06);
  border-radius: 28px;
  padding: 0;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 480px;
  transition: box-shadow 0.2s, transform 0.2s;
}
.enhanced-article-card:hover {
  box-shadow: 0 16px 48px rgba(255,107,107,0.16), 0 2px 8px rgba(255,107,107,0.10);
  transform: translateY(-4px) scale(1.02);
}

.article-image-wrapper {
  position: relative;
  width: 100%;
  height: 260px;
  overflow: hidden;
  border-top-left-radius: 28px;
  border-top-right-radius: 28px;
  background: #ffe5e5;
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
}
.article-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-top-left-radius: 28px;
  border-top-right-radius: 28px;
  display: block;
}

.enhanced-category {
  position: absolute;
  top: 18px;
  left: 18px;
  z-index: 2;
  background: #ff6b6b;
  color: #fff;
  border-radius: 999px;
  padding: 0.38em 1.2em;
  font-weight: 700;
  font-size: 1em;
  box-shadow: 0 2px 8px rgba(255,107,107,0.10);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0.97;
}

.enhanced-article-card .article-content {
  padding: 2rem 1.5rem 1.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.enhanced-article-card h2 {
  font-size: 1.45rem;
  font-weight: 800;
  margin-bottom: 0.7rem;
  color: #d90429;
  line-height: 1.2;
}

.enhanced-article-card h2 a {
  color: #d90429;
  text-decoration: none;
  transition: color 0.18s;
}
.enhanced-article-card h2 a:hover {
  color: #ff6b6b;
  text-decoration: underline;
}

.enhanced-article-card .article-summary {
  color: #222e3a;
  margin-bottom: 1.5rem;
  font-size: 1.08rem;
  font-weight: 400;
}

.enhanced-btn {
  width: 100%;
  background: linear-gradient(90deg, #ff6b6b 0%, #ffb3b3 100%);
  color: #fff;
  border-radius: 999px;
  padding: 0.7em 0;
  font-weight: 700;
  font-size: 1.08em;
  border: none;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  box-shadow: 0 2px 8px rgba(255,107,107,0.08);
  letter-spacing: 0.03em;
  margin-top: auto;
  display: block;
  text-align: center;
}
.enhanced-btn:hover {
  background: linear-gradient(90deg, #d90429 0%, #ff6b6b 100%);
  color: #fff;
  box-shadow: 0 4px 16px rgba(255,107,107,0.13);
}
