/* ============================================================
   TURTLE DETAIL PAGES – warm gold-amber + soft teal palette
   Smooth hover, takeaway UNDER graph (no overlap), rich text
============================================================ */

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

body {
  font-family: 'Inter', sans-serif;
  line-height: 1.7;
  color: #e5e7eb;
  background: #0b132b;
}

/* Hero */
.detail-hero {
  position: relative;
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 7rem 2rem 9rem;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  overflow: hidden;
}

.hero-bg-grain {
  position: absolute;
  inset: 0;
  background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><filter id="n"><feTurbulence type="fractalNoise" baseFrequency="0.9" numOctaves="3"/><feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.04 0"/></filter><rect width="100" height="100" filter="url(%23n)" opacity="0.05"/></svg>');
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 960px;
}

.detail-hero h1 {
  font-size: clamp(3.2rem, 8vw, 5.4rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  background: linear-gradient(90deg, #fbbf24, #f59e0b, #10b981);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 1.4rem;
  text-shadow: 0 4px 20px rgba(251,191,36,0.35);
}

.hero-subtitle {
  font-size: clamp(1.25rem, 3vw, 1.5rem);
  color: #fde68a;
  opacity: 0.94;
  max-width: 800px;
  margin: 0 auto;
  font-weight: 400;
}

/* Main Content */
.detail-content {
  padding: 6rem 2rem 10rem;
  max-width: 1320px;
  margin: 0 auto;
}

.content-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3.5rem;
  margin-bottom: 7rem;
}

@media (max-width: 900px) {
  .content-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
}

/* Big Cards – gentle lift only, no jump/scale */
.info-card,
.visual-card {
  background: linear-gradient(145deg, rgba(30,41,59,0.86), rgba(15,23,42,0.94));
  border: 1px solid rgba(251,191,36,0.18);
  border-radius: 1.6rem;
  padding: 2.8rem;
  box-shadow: 0 12px 48px rgba(0,0,0,0.4);
  transition: all 0.7s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.info-card:hover,
.visual-card:hover {
  transform: translateY(-4px);
  border-color: rgba(251,191,36,0.5);
  box-shadow: 0 28px 80px rgba(251,191,36,0.28);
}

.card-header {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  margin-bottom: 1.8rem;
  justify-content: center;
  text-align: center;
}

.card-header i {
  font-size: 2.4rem;
  color: #fbbf24;
}

.card-header h2,
.visual-header h3 {
  font-size: 2rem;
  font-weight: 800;
  color: #fde68a;
  letter-spacing: -0.01em;
  text-align: center;
}

/* Formula Section */
.formula-section {
  margin-bottom: 7rem;
}

.formula-section h2 {
  font-size: 2.4rem;
  text-align: center;
  color: #fde68a;
  margin-bottom: 2rem;
}

.main-formula {
  background: rgba(251,191,36,0.08);
  border: 1px solid rgba(251,191,36,0.35);
  border-radius: 1.4rem;
  padding: 2.5rem;
  box-shadow: 0 8px 32px rgba(251,191,36,0.15);
}

.formula-main {
  font-size: 1.9rem;
  font-weight: 700;
  color: #fde68a;
  text-align: center;
  margin-bottom: 1.8rem;
  padding: 1.2rem;
  background: rgba(251,191,36,0.12);
  border-radius: 1rem;
}

.formula-details {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.formula-breakdown {
  background: rgba(16,185,129,0.08);
  border: 1px solid rgba(16,185,129,0.25);
  border-radius: 1rem;
  padding: 1.2rem;
  text-align: center;
}

.formula-breakdown .label {
  font-size: 1rem;
  color: #d1d5db;
  display: block;
  margin-bottom: 0.4rem;
}

.formula-breakdown .value {
  font-size: 1.25rem;
  font-weight: 700;
  color: #34d399;
}

.formula-note {
  text-align: center;
  font-size: 1.05rem;
  color: #9ca3af;
  margin-top: 1.8rem;
  font-style: italic;
}

/* Example Section */
.example-section h2 {
  font-size: 2.4rem;
  text-align: center;
  color: #fde68a;
  margin-bottom: 2rem;
}

.example-intro {
  font-size: 1.25rem;
  text-align: center;
  color: #d1d5db;
  max-width: 900px;
  margin: 0 auto 3rem;
  line-height: 1.7;
}

.scenario-list {
  display: flex;
  flex-direction: column;
  gap: 1.8rem;
}

.scenario-item {
  background: rgba(251,191,36,0.1);
  border: 1px solid rgba(251,191,36,0.3);
  border-radius: 1.2rem;
  padding: 1.6rem;
  transition: all 0.4s ease;
}

.scenario-item:hover {
  transform: translateY(-4px);
  background: rgba(251,191,36,0.16);
}

.scenario-title {
  font-size: 1.3rem;
  color: #fde68a;
  display: block;
  margin-bottom: 0.6rem;
  text-align: center;
}

.scenario-result {
  font-size: 1.45rem;
  font-weight: 700;
  color: #34d399;
  text-align: center;
}

/* Chart & Takeaway – taller + text UNDER graph */
.chart-wrapper {
  position: relative;
  height: 420px;               /* tall enough for full orange gradient */
  background: #0f172a;
  border-radius: 1.4rem;
  overflow: hidden;
  box-shadow: inset 0 0 40px rgba(0,0,0,0.6);
  margin-bottom: 6rem;         /* generous space below for takeaway */
}

.sizing-chart {
  width: 100%;
  height: 100%;
}

/* Takeaway text – placed UNDER the graph (not inside) */
.chart-takeaway {
  margin-top: 1.5rem;
  text-align: center;
  font-size: 1.1rem;
  font-style: italic;
  color: #d97706;
  background: rgba(251,191,36,0.08);
  border: 1px solid rgba(251,191,36,0.25);
  border-radius: 1rem;
  padding: 1.4rem 2rem;
  box-shadow: 0 6px 24px rgba(251,191,36,0.15);
  line-height: 1.6;
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
}

/* Extra Info */
.extra-info {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2.5rem;
  margin-bottom: 7rem;
}

.info-item {
  background: rgba(30,41,59,0.75);
  border: 1px solid rgba(251,191,36,0.16);
  border-radius: 1.4rem;
  padding: 2.2rem;
  text-align: center;
  transition: all 0.45s ease;
}

.info-item:hover {
  transform: translateY(-8px);
  border-color: rgba(251,191,36,0.45);
}

.info-item i {
  font-size: 2.4rem;
  color: #fbbf24;
  margin-bottom: 1.2rem;
}

.info-item h4 {
  font-size: 1.45rem;
  color: #fde68a;
  margin-bottom: 0.9rem;
}

/* Back Link */
.back-link {
  text-align: center;
}

.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  padding: 1.1rem 2.5rem;
  background: rgba(251,191,36,0.16);
  border: 1px solid rgba(251,191,36,0.35);
  border-radius: 1.1rem;
  color: #fde68a;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.45s ease;
}

.btn-back:hover {
  background: rgba(251,191,36,0.26);
  transform: translateY(-4px);
  border-color: #fbbf24;
  box-shadow: 0 10px 30px rgba(251,191,36,0.3);
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(35px);
  animation: fadeInUp 1s forwards;
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive */
@media (max-width: 900px) {
  .detail-hero { padding: 6rem 1.5rem 8rem; }
  .content-grid { gap: 3rem; }
  .detail-content { padding: 5rem 1.5rem 8rem; }
  .main-formula { padding: 2rem; }
  .chart-wrapper { height: 380px; } /* slightly shorter on mobile */
  .chart-takeaway { font-size: 1rem; padding: 1.2rem 1.6rem; }
}