/*
Theme Name: Contabilidad RD Portal
Theme URI: http://localhost/Portal/
Author: Codex
Description: Tema personalizado para portal de servicios contables en Republica Dominicana.
Version: 1.0.1
Text Domain: contabilidad-rd
*/

:root {
  --ink: #18202b;
  --muted: #667085;
  --line: #d7dde7;
  --paper: #ffffff;
  --soft: #f4f7fb;
  --brand: #0a6f6f;
  --brand-strong: #064f56;
  --accent: #d4a017;
  --accent-soft: #fff4cf;
  --danger: #bb3e30;
  --radius: 8px;
  --shadow: 0 18px 50px rgba(24, 32, 43, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

body.admin-bar {
  min-height: calc(100vh - 32px);
}

main {
  flex: 1;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(215, 221, 231, 0.85);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(18px);
}

.container {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: var(--radius);
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-strong));
  font-weight: 900;
}

.menu {
  display: flex;
  align-items: center;
  gap: 24px;
  color: #344054;
  font-size: 0.95rem;
}

.menu ul,
.menu-list {
  display: flex;
  align-items: center;
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.menu li {
  margin: 0;
  padding: 0;
  list-style: none;
}

.menu li::marker {
  content: "";
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-weight: 750;
  line-height: 1;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button.primary {
  color: #fff;
  background: var(--brand);
  box-shadow: 0 12px 24px rgba(10, 111, 111, 0.2);
}

.button.secondary {
  color: var(--brand-strong);
  border-color: rgba(10, 111, 111, 0.25);
  background: #fff;
}

.hero {
  position: relative;
  min-height: 660px;
  overflow: hidden;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(9, 36, 45, 0.9), rgba(9, 36, 45, 0.7) 42%, rgba(9, 36, 45, 0.15)),
    url("assets/hero-contabilidad.svg") center right / cover no-repeat,
    #0d3640;
}

.hero-inner {
  display: grid;
  min-height: 660px;
  align-items: center;
  padding: 72px 0 92px;
}

.hero-copy {
  width: min(680px, 100%);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  color: var(--accent-soft);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
}

.hero h1 {
  margin: 0;
  font-size: clamp(2.45rem, 7vw, 4.85rem);
  line-height: 1.02;
  letter-spacing: 0;
}

.hero p {
  width: min(610px, 100%);
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 1.15rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.hero-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  width: min(660px, 100%);
  margin-top: 44px;
}

.metric {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius);
  padding: 16px;
  background: rgba(255, 255, 255, 0.1);
}

.metric strong {
  display: block;
  font-size: 1.4rem;
}

.metric span {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.88rem;
}

.section {
  padding: 86px 0;
}

.section.soft {
  background: var(--soft);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 34px;
}

.section-head h2 {
  width: min(650px, 100%);
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.1rem);
  line-height: 1.08;
  letter-spacing: 0;
}

