/*
Theme Name: Ingeniosia
Description: Tema premium para Ingeniosia — newsletter y blog de IA en español
Version: 2.0.0
*/

/* =============================================
   IMPORTS
   ============================================= */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

/* =============================================
   VARIABLES
   ============================================= */
:root {
  --orange:        #FF4D00;
  --orange-light:  #FF7A35;
  --orange-dark:   #CC2200;
  --black:         #080808;
  --black-2:       #111111;
  --black-3:       #1A1A1A;
  --white:         #FFFFFF;
  --white-70:      rgba(255,255,255,0.7);
  --white-40:      rgba(255,255,255,0.4);
  --white-10:      rgba(255,255,255,0.08);
  --border:        rgba(255,255,255,0.1);

  --grad-hero:     linear-gradient(135deg, #FF4500 0%, #9B1A00 45%, #080808 100%);
  --grad-orange:   linear-gradient(135deg, #FF4D00, #FF7A35);
  --grad-dark:     linear-gradient(180deg, #111111 0%, #080808 100%);

  --font:          'Inter', -apple-system, sans-serif;
  --radius-sm:     8px;
  --radius-md:     16px;
  --radius-lg:     24px;
  --radius-full:   100px;

  --max-w:         1200px;
  --content-w:     740px;
  --ease:          cubic-bezier(0.4, 0, 0.2, 1);
}

/* =============================================
   RESET
   ============================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--black);
  color: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; transition: all 0.2s var(--ease); }

/* =============================================
   TIPOGRAFÍA
   ============================================= */
h1, h2, h3, h4 {
  font-family: var(--font);
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--white);
}
h1 { font-size: clamp(3rem, 8vw, 6rem); font-weight: 900; }
h2 { font-size: clamp(2rem, 4vw, 3.5rem); font-weight: 800; }
h3 { font-size: clamp(1.25rem, 2vw, 1.75rem); font-weight: 700; }
p  { color: var(--white-70); line-height: 1.75; }

/* =============================================
   LAYOUT
   ============================================= */
.wrap    { max-width: var(--max-w); margin: 0 auto; padding: 0 32px; }
.narrow  { max-width: var(--content-w); margin: 0 auto; }

/* =============================================
   HEADER
   ============================================= */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 999;
  padding: 20px 0;
  transition: background 0.3s var(--ease), backdrop-filter 0.3s;
}
.site-header.scrolled {
  background: rgba(8,8,8,0.92);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: -0.04em;
  color: var(--white);
}
.logo-mark {
  width: 38px; height: 38px;
  background: var(--grad-orange);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 900;
  color: white;
  box-shadow: 0 4px 20px rgba(255,77,0,0.4);
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
  list-style: none;
}
.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--white-70);
}
.nav-links a:hover { color: var(--white); }
.btn-cta-nav {
  background: var(--white);
  color: var(--black) !important;
  font-weight: 700 !important;
  font-size: 0.875rem !important;
  padding: 10px 22px;
  border-radius: var(--radius-full);
  transition: all 0.2s var(--ease) !important;
}
.btn-cta-nav:hover {
  background: var(--orange) !important;
  color: var(--white) !important;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(255,77,0,0.4);
}

/* =============================================
   HERO
   ============================================= */
.hero {
  min-height: 100vh;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding-bottom: 80px;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background: var(--grad-hero);
  z-index: 0;
}
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 60% 30%, rgba(255,69,0,0.35) 0%, transparent 70%),
    radial-gradient(ellipse 50% 80% at 20% 80%, rgba(0,0,0,0.8) 0%, transparent 60%);
}
.hero-noise {
  position: absolute;
  inset: 0;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  z-index: 1;
}
.hero .wrap { position: relative; z-index: 2; width: 100%; }
.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--white-10);
  border: 1px solid rgba(255,77,0,0.3);
  color: var(--orange-light);
  padding: 7px 18px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 36px;
}
.hero-tag span { width: 6px; height: 6px; background: var(--orange); border-radius: 50%; animation: pulse 2s infinite; }
@keyframes pulse { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:0.5;transform:scale(1.4)} }

.hero h1 {
  max-width: 820px;
  margin-bottom: 32px;
  text-shadow: 0 2px 40px rgba(0,0,0,0.5);
}
.hero h1 em {
  font-style: normal;
  background: var(--grad-orange);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-sub {
  font-size: 1.15rem;
  color: var(--white-70);
  max-width: 500px;
  margin-bottom: 48px;
  line-height: 1.7;
}
.hero-actions {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 80px;
}
.hero-categories {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  border-top: 1px solid var(--border);
  padding-top: 40px;
}
.hero-cat {
  padding: 20px 0;
  border-right: 1px solid var(--border);
  padding-right: 32px;
}
.hero-cat:last-child { border-right: none; padding-right: 0; padding-left: 32px; }
.hero-cat:first-child { padding-left: 0; }
.cat-num {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--orange);
  letter-spacing: 0.08em;
  margin-bottom: 8px;
}
.cat-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--white-70);
}

