/*
Theme Name: БухОснова
Theme URI: https://buhosnova.ru/
Author: БухОснова
Author URI: https://buhosnova.ru/
Description: Классическая тема БухОснова для бухгалтерского сопровождения ИП и ООО.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: buhosnova
*/

html {
  scroll-behavior: smooth;
  scroll-padding-top: 6rem;
}

body {
  min-width: 320px;
}

.range-input {
  --range-progress: 0%;
  height: 6px;
  margin: 0;
  appearance: none;
  -webkit-appearance: none;
  border-radius: 9999px;
  background: linear-gradient(to right, #FFCC00 0%, #FFCC00 var(--range-progress), #FDE68A var(--range-progress), #FDE68A 100%);
  cursor: pointer;
  outline: none;
}

.range-input::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 9999px;
  background: transparent;
}

.range-input::-webkit-slider-thumb {
  width: 18px;
  height: 18px;
  margin-top: -6px;
  appearance: none;
  -webkit-appearance: none;
  border: 3px solid #FFFFFF;
  border-radius: 50%;
  background: #FFCC00;
  box-shadow: 0 0 0 1px #D4A900, 0 2px 5px rgba(30, 41, 59, 0.22);
  transition: box-shadow 150ms ease, transform 150ms ease;
}

.range-input::-moz-range-track {
  height: 6px;
  border-radius: 9999px;
  background: #FDE68A;
}

.range-input::-moz-range-progress {
  height: 6px;
  border-radius: 9999px;
  background: #FFCC00;
}

.range-input::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border: 3px solid #FFFFFF;
  border-radius: 50%;
  background: #FFCC00;
  box-shadow: 0 0 0 1px #D4A900, 0 2px 5px rgba(30, 41, 59, 0.22);
  transition: box-shadow 150ms ease, transform 150ms ease;
}

.range-input:hover::-webkit-slider-thumb,
.range-input:focus-visible::-webkit-slider-thumb {
  box-shadow: 0 0 0 4px rgba(255, 204, 0, 0.24), 0 2px 5px rgba(30, 41, 59, 0.22);
  transform: scale(1.08);
}

.range-input:hover::-moz-range-thumb,
.range-input:focus-visible::-moz-range-thumb {
  box-shadow: 0 0 0 4px rgba(255, 204, 0, 0.24), 0 2px 5px rgba(30, 41, 59, 0.22);
  transform: scale(1.08);
}

.accounting-grid {
  background-color: #FFFDF5;
  background-image: linear-gradient(rgba(251, 191, 36, 0.12) 1px, transparent 1px), linear-gradient(90deg, rgba(251, 191, 36, 0.12) 1px, transparent 1px);
  background-size: 22px 22px;
}