.section-head p {
  width: min(390px, 100%);
  margin: 0;
  color: var(--muted);
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.service-card,
.benefit,
.contact-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.service-card {
  padding: 24px;
  min-height: 260px;
}

.service-card .icon,
.benefit .icon {
  display: grid;
  width: 44px;
  height: 44px;
  margin-bottom: 18px;
  place-items: center;
  border-radius: var(--radius);
  color: var(--brand-strong);
  background: #e6f3f2;
  font-weight: 900;
}

.service-card h3,
.benefit h3 {
  margin: 0 0 10px;
  font-size: 1.18rem;
  line-height: 1.25;
}

.service-card p,
.benefit p {
  margin: 0;
  color: var(--muted);
}

.split {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 44px;
  align-items: center;
}

.quote-box {
  padding: 34px;
  border-left: 5px solid var(--accent);
  background: var(--accent-soft);
}

.quote-box h2 {
  margin: 0 0 16px;
  font-size: clamp(1.8rem, 4vw, 2.7rem);
  line-height: 1.12;
}

.quote-box p {
  margin: 0;
  color: #5b4a12;
}

.benefits {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.benefit {
  padding: 22px;
}

.process {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  counter-reset: steps;
}

.resources {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.clients {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 28px;
  align-items: start;
}

.client-summary {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  background: #fff;
  box-shadow: var(--shadow);
}

.client-summary strong {
  display: block;
  margin-bottom: 10px;
  color: var(--brand);
  font-size: 2.3rem;
  line-height: 1;
}

.client-summary p {
  margin: 0;
  color: var(--muted);
}

.client-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.client-card,
.blog-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  background: #fff;
}

.client-card h3,
.blog-card h3 {
  margin: 0 0 10px;
  font-size: 1.12rem;
  line-height: 1.25;
}

.client-card p,
.blog-card p {
  margin: 0;
  color: var(--muted);
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.blog-card {
  display: flex;
  min-height: 255px;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}

.blog-thumb {
  display: block;
  margin: -22px -22px 20px;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

.blog-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-meta {
  display: block;
  margin-bottom: 14px;
  color: var(--danger);
  font-size: 0.82rem;
  font-weight: 850;
  text-transform: uppercase;
}

.blog-card a {
  margin-top: 22px;
  color: var(--brand);
  font-weight: 800;
}

.post-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 42px;
  align-items: start;
}

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

.post-header {
  margin-bottom: 28px;
}

.post-header h1 {
  margin: 0 0 16px;
  font-size: clamp(2rem, 5vw, 3.5rem);
  line-height: 1.08;
}

.post-header p {
  width: min(760px, 100%);
  margin: 0;
  color: var(--muted);
  font-size: 1.1rem;
}

.post-hero-image {
  margin: 0 0 34px;
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--soft);
}

.post-hero-image img {
  width: 100%;
  height: auto;
}

.post-content {
  color: #263241;
  font-size: 1.04rem;
}

.post-content h2 {
  margin: 34px 0 12px;
  font-size: 1.55rem;
  line-height: 1.2;
}

.post-content p,
.post-content ul,
.post-content ol {
  margin: 0 0 18px;
}

.post-content ul,
.post-content ol {
  padding-left: 22px;
}

.post-sidebar {
  position: sticky;
  top: 104px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  background: #fff;
}

.post-sidebar h2 {
  margin: 0 0 16px;
  font-size: 1.2rem;
  line-height: 1.2;
}

.recent-posts {
  display: grid;
  gap: 14px;
}

.recent-post {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  padding-bottom: 14px;
}

.recent-post:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.recent-post img {
  width: 64px;
  height: 64px;
  border-radius: var(--radius);
  object-fit: cover;
  background: var(--soft);
}

.recent-post small {
  display: block;
  margin-bottom: 4px;
  color: var(--danger);
  font-size: 0.72rem;
  font-weight: 850;
  text-transform: uppercase;
}

.recent-post strong {
  display: block;
  font-size: 0.94rem;
  line-height: 1.25;
}

.resource-card {
  display: flex;
  min-height: 250px;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  background: #fff;
}

.resource-card .tag {
  width: fit-content;
  margin-bottom: 18px;
  border-radius: 999px;
  padding: 5px 10px;
  color: var(--brand-strong);
  background: #e6f3f2;
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: uppercase;
}

.resource-card h3 {
  margin: 0 0 10px;
  font-size: 1.18rem;
  line-height: 1.25;
}

.resource-card p {
  margin: 0;
  color: var(--muted);
}

.resource-card a {
  margin-top: 22px;
  color: var(--brand);
  font-weight: 800;
}

.step {
  position: relative;
  min-height: 176px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  counter-increment: steps;
}

.step::before {
  content: counter(steps, decimal-leading-zero);
  display: block;
  margin-bottom: 22px;
  color: var(--brand);
  font-size: 0.85rem;
  font-weight: 900;
}

.step h3 {
  margin: 0 0 8px;
  font-size: 1.04rem;
}

.step p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
}

.contact-wrap {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 22px;
}

.contact-panel {
  padding: 28px;
}

.contact-panel h2 {
  margin: 0 0 12px;
  font-size: 2rem;
  line-height: 1.12;
}

.contact-panel p {
  margin: 0 0 20px;
  color: var(--muted);
}

.contact-list {
  display: grid;
  gap: 12px;
  margin-top: 24px;
}

.contact-list a,
.contact-list span {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #344054;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.field {
  display: grid;
  gap: 7px;
}

.field.full {
  grid-column: 1 / -1;
}

label {
  font-size: 0.88rem;
  font-weight: 750;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 13px;
  color: var(--ink);
  background: #fff;
  font: inherit;
}

textarea {
  min-height: 118px;
  resize: vertical;
}

.site-footer {
  padding: 42px 0 28px;
  color: rgba(255, 255, 255, 0.76);
  background: #12232c;
}

.footer-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 34px;
  align-items: start;
  padding-bottom: 28px;
}

