/*!
 * MiningHelp — штатная разметка WordPress и WooCommerce, которой нет в макетах: страницы кабинета
 * и оплаты заказа (page.php → .mh-orderflow), уведомления WooCommerce, стили блоков редактора, служебное.
 */

/* Страницы без своего макета: кабинет WooCommerce, страницы Elementor */
.mh-layout { padding-top: 24px; padding-bottom: var(--mh-section-y); }
.mh-layout__h { margin-bottom: clamp(20px, 2.4vw, 28px); }

/* Стили блоков редактора (inc/setup.php: register_block_style) — в тексте любых страниц и записей */
.is-style-mh-ticklist, .mh-ticklist { list-style: none; padding-left: 0; gap: 0; border-top: 1px solid var(--mh-line); }
.is-style-mh-ticklist li, .mh-ticklist li { position: relative; padding: 14px 0 14px 38px; border-bottom: 1px solid var(--mh-line); }
.is-style-mh-ticklist li::before, .mh-ticklist li::before { content: ""; position: absolute; left: 0; top: 16px; width: 24px; height: 24px; border-radius: 6px; background: var(--mh-accent-tint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23b5650a' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") no-repeat center; }
.is-style-mh-hours table, .mh-hours table { border: 1px solid var(--mh-line); border-radius: var(--mh-r-sm); border-collapse: separate; border-spacing: 0; overflow: hidden; }
.is-style-mh-hours td, .mh-hours td { padding: 14px 18px; border: 0; border-bottom: 1px solid var(--mh-line); }
.is-style-mh-hours tr:last-child td, .mh-hours tr:last-child td { border-bottom: 0; }
.is-style-mh-hours td:first-child, .mh-hours td:first-child { font-weight: 700; color: var(--mh-ink); }
.is-style-mh-hours td:last-child, .mh-hours td:last-child { text-align: right; font-family: var(--mh-font-mono); font-size: var(--mh-fs-14); color: #4A5560; white-space: nowrap; }
.is-style-mh-hint, .mh-hint { padding: 24px; border-radius: var(--mh-r-sm); border: 1px dashed var(--mh-line-strong); background: #F4F5F6; font-family: var(--mh-font-mono); font-size: var(--mh-fs-13); letter-spacing: .04em; color: var(--mh-text-3); line-height: 1.6; }


/* =====================================================================
   Оформление и аккаунт (разметка WooCommerce)
   ===================================================================== */
.mh-orderflow { font-size: var(--mh-fs-15); line-height: 1.55; }
.mh-orderflow h2, .mh-orderflow h3 { font-weight: 700; font-size: var(--mh-fs-20); letter-spacing: -0.015em; margin: 0 0 14px; }
.mh-orderflow table.shop_table { width: 100%; border-collapse: separate; border-spacing: 0; background: #fff; border: 1px solid var(--mh-line); border-radius: var(--mh-r-xs); overflow: hidden; margin-bottom: 24px; }
.mh-orderflow table.shop_table th, .mh-orderflow table.shop_table td { padding: 14px 16px; border-bottom: 1px solid #E9EBED; text-align: left; vertical-align: middle; }
.mh-orderflow table.shop_table thead th { background: var(--mh-ink); color: var(--mh-accent); font-family: var(--mh-font-mono); font-size: var(--mh-fs-12); font-weight: 500; letter-spacing: .06em; text-transform: uppercase; }
.mh-orderflow table.shop_table tr:last-child > * { border-bottom: 0; }
.mh-orderflow .product-thumbnail img { width: 64px; height: 64px; object-fit: contain; border-radius: var(--mh-r-xs); background: var(--mh-surface); }
.mh-orderflow .product-name a { font-weight: 600; color: var(--mh-ink); }
.mh-orderflow .product-remove a { display: inline-flex; width: 28px; height: 28px; border-radius: 6px; align-items: center; justify-content: center; background: var(--mh-surface); color: var(--mh-text-2) !important; font-size: var(--mh-fs-17); line-height: 1; }
.mh-orderflow .product-remove a:hover { background: #fdf2f1; color: #b3261e !important; }
.mh-orderflow .quantity input, .mh-orderflow input.input-text, .mh-orderflow select, .mh-orderflow textarea { height: var(--mh-btn-h); width: 100%; padding: 0 14px; border-radius: var(--mh-r-sm); border: 1px solid var(--mh-line-strong); background: var(--mh-surface); font: inherit; font-size: var(--mh-fs-15); color: var(--mh-ink); }
.mh-orderflow textarea { height: auto; min-height: 110px; padding: 12px 14px; }
.mh-orderflow .quantity input { width: 80px; text-align: center; }
.mh-orderflow input:focus, .mh-orderflow select:focus, .mh-orderflow textarea:focus { outline: 2px solid var(--mh-accent); outline-offset: 0; border-color: transparent; }
.mh-orderflow .button, .mh-orderflow button[type="submit"], .mh-orderflow .checkout-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: var(--mh-btn-h); padding: 0 20px; border-radius: var(--mh-r-sm); border: 1px solid var(--mh-line); background: #fff; color: var(--mh-ink) !important; font: inherit; font-weight: 600; font-size: var(--mh-fs-15); cursor: pointer; }
.mh-orderflow .button:hover { border-color: var(--mh-accent); }
.mh-orderflow .button.alt, .mh-orderflow .checkout-button, .mh-orderflow #place_order { background: var(--mh-accent); border-color: var(--mh-accent); color: #fff !important; font-weight: 700; }
.mh-orderflow .button.alt:hover, .mh-orderflow .checkout-button:hover, .mh-orderflow #place_order:hover { background: var(--mh-accent-hover); border-color: var(--mh-accent-hover); }
.mh-orderflow .button:disabled, .mh-orderflow .button[disabled] { opacity: .5; cursor: default; }
.mh-orderflow .actions .coupon { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.mh-orderflow .actions .coupon input { width: auto; flex: 1 1 200px; }
.mh-orderflow .wc-proceed-to-checkout .checkout-button { width: 100%; height: var(--mh-btn-h); font-size: var(--mh-fs-16); }
.mh-orderflow .form-row { display: flex; flex-direction: column; gap: 6px; margin: 0 0 14px; }
.mh-orderflow .form-row label { font-size: var(--mh-fs-14); font-weight: 600; color: var(--mh-text-2); }
.mh-orderflow .form-row .required { color: var(--mh-accent-ink); text-decoration: none; }
.mh-orderflow .col2-set { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 24px; margin-bottom: 24px; }
.mh-orderflow #order_review_heading { margin-top: 8px; }
.mh-orderflow .woocommerce-checkout-review-order, .mh-orderflow .woocommerce-checkout-payment { margin-bottom: 20px; }
.mh-orderflow #payment { background: #fff; border: 1px solid var(--mh-line); border-radius: var(--mh-r-xs); padding: 18px; }
.mh-orderflow #payment ul.payment_methods { list-style: none; display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
.mh-orderflow .payment_box { margin-top: 8px; padding: 12px 14px; border-radius: var(--mh-r-sm); background: var(--mh-surface); font-size: var(--mh-fs-14); color: var(--mh-text-2); }
.mh-orderflow .woocommerce-MyAccount-navigation ul { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.mh-orderflow .woocommerce-MyAccount-navigation a { display: inline-flex; height: var(--mh-ctl-h); padding: 0 14px; align-items: center; border-radius: var(--mh-r-sm); border: 1px solid var(--mh-line); font-weight: 600; font-size: var(--mh-fs-14); color: var(--mh-ink); }
.mh-orderflow .woocommerce-MyAccount-navigation .is-active a { background: var(--mh-ink); border-color: var(--mh-ink); color: #fff; }
.mh-orderflow .wc-block-components-button:not(.is-link) { border-radius: var(--mh-r-sm); background: var(--mh-accent); color: #fff; }

/* Уведомления WooCommerce */
.woocommerce-notices-wrapper:empty { display: none; }
.mininghelp .woocommerce-message, .mininghelp .woocommerce-info, .mininghelp .woocommerce-error { list-style: none; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; margin: 0 0 20px; padding: 14px 18px; border-radius: var(--mh-r-sm); background: var(--mh-accent-tint); color: var(--mh-accent-ink); font-size: var(--mh-fs-15); line-height: 1.5; }
.mininghelp .woocommerce-error { background: #fdf2f1; color: #b3261e; flex-direction: column; align-items: flex-start; }
.mininghelp .woocommerce-message .button, .mininghelp .woocommerce-info .button { order: 2; display: inline-flex; align-items: center; height: var(--mh-ctl-h); padding: 0 16px; border-radius: var(--mh-r-xs); background: var(--mh-ink); color: #fff; font-weight: 600; font-size: var(--mh-fs-14); }
.mininghelp .woocommerce-message .button:hover { background: var(--mh-line-dark); color: #fff; }
.mh-pdp .woocommerce-notices-wrapper { margin-bottom: 4px; }

/* Классическая корзина на телефоне: строки таблицы — карточками */
@media (max-width: 759.98px) {
  .mh-orderflow table.shop_table_responsive thead { display: none; }
  .mh-orderflow table.shop_table_responsive, .mh-orderflow table.shop_table_responsive tbody, .mh-orderflow table.shop_table_responsive tr { display: block; width: 100%; }
  .mh-orderflow table.shop_table_responsive tr { border-bottom: 1px solid #E9EBED; }
  .mh-orderflow table.shop_table_responsive td { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 8px 14px; border: 0; text-align: right; }
  .mh-orderflow table.shop_table_responsive td::before { content: attr(data-title); font-weight: 600; color: var(--mh-text-2); text-align: left; }
  .mh-orderflow table.shop_table_responsive td.product-remove::before, .mh-orderflow table.shop_table_responsive td.product-thumbnail::before, .mh-orderflow table.shop_table_responsive td.actions::before { content: none; }
  .mh-orderflow table.shop_table_responsive td.actions { display: block; text-align: left; }
  .mh-orderflow table.shop_table_responsive tbody th { display: none; }
  .mh-orderflow .actions .coupon { flex-direction: column; }
  .mh-orderflow .actions .coupon input { flex: none; width: 100%; height: var(--mh-input-h); }
  .mh-orderflow .actions .button { width: 100%; }
}


/* =====================================================================
   Служебное
   ===================================================================== */
.mininghelp .is-busy { opacity: .7; cursor: progress; }
.mininghelp .screen-reader-text { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.mininghelp .wp-caption { max-width: 100%; }
.mininghelp .wp-caption-text, .mininghelp .gallery-caption { font-size: var(--mh-fs-14); color: var(--mh-text-3); }
.mininghelp .bypostauthor { display: block; }
.mininghelp .sticky { display: block; }
.mininghelp .mh-price-request { font-weight: 700; }
html { scroll-padding-top: var(--mh-top-offset); }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .mininghelp *, .mininghelp *::before, .mininghelp *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
@media print {
  .mh-header, .mh-footer, .mh-cookie, .mh-drawer, .mh-modal, .mh-digest-col, .mh-doc__nav, .mh-facets { display: none !important; }
  .mininghelp { background: #fff; }
  .mh-doc__body a, .mh-copy a, .mh-prose a { text-decoration: underline; }
}