/* =============================================
   BOTONES
   ============================================= */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  border: none;
  transition: all 0.2s var(--ease);
  letter-spacing: -0.01em;
}
.btn-orange {
  background: var(--grad-orange);
  color: white;
  box-shadow: 0 4px 24px rgba(255,77,0,0.35);
}
.btn-orange:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(255,77,0,0.5);
  color: white;
}
.btn-ghost {
  background: var(--white-10);
  color: var(--white);
  border: 1px solid var(--border);
}
.btn-ghost:hover {
  background: var(--white);
  color: var(--black);
  border-color: var(--white);
}
.btn-white {
  background: var(--white);
  color: var(--black);
  font-weight: 800;
}
.btn-white:hover {
  background: var(--orange);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(255,77,0,0.4);
}

/* =============================================
   TRUSTED BY
   ============================================= */
.trusted {
  background: var(--black-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 28px 0;
}
.trusted-inner {
  display: flex;
  align-items: center;
  gap: 48px;
  flex-wrap: wrap;
}
.trusted-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--white-40);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}
.trusted-items {
  display: flex;
  align-items: center;
  gap: 40px;
  flex: 1;
  flex-wrap: wrap;
}
.trusted-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--white-40);
  white-space: nowrap;
  transition: color 0.2s;
}
.trusted-item:hover { color: var(--white-70); }
.trusted-item svg { opacity: 0.5; }

/* =============================================
   ABOUT / SPLIT SECTION
   ============================================= */
.split-section {
  padding: 120px 0;
  background: var(--black);
}
.split-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}
.split-label {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--orange);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 20px;
}
.split-section h2 { margin-bottom: 0; }
.split-right p {
  font-size: 1.05rem;
  margin-bottom: 32px;
  color: var(--white-70);
}

/* =============================================
   FEATURES / HOW IT WORKS
   ============================================= */
.features-section {
  padding: 120px 0;
  background: var(--black-2);
}
.section-header {
  text-align: center;
  margin-bottom: 72px;
}
.section-tag {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--orange);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 20px;
}
.section-header h2 { margin-bottom: 16px; }
.section-header p { font-size: 1.05rem; max-width: 500px; margin: 0 auto; }

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.feat-card {
  background: var(--black-2);
  padding: 48px 40px;
  transition: background 0.2s;
}
.feat-card:hover { background: var(--black-3); }
.feat-num {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--orange);
  letter-spacing: 0.1em;
  margin-bottom: 28px;
}
.feat-icon {
  font-size: 2.5rem;
  margin-bottom: 24px;
  display: block;
}
.feat-card h3 { font-size: 1.2rem; margin-bottom: 14px; color: var(--white); }
.feat-card p  { font-size: 0.9rem; color: var(--white-70); line-height: 1.7; margin: 0; }

/* =============================================
   POSTS GRID
   ============================================= */
.posts-section {
  padding: 120px 0;
  background: var(--black);
}
.posts-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 56px;
  gap: 32px;
}
.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.post-card {
  background: var(--black-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform 0.25s var(--ease), border-color 0.25s;
}
.post-card:hover {
  transform: translateY(-6px);
  border-color: rgba(255,77,0,0.3);
}
.post-thumb {
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--black-3);
}
.post-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.4s var(--ease);
}
.post-card:hover .post-thumb img { transform: scale(1.06); }
.post-body { padding: 28px; }
.post-cat {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--orange);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.post-body h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--white);
  line-height: 1.4;
}
.post-body h3 a { color: inherit; }
.post-body h3 a:hover { color: var(--orange-light); }
.post-excerpt {
  font-size: 0.875rem;
  color: var(--white-40);
  line-height: 1.6;
  margin-bottom: 20px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.post-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border);
  padding-top: 18px;
}
.post-time { font-size: 0.78rem; color: var(--white-40); font-weight: 500; }
.post-arrow {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--orange);
  display: flex;
  align-items: center;
  gap: 6px;
}
.post-card:hover .post-arrow { gap: 10px; }

/* =============================================
   CTA SECTION
   ============================================= */
.cta-section {
  padding: 140px 0;
  background: var(--black-2);
  border-top: 1px solid var(--border);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-section::before {
  content: '';
  position: absolute;
  top: -200px; left: 50%;
  transform: translateX(-50%);
  width: 800px; height: 600px;
  background: radial-gradient(ellipse, rgba(255,69,0,0.12) 0%, transparent 70%);
  pointer-events: none;
}
.cta-section .wrap { position: relative; z-index: 1; }
.cta-eyebrow {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--orange);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 24px;
}
.cta-section h2 { max-width: 700px; margin: 0 auto 20px; }
.cta-section p  { font-size: 1.1rem; max-width: 460px; margin: 0 auto 48px; }

/* =============================================
   SINGLE POST
   ============================================= */