.footer-brand {
  color: #fff;
}

.footer-main p {
  width: min(520px, 100%);
  margin: 18px 0 0;
}

.footer-menu {
  display: grid;
  grid-template-columns: repeat(2, minmax(120px, 1fr));
  gap: 10px 22px;
}

.footer-menu ul {
  display: contents;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-menu li {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-menu li::marker {
  content: "";
}

.footer-menu a {
  color: rgba(255, 255, 255, 0.86);
  font-weight: 700;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 24px;
}

.page-container {
  width: min(980px, calc(100% - 40px));
}

.page-header {
  margin-bottom: 32px;
}

.page-eyebrow {
  color: var(--brand);
}

.page-header h1 {
  margin: 0;
  font-size: clamp(2.25rem, 5vw, 4rem);
  line-height: 1.06;
}

.page-header p:not(.eyebrow) {
  width: min(720px, 100%);
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 1.1rem;
}

.page-content {
  color: #263241;
  font-size: 1.04rem;
}

.page-content h2 {
  margin: 34px 0 14px;
  font-size: 1.7rem;
  line-height: 1.18;
}

.page-content p,
.page-content ul,
.page-content ol {
  margin: 0 0 18px;
}

.page-content ul,
.page-content ol {
  padding-left: 22px;
}

.page-content .grid,
.page-content .benefits,
.page-content .process,
.page-content .resources,
.page-content .client-list {
  margin-top: 22px;
}

.blog-archive-grid {
  margin-top: 28px;
}

.pagination {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.pagination a,
.pagination span {
  display: inline-flex;
  min-width: 38px;
  min-height: 38px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 12px;
  background: #fff;
  font-weight: 800;
}

.pagination .current {
  color: #fff;
  border-color: var(--brand);
  background: var(--brand);
}

@media (max-width: 900px) {
  .menu {
    display: none;
  }

  .hero,
  .hero-inner {
    min-height: 620px;
  }

  .hero-metrics,
  .grid,
  .resources,
  .clients,
  .blog-grid,
  .post-layout,
  .process,
  .split,
  .contact-wrap {
    grid-template-columns: 1fr;
  }

  .post-sidebar {
    position: static;
  }

  .section-head {
    display: block;
  }

  .section-head p {
    margin-top: 12px;
  }

  .benefits,
  .client-list,
  .form-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .container {
    width: min(100% - 28px, 1160px);
  }

  .nav {
    min-height: 68px;
  }

  .brand span:last-child {
    max-width: 170px;
    line-height: 1.1;
  }

  .hero {
    background:
      linear-gradient(180deg, rgba(9, 36, 45, 0.92), rgba(9, 36, 45, 0.78)),
      url("assets/hero-contabilidad.svg") center / cover no-repeat,
      #0d3640;
  }

  .hero-actions .button {
    width: 100%;
  }

  .section {
    padding: 62px 0;
  }

  .footer-inner {
    display: grid;
  }

  .footer-main {
    grid-template-columns: 1fr;
  }

  .footer-menu {
    grid-template-columns: 1fr;
  }
}
