:root {
  --bg-color: #fff9c4;
  /* Pastel Yellow */
  --text-color: #2d3748;
  --card-bg: #ffffff;
  --primary-color: #ff4081;
  /* Pink */
  --secondary-color: #00e5ff;
  /* Cyan */
  --accent-color: #ffd740;
  /* Amber */
  --border-radius: 16px;
  --shadow: 4px 4px 0px rgba(0, 0, 0, 0.15);
  --border: 2px solid #2d3748;
}

html {
  color: var(--text-color);
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
  margin: 0;
  background-color: var(--bg-color);
  background-image: radial-gradient(#ff80ab 1px, transparent 1px), radial-gradient(#80d8ff 1px, transparent 1px);
  background-size: 20px 20px;
  background-position: 0 0, 10px 10px;
}

header {
  background: var(--card-bg);
  padding: 1rem 0;
  margin-bottom: 2rem;
  position: relative;
  z-index: 10;
}

header h1 {
  margin: 0;
  color: var(--primary-color);
  text-shadow: 2px 2px 0px #2d3748;
  font-size: 2.5rem;
  letter-spacing: 1px;
}

header p {
  margin: 0.5rem 0 0;
  font-weight: bold;
  color: var(--text-color);
  text-align: center;
}

h2 {
  margin: 0 0 1.5rem;
  color: var(--text-color);
  font-size: 1.8rem;
  border-bottom: 4px dotted var(--secondary-color);
  display: block;
  background-color: white;
  padding: 1rem;
  border-radius: 1rem 1rem 0 0;
}

h3 {
  color: var(--primary-color);
  margin-top: 0;
}

.container {
  width: min(1200px, 90%);
  margin: 0 auto;
}

main {
  display: flex;
  gap: 2rem;
  padding: 0 0 4rem;
}

aside {
  flex: 0 0 300px;
  background: var(--card-bg);
  border: var(--border);
  border-radius: var(--border-radius);
  padding: 1.5rem;
  height: fit-content;
  box-shadow: var(--shadow);
}

.hint {
  font-size: 0.85rem;
  color: #718096;
}

.anime-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.anime-list button {
  width: 100%;
  border: var(--border);
  background: #fff;
  color: var(--text-color);
  padding: 1rem;
  border-radius: 12px;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s ease;
  font-size: 1rem;
  font-weight: bold;
  box-shadow: 2px 2px 0px rgba(0, 0, 0, 0.1);
}

.anime-list button.active,
.anime-list button:hover {
  background: var(--secondary-color);
  color: #fff;
  transform: translate(-2px, -2px);
  box-shadow: 4px 4px 0px #2d3748;
}

.details {
  flex: 1;
}

.anime-details {
  background: var(--card-bg);
  border: var(--border);
  border-radius: var(--border-radius);
  padding: 2.5rem;
  box-shadow: var(--shadow);
  position: relative;
}

.summary {
  line-height: 1.8;
  font-size: 1.05rem;
}

.chart-block {
  margin: 2rem 0;
  background: #f7fafc;
  padding: 1rem;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
}

.analysis-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
  margin: 0;
  padding: 0;
}

.analysis-item {
  background: #fff;
  border: var(--border);
  border-radius: 12px;
  padding: 1rem 1.25rem;
  box-shadow: 4px 4px 0px var(--accent-color);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  transition: transform 0.2s;
}

.analysis-item:hover {
  transform: translateY(-2px);
}

.analysis-term {
  margin: 0;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-weight: 800;
  color: var(--primary-color);
  font-size: 1.1rem;
}

.analysis-score {
  font-size: 1rem;
  background: var(--text-color);
  color: #fff;
  padding: 0.2rem 0.6rem;
  border-radius: 20px;
}

.analysis-item dd {
  margin: 0;
  color: var(--text-color);
  font-size: 0.95rem;
  line-height: 1.5;
}

/* Filters */
.filters select {
  background: #fff;
  border: var(--border);
  padding: 0.5rem;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 2px 2px 0px rgba(0, 0, 0, 0.1);
}

.filters select:hover {
  background: #f0f0f0;
}

@media (max-width: 900px) {
  main {
    flex-direction: column;
  }
}

.site-logo {
  max-height: 230px;
  width: auto;
  max-width: 100%;
  display: block;
  margin: 0 auto;
}

/* Dashboard */
.dashboard {
  padding: 1rem;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 1rem;
}

.dashboard-card {
  background: var(--surface);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background-color: white;
}

.dashboard-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 12px rgba(0, 0, 0, 0.2);
  border-color: var(--primary-color);
}

.dashboard-card h3 {
  margin: 0 0 1rem 0;
  font-size: 1.25rem;
  color: var(--text);
  border-bottom: 2px solid var(--primary-color);
  padding-bottom: 0.5rem;
}

.score-grid {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.5rem 1rem;
  font-size: 0.9rem;
}

.score-label {
  color: var(--text-muted);
}

.score-value {
  font-weight: bold;
  color: var(--primary);
}

.hidden {
  display: none !important;
}

.empty-state {
  background: var(--card-bg);
  border: 2px dashed var(--text-color);
  border-radius: var(--border-radius);
  padding: 3rem;
  text-align: center;
  color: var(--text-color);
  font-weight: bold;
  box-shadow: var(--shadow);
}

/* Share Button */
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--card-bg);
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-left: 1rem;
}

.share-btn:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 6px rgba(255, 64, 129, 0.3);
}

.share-btn svg {
  width: 1.2em;
  height: 1.2em;
}

/* Adjust header for share button */
.anime-details header {}

/* Share Buttons Container */
.share-buttons {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Social Share Buttons */
.social-share-buttons {
  display: flex;
  gap: 0.5rem;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.social-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.twitter-btn {
  background: #000000;
  color: white;
}

.twitter-btn:hover {
  background: #333333;
}

.facebook-btn {
  background: #1877F2;
  color: white;
}

.facebook-btn:hover {
  background: #3b5998;
}

.line-btn {
  background: #00B900;
  color: white;
}

.line-btn:hover {
  background: #00a000;
}

/* Affiliate */
.affiliate-section {
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 2px dashed var(--secondary-color);
}

.amazon-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #FF9900;
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s, box-shadow 0.2s;
}

.amazon-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  background: #ffad33;
}