.audit-banner {
  background-image: radial-gradient(circle at 85% 20%, rgba(255, 204, 0, 0.16), transparent 34%), linear-gradient(135deg, #1E293B, #0F172A);
}

.report-stamp {
  transform: rotate(-5deg);
}

.faq-answer {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 250ms ease;
}

.faq-answer.is-open {
  grid-template-rows: 1fr;
}

.faq-chevron {
  transition: transform 250ms ease;
}

.faq-toggle[aria-expanded="true"] .faq-chevron {
  transform: rotate(180deg);
}

.modal-overlay {
  animation: fade-in 180ms ease-out;
}

.modal-panel {
  animation: modal-in 220ms ease-out;
}

.entry-content {
  color: #475569;
  font-size: 1rem;
  line-height: 2;
  overflow-wrap: break-word;
}

.entry-content > *:first-child {
  margin-top: 0;
}

.entry-content p {
  margin: 0 0 1.5rem;
}

.entry-content h2 {
  margin: 3.5rem 0 1rem;
  color: #020617;
  font-size: 1.875rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.25;
  scroll-margin-top: 7rem;
}

.entry-content h3 {
  margin: 2.25rem 0 1rem;
  color: #0F172A;
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1.5;
}

.entry-content h4,
.entry-content h5,
.entry-content h6 {
  margin: 2rem 0 0.75rem;
  color: #0F172A;
  font-weight: 700;
  line-height: 1.5;
}

.entry-content strong {
  color: #0F172A;
  font-weight: 700;
}

.entry-content a {
  color: #B45309;
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: #FCD34D;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  transition: color 150ms ease, text-decoration-color 150ms ease;
}

.entry-content a:hover {
  color: #DC2626;
  text-decoration-color: #FCA5A5;
}

.entry-content ul,
.entry-content ol {
  margin: 0 0 1.75rem;
  padding-left: 1.75rem;
  font-size: 0.9375rem;
  line-height: 1.875;
}

.entry-content ul {
  list-style: disc;
}

.entry-content ol {
  list-style: decimal;
}

.entry-content li {
  margin-bottom: 0.75rem;
  padding-left: 0.375rem;
}

.entry-content li::marker {
  color: #DC2626;
  font-weight: 700;
}

.entry-content li > ul,
.entry-content li > ol {
  margin-top: 0.75rem;
  margin-bottom: 0;
}

.entry-content figure {
  margin: 2rem 0;
}

.entry-content img {
  max-width: 100%;
  height: auto;
  border-radius: 1rem;
}

.entry-content figcaption,
.entry-content .wp-caption-text {
  margin-top: 0.75rem;
  color: #64748B;
  font-size: 0.75rem;
  line-height: 1.5;
  text-align: center;
}

.entry-content .wp-block-table {
  margin: 2rem 0;
  overflow-x: auto;
  border: 1px solid #E7E5E4;
  border-radius: 1rem;
  background: #FFFFFF;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
}

.entry-content table {
  width: 100%;
  margin: 2rem 0;
  overflow: hidden;
  border: 1px solid #E7E5E4;
  border-spacing: 0;
  border-collapse: separate;
  border-radius: 1rem;
  background: #FFFFFF;
  color: #475569;
  font-size: 0.875rem;
  line-height: 1.6;
  text-align: left;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
}

.entry-content .wp-block-table table {
  min-width: 650px;
  margin: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.entry-content thead {
  background: #0F172A;
  color: #FCD34D;
}

.entry-content thead th {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.entry-content th,
.entry-content td {
  padding: 1.25rem;
  border-bottom: 1px solid #E7E5E4;
  vertical-align: top;
}

.entry-content tbody th {
  background: rgba(248, 250, 252, 0.7);
  color: #0F172A;
  font-weight: 700;
}

.entry-content tbody tr:last-child > * {
  border-bottom: 0;
}

.entry-content tbody tr {
  transition: background-color 150ms ease;
}

.entry-content tbody tr:hover {
  background: rgba(255, 251, 235, 0.5);
}

.entry-content blockquote {
  position: relative;
  margin: 2.5rem 0;
  padding: 2rem;
  overflow: hidden;
  border: 1px solid #E7E5E4;
  border-left: 4px solid #FBBF24;
  border-radius: 0 1rem 1rem 0;
  background: #FFFFFF;
  color: #1E293B;
  font-size: 1.125rem;
  font-style: normal;
  font-weight: 600;
  line-height: 1.75;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
}

.entry-content blockquote p {
  margin-bottom: 1rem;
}

.entry-content blockquote p:last-child {
  margin-bottom: 0;
}

.entry-content blockquote cite,
.entry-content blockquote footer {
  display: block;
  margin-top: 1rem;
  color: #64748B;
  font-size: 0.875rem;
  font-style: normal;
  font-weight: 500;
  line-height: 1.5;
}

.entry-content hr {
  margin: 3rem 0;
  border: 0;
  border-top: 1px solid #E7E5E4;
}

.entry-content pre,
.entry-content code {
  border-radius: 0.375rem;
  background: #F1F5F9;
  color: #0F172A;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.875em;
}

.entry-content code {
  padding: 0.15rem 0.35rem;
}

.entry-content pre {
  margin: 2rem 0;
  padding: 1.5rem;
  overflow-x: auto;
  line-height: 1.7;
}

.entry-content pre code {
  padding: 0;
  background: transparent;
}

.pagination {
  margin-top: 2.5rem;
}

.pagination .nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
}

.pagination .page-numbers {
  display: inline-flex;
  min-width: 2.75rem;
  min-height: 2.75rem;
  align-items: center;
  justify-content: center;
  padding: 0.625rem 1rem;
  border: 1px solid #E7E5E4;
  border-radius: 0.75rem;
  background: #FFFFFF;
  color: #475569;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.25;
}

.pagination .page-numbers.current,
.pagination .page-numbers:hover {
  border-color: #F59E0B;
  background: #FBBF24;
  color: #0F172A;
}

.pagination .page-numbers.dots:hover {
  border-color: #E7E5E4;
  background: #FFFFFF;
  color: #475569;
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes modal-in {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 767px) {
  .entry-content h2 {
    margin-top: 2.75rem;
    font-size: 1.625rem;
  }

  .entry-content table {
    display: block;
    overflow-x: auto;
  }

  .entry-content tbody,
  .entry-content thead {
    min-width: 650px;
  }

  .entry-content blockquote {
    padding: 1.5rem;
    font-size: 1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
