/* ==========================================================================
   NARANJA EXPRIMIA — Tools Shared Styles
   ========================================================================== */

.tool-page {
  max-width: 860px;
  margin: 0 auto;
  padding: 6rem 2rem 4rem;
}

.tool-hero {
  margin-bottom: 3rem;
}

/* ── WP editor content in tool pages ── */
.tool-seo-content {
  margin-bottom: 3rem;
}

.tool-seo-content h1 {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  color: #0a0a0a;
  line-height: 1.15;
  margin: 0 0 1rem;
}

.tool-seo-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 2rem 0 1rem;
  color: #0a0a0a;
}

.tool-seo-content p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: #444;
  margin-bottom: 1.5rem;
}

.tool-category-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  color: #FF4D00;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
  display: block;
}

.tool-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  color: #0a0a0a;
  line-height: 1.15;
  margin: 0 0 1rem;
}

.tool-intro {
  font-size: 1.05rem;
  line-height: 1.8;
  color: #444;
  margin-bottom: 2rem;
}

.tool-intro p { margin: 0 0 1rem; }
.tool-intro ul { padding-left: 1.5rem; margin: 0 0 1rem; }
.tool-intro li { margin-bottom: 0.4rem; }

/* ── Calculator box ── */
.tool-calculator {
  background: #ffffff;
  border: 2px solid #f0ebe4;
  border-radius: 16px;
  padding: 2.5rem;
  margin: 3rem 0;
  box-shadow: 0 4px 24px rgba(0,0,0,0.06);
}

.tool-calculator h2 {
  font-size: 1.3rem;
  font-weight: 700;
  margin: 0 0 1.5rem;
  color: #0a0a0a;
}

/* ── Fields ── */
.tool-field {
  margin-bottom: 1.25rem;
}

.tool-field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: #333;
  margin-bottom: 0.4rem;
}

.tool-field input,
.tool-field select,
.tool-field textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1.5px solid #e0dbd4;
  border-radius: 8px;
  font-size: 1rem;
  color: #0a0a0a;
  background: #faf8f5;
  transition: border-color 0.2s;
  box-sizing: border-box;
  font-family: inherit;
}

.tool-field input:focus,
.tool-field select:focus,
.tool-field textarea:focus {
  outline: none;
  border-color: #FF4D00;
  background: #fff;
}

.tool-field .field-hint {
  font-size: 0.75rem;
  color: #999;
  margin-top: 0.3rem;
  display: block;
}

/* ── 2-col grid for inputs ── */
.tool-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

/* ── Calculate button ── */
.tool-btn-calculate {
  width: 100%;
  padding: 1rem;
  background: #FF4D00;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  margin-top: 1.5rem;
  transition: background 0.2s, transform 0.15s;
}

.tool-btn-calculate:hover {
  background: #e04400;
  transform: translateY(-1px);
}

/* ── Results ── */
.tool-results {
  display: none;
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 2px solid #f0ebe4;
  animation: fadeInUp 0.3s ease;
}

.tool-results.visible {
  display: block;
}

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

.tool-results h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0 0 1.25rem;
  color: #0a0a0a;
}

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

.result-card {
  background: #f5f0eb;
  border-radius: 10px;
  padding: 1.25rem;
  text-align: center;
}

.result-card .result-value {
  font-size: 1.8rem;
  font-weight: 800;
  color: #FF4D00;
  display: block;
  margin-bottom: 0.25rem;
  line-height: 1.1;
}