.post-hero {
  padding: 140px 0 80px;
  background: var(--black-2);
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
.post-hero::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: radial-gradient(ellipse 60% 80% at 80% 20%, rgba(255,69,0,0.08) 0%, transparent 70%);
}
.post-hero .wrap { position: relative; z-index: 1; }
.post-hero-cat {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--orange);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 24px;
}
.post-hero h1 { max-width: 800px; margin-bottom: 28px; }
.post-meta-bar {
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 0.85rem;
  color: var(--white-40);
  font-weight: 500;
}
.post-meta-bar span::before {
  content: '·';
  margin-right: 24px;
}
.post-meta-bar span:first-child::before { content: ''; margin: 0; }

.post-content-area {
  padding: 80px 0 120px;
  background: var(--black);
}
.post-content-area .narrow { padding: 0 24px; }
.post-content-area h2 { font-size: 1.9rem; margin: 56px 0 20px; padding-top: 40px; border-top: 1px solid var(--border); }
.post-content-area h3 { font-size: 1.4rem; margin: 40px 0 16px; color: var(--white); }
.post-content-area p  { margin-bottom: 24px; font-size: 1.05rem; }
.post-content-area ul,
.post-content-area ol { padding-left: 28px; margin-bottom: 24px; }
.post-content-area li { color: var(--white-70); margin-bottom: 10px; font-size: 1.05rem; }
.post-content-area strong { color: var(--white); }
.post-content-area a { color: var(--orange-light); border-bottom: 1px solid rgba(255,122,53,0.3); }
.post-content-area a:hover { color: var(--orange); border-color: var(--orange); }
.post-content-area blockquote {
  border-left: 3px solid var(--orange);
  padding: 20px 28px;
  background: var(--black-2);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  margin: 40px 0;
}
.post-content-area blockquote p { color: var(--white-70); font-style: italic; margin: 0; }
.post-content-area table {
  width: 100%; border-collapse: collapse; margin: 40px 0;
  font-size: 0.9rem;
}
.post-content-area th {
  background: var(--black-3); padding: 14px 18px;
  text-align: left; font-weight: 700; color: var(--white);
  border-bottom: 1px solid var(--border);
}
.post-content-area td {
  padding: 12px 18px;
  border-bottom: 1px solid var(--border);
  color: var(--white-70);
}
.post-content-area tr:hover td { background: var(--black-2); }

.inline-cta {
  background: linear-gradient(135deg, var(--black-3), var(--black-2));
  border: 1px solid rgba(255,77,0,0.25);
  border-radius: var(--radius-lg);
  padding: 48px;
  margin: 60px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.inline-cta::before {
  content: '';
  position: absolute;
  top: -60px; left: 50%;
  transform: translateX(-50%);
  width: 300px; height: 200px;
  background: radial-gradient(ellipse, rgba(255,69,0,0.1) 0%, transparent 70%);
}
.inline-cta p:first-child { color: var(--white); font-size: 1.25rem; font-weight: 700; margin-bottom: 10px; }
.inline-cta p:nth-child(2) { color: var(--white-70); font-size: 0.95rem; margin-bottom: 28px; }

/* =============================================
   FOOTER
   ============================================= */
.site-footer {
  background: var(--black);
  border-top: 1px solid var(--border);
  padding: 80px 0 40px;
}
.footer-top {
  display: grid;
  grid-template-columns: 1.8fr 1fr 1fr;
  gap: 64px;
  padding-bottom: 64px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 40px;
}
.footer-logo { margin-bottom: 20px; }
.footer-desc { font-size: 0.9rem; color: var(--white-40); max-width: 280px; line-height: 1.7; margin-bottom: 32px; }
.footer-col h5 {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--white-40);
  margin-bottom: 20px;
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 12px; }
.footer-col a { font-size: 0.9rem; color: var(--white-70); font-weight: 500; }
.footer-col a:hover { color: var(--white); }
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--white-40);
}
.footer-bottom a { color: var(--white-40); }
.footer-bottom a:hover { color: var(--orange); }

/* =============================================
   SCROLL ANIMATION
   ============================================= */
.fade-up {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.fade-up.visible { opacity: 1; transform: translateY(0); }

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 1024px) {
  h1 { font-size: clamp(2.4rem, 6vw, 4rem); }
  .hero-categories { grid-template-columns: repeat(2, 1fr); }
  .split-inner { grid-template-columns: 1fr; gap: 48px; }
  .features-grid { grid-template-columns: 1fr; }
  .posts-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-top { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .nav-links { display: none; }
  .wrap { padding: 0 20px; }
  .hero { padding-bottom: 60px; }
  .hero-categories { grid-template-columns: repeat(2, 1fr); gap: 0; }
  .posts-grid { grid-template-columns: 1fr; }
  .features-section, .posts-section, .split-section, .cta-section { padding: 80px 0; }
  .posts-header { flex-direction: column; align-items: flex-start; }
  .footer-top { grid-template-columns: 1fr; gap: 40px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
  .inline-cta { padding: 32px 24px; }
}