.result-card .result-label {
  font-size: 0.72rem;
  color: #666;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ── Semáforo ── */
.result-semaforo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-radius: 8px;
  font-weight: 600;
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.result-semaforo.green  { background: #e8f5e9; color: #2e7d32; }
.result-semaforo.yellow { background: #fff8e1; color: #f57f17; }
.result-semaforo.red    { background: #ffebee; color: #c62828; }

/* ── Benchmark bar ── */
.benchmark-bar-wrap {
  margin-top: 1rem;
}
.benchmark-label {
  font-size: 0.8rem;
  color: #666;
  margin-bottom: 0.4rem;
  display: flex;
  justify-content: space-between;
}
.benchmark-bar {
  height: 10px;
  background: #f0ebe4;
  border-radius: 5px;
  overflow: hidden;
  margin-bottom: 0.75rem;
}
.benchmark-fill {
  height: 100%;
  background: #FF4D00;
  border-radius: 5px;
  transition: width 0.6s ease;
}

/* ── Prompt output ── */
.prompt-output-box {
  background: #f5f0eb;
  border: 1.5px solid #e0dbd4;
  border-radius: 8px;
  padding: 1.25rem;
  font-size: 0.95rem;
  line-height: 1.7;
  color: #333;
  white-space: pre-wrap;
  min-height: 120px;
  margin-bottom: 1rem;
}

.prompt-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 0.5rem;
}

.prompt-btn {
  padding: 0.65rem 1.25rem;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
  text-decoration: none;
  border: none;
  transition: background 0.2s;
}

.prompt-btn--copy    { background: #0a0a0a; color: #fff; }
.prompt-btn--copy:hover { background: #333; }
.prompt-btn--chatgpt { background: #10a37f; color: #fff; }
.prompt-btn--chatgpt:hover { background: #0d8a6c; }
.prompt-btn--claude  { background: #CC785C; color: #fff; }
.prompt-btn--claude:hover { background: #b5624a; }

/* ── Affiliate CTA strip ── */
.tool-cta-affiliate {
  background: #0a0a0a;
  color: #fff;
  border-radius: 12px;
  padding: 2rem;
  margin: 2rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.tool-cta-affiliate p { margin: 0; font-size: 1rem; }

.tool-cta-affiliate a {
  background: #FF4D00;
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
}

.tool-cta-affiliate a:hover { background: #e04400; }

/* ── Post-calc content ── */
.tool-post-content {
  margin-top: 3rem;
  padding-top: 3rem;
  border-top: 2px solid #f0ebe4;
}

.tool-post-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 1rem;
  color: #0a0a0a;
}

.tool-post-content p { line-height: 1.8; color: #444; margin-bottom: 1rem; }

.tool-tips {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
}

.tool-tips li {
  padding: 1rem 1rem 1rem 3rem;
  background: #f5f0eb;
  border-radius: 8px;
  margin-bottom: 0.75rem;
  position: relative;
  line-height: 1.6;
  color: #333;
}

.tool-tips li::before {
  content: attr(data-n);
  position: absolute;
  left: 1rem;
  top: 1rem;
  width: 1.5rem;
  height: 1.5rem;
  background: #FF4D00;
  color: #fff;
  border-radius: 50%;
  font-size: 0.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── Newsletter mini form ── */
.tool-newsletter {
  background: linear-gradient(135deg, #FF4D00, #cc3d00);
  border-radius: 12px;
  padding: 2rem;
  margin-top: 2rem;
  color: #fff;
}

.tool-newsletter h3 { margin: 0 0 0.5rem; font-size: 1.2rem; }
.tool-newsletter p  { margin: 0 0 1.25rem; opacity: 0.85; font-size: 0.9rem; }

.tool-newsletter-form {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.tool-newsletter-form input {
  flex: 1;
  min-width: 200px;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  background: rgba(255,255,255,0.2);
  color: #fff;
  box-sizing: border-box;
}

.tool-newsletter-form input::placeholder { color: rgba(255,255,255,0.6); }

.tool-newsletter-form button {
  padding: 0.75rem 1.5rem;
  background: #0a0a0a;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

/* ── Hub page ── */
.tools-hub-hero {
  background: #0a0a0a;
  color: #fff;
  padding: 8rem 5% 5rem;
  text-align: center;
}

.tools-hub-hero h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.1;
  margin: 0.5rem 0 1rem;
}

.tools-hub-hero h1 span { color: #FF4D00; }

.tools-hub-hero p {
  font-size: 1.15rem;
  color: rgba(255,255,255,0.7);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.7;
}

.tools-hub-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
  padding: 4rem 5%;
}

.tool-card {
  background: #fff;
  border: 2px solid #f0ebe4;
  border-radius: 16px;
  padding: 2rem;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.tool-card:hover {
  border-color: #FF4D00;
  box-shadow: 0 8px 32px rgba(255,77,0,0.12);
  transform: translateY(-3px);
}

.tool-card__icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  line-height: 1;
}

.tool-card__name {
  font-size: 1.1rem;
  font-weight: 700;
  color: #0a0a0a;
  margin-bottom: 0.5rem;
}

.tool-card__desc {
  font-size: 0.875rem;
  color: #666;
  line-height: 1.6;
  flex: 1;
  margin-bottom: 1.25rem;
}

.tool-card__cta {
  font-size: 0.875rem;
  font-weight: 700;
  color: #FF4D00;
}

/* ── Chart bar (Google Ads) ── */
.chart-bars {
  display: flex;
  gap: 1rem;
  align-items: flex-end;
  height: 160px;
  margin-top: 1rem;
  padding: 0 0.5rem;
}

.chart-bar-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  height: 100%;
  justify-content: flex-end;
}

.chart-bar {
  width: 100%;
  border-radius: 6px 6px 0 0;
  transition: height 0.5s ease;
  min-height: 4px;
}

.chart-bar--invest  { background: #0a0a0a; }
.chart-bar--revenue { background: #FF4D00; }
.chart-bar-label    { font-size: 0.7rem; color: #666; text-align: center; font-weight: 600; }
.chart-bar-val      { font-size: 0.8rem; font-weight: 700; color: #0a0a0a; }

/* ── Orange bullet points ── */
.tool-intro ul,
.tool-page ul {
  list-style: none;
  padding: 0;
  margin: 1rem 0 1.5rem;
}

.tool-intro ul li,
.tool-page ul li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.6rem;
  font-size: 1.05rem;
  line-height: 1.6;
  color: #333;
}

.tool-intro ul li::before,
.tool-page ul li::before {
  content: "●";
  position: absolute;
  left: 0;
  top: 0;
  color: #FF4D00;
  font-size: 0.6rem;
  line-height: 2.2;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .tool-grid-2      { grid-template-columns: 1fr; }
  .tool-calculator  { padding: 1.5rem; }
  .tool-page        { padding: 5rem 1.25rem 3rem; }
  .tools-hub-grid   { grid-template-columns: 1fr; }
  .results-grid     { grid-template-columns: 1fr 1fr; }
  .tool-cta-affiliate { flex-direction: column; }
  .chart-bars       { height: 120px; }
}

/* ── Ad zone ── */
.ad-zone {
  background: #f5f0eb;
  border: 1px dashed #e0dbd4;
  border-radius: 8px;
  padding: 1.5rem;
  text-align: center;
  margin: 2rem 0;
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ad-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #bbb;
}

/* ── Glossary hero ── */
.glossary-hero {
  background: #0a0a0a;
  color: #fff;
  padding: 8rem 5% 4rem;
  text-align: center;
}

.glossary-eyebrow {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #FF4D00;
  margin-bottom: 0.75rem;
}

.glossary-title {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  line-height: 1.1;
  margin: 0 0 1rem;
}

.glossary-subtitle {
  font-size: 1.1rem;
  color: rgba(255,255,255,0.65);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ── Glossary A–Z nav ── */
.glossary-alpha-nav {
  position: sticky;
  top: 65px;
  background: #fff;
  z-index: 200;
  padding: 0.75rem 5%;
  border-bottom: 2px solid #f0ebe4;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.alpha-btn {
  width: 2.2rem;
  height: 2.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 700;
  color: #666;
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
  border: none;
  background: none;
}

.alpha-btn:hover {
  color: #FF4D00;
  background: #fff0eb;
}

.alpha-btn.active {
  background: #FF4D00 !important;
  color: #fff !important;
}

/* ── Glossary content ── */
.glossary-content {
  max-width: 860px;
  margin: 0 auto;
  padding: 3rem 5%;
}

.glossary-letter-section {
  margin-bottom: 3rem;
  scroll-margin-top: 140px;
}

.glossary-letter-heading {
  font-size: 2.5rem;
  font-weight: 800;
  color: #FF4D00;
  border-bottom: 3px solid #FF4D00;
  padding-bottom: 0.5rem;
  margin-bottom: 1.5rem;
  line-height: 1;
}

.glossary-list {
  margin: 0;
  padding: 0;
}

.glossary-list dt {
  font-size: 1.1rem;
  font-weight: 700;
  color: #0a0a0a;
  margin: 1.5rem 0 0.4rem;
  scroll-margin-top: 150px;
}

.glossary-list dt:first-child {
  margin-top: 0;
}

.glossary-list dd {
  margin: 0 0 0.5rem 0;
  padding: 0.75rem 0 0.75rem 1.25rem;
  border-left: 3px solid #f0ebe4;
}

.glossary-list dd p {
  margin: 0 0 0.4rem;
  font-size: 0.95rem;
  line-height: 1.75;
  color: #444;
}

.term-example {
  font-size: 0.875rem !important;
  color: #666 !important;
  font-style: italic;
  background: #faf8f5;
  padding: 0.5rem 0.75rem !important;
  border-radius: 4px;
}

.term-related {
  font-size: 0.8rem !important;
  color: #999 !important;
}

.term-related a {
  color: #FF4D00;
  text-decoration: none;
}

.term-related a:hover {
  text-decoration: underline;
}

/* ── FAQ category filter nav ── */
.faq-category-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 2rem 5%;
  max-width: 960px;
  margin: 0 auto;
  border-bottom: 2px solid #f0ebe4;
}

.faq-cat-btn {
  padding: 0.5rem 1.25rem;
  border-radius: 24px;
  border: 2px solid #e0dbd4;
  background: #fff;
  color: #666;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
}

.faq-cat-btn:hover {
  border-color: #FF4D00;
  color: #FF4D00;
}

.faq-cat-btn.active {
  background: #FF4D00;
  border-color: #FF4D00;
  color: #fff;
}

/* ── FAQ accordion ── */
.faq-section {
  max-width: 860px;
  margin: 0 auto;
  padding: 2rem 5% 4rem;
  width: 100%;
  box-sizing: border-box;
}

.faq-category {
  margin-bottom: 3rem;
  width: 100%;
  box-sizing: border-box;
}

.faq-category-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: #0a0a0a;
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid #FF4D00;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.faq-item {
  border-bottom: 1px solid #f0ebe4;
  list-style: none;
  width: 100%;
  box-sizing: border-box;
  display: block;
}

.faq-item summary {
  padding: 1.25rem 0;
  font-size: 1rem;
  font-weight: 600;
  color: #0a0a0a;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  line-height: 1.4;
  list-style: none;
  width: 100%;
  box-sizing: border-box;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  min-width: 28px;
  border-radius: 50%;
  background: #fff0eb;
  color: #FF4D00;
  font-size: 1.2rem;
  font-weight: 300;
  line-height: 1;
  transition: transform 0.3s ease, background 0.2s;
  flex-shrink: 0;
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
  background: #FF4D00;
  color: #ffffff;
}

.faq-item summary:hover::after {
  background: #FF4D00;
  color: #ffffff;
}

.faq-item[open] summary {
  color: #FF4D00;
}

.faq-answer {
  padding-bottom: 1.25rem;
}

.faq-answer p {
  font-size: 0.95rem;
  line-height: 1.75;
  color: #444;
  margin: 0;
}

/* ── Responsive: glossary + FAQ ── */
@media (max-width: 768px) {
  .glossary-hero { padding: 6rem 5% 3rem; }
  .glossary-alpha-nav { top: 60px; gap: 0.2rem; padding: 0.6rem 3%; }
  .alpha-btn { width: 1.8rem; height: 1.8rem; font-size: 0.75rem; border-radius: 4px; }
  .glossary-letter-heading { font-size: 2rem; }
  .glossary-content { padding: 2rem 1.25rem; }
  .faq-section { padding: 1.5rem 1.25rem 3rem; }
  .faq-category-nav { padding: 1.5rem 1.25rem; }
}
