/*
Theme Name: Astra Anandashivanii Child
Template: astra
Version: 1.0.0
Description: Child theme for Anandashivanii.org (coffee palette + unified UI)
*/

/* =========================================================
   Anandashivanii UI tokens + unified buttons/forms (Astra)
   File: style.css (FULL)
   ========================================================= */

/* 1) Design tokens */
:root{
  /* Brand (coffee) */
  --tapas-primary: #C8A983;
  --tapas-primary-hover: #B8936B;
  --tapas-primary-active: #A8835B;

  /* Text */
  --tapas-text: #2B2A28;
  --tapas-text-muted: #6A6761;

  /* Surfaces */
  --tapas-bg: #FFFFFF;
  --tapas-surface: #F7F3ED;
  --tapas-surface-2: #EFE8DF;

  /* Borders / radius / shadows */
  --tapas-border: rgba(43,42,40,.14);
  --tapas-radius-pill: 50px;    /* единый “премиум-pill” */
  --tapas-radius-field: 14px;

  /* Buttons */
  --tapas-btn-min-height: 48px;
  --tapas-btn-padding-y: 14px;
  --tapas-btn-padding-x: 22px;
  --tapas-btn-font-desktop: 16px;
  --tapas-btn-font-mobile: 14px;
  --tapas-btn-letter-spacing: 0.2px;

  /* Soft premium shadow (можно выключить позже) */
  --tapas-btn-shadow: 0 8px 18px rgba(31,35,40,.10);
  --tapas-btn-shadow-hover: 0 10px 22px rgba(31,35,40,.14);

  /* Forms */
  --tapas-input-bg: rgba(255,255,255,.82);
  --tapas-input-text: #2B2A28;
  --tapas-input-placeholder: rgba(43,42,40,.55);
}

/* 2) Base text (очень мягко, безопасно) */
body{
  color: var(--tapas-text);
}

/* 3) Unified buttons — Astra/WP/Elementor/Woo/CF7 */
:where(
  .button,
  button,
  input[type="button"],
  input[type="submit"],
  input[type="reset"],
  a.button,
  .ast-button,
  .wp-block-button__link,
  .elementor-button,
  .woocommerce a.button,
  .woocommerce button.button,
  .woocommerce input.button,
  .wpcf7-submit
){
  -webkit-appearance: none;
  appearance: none;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;

  min-height: var(--tapas-btn-min-height);
  padding: var(--tapas-btn-padding-y) var(--tapas-btn-padding-x);

  border-radius: var(--tapas-radius-pill);
  border: 1px solid transparent;

  background: var(--tapas-primary) !important;
  color: #FFFFFF !important;

  font-weight: 600;
  font-size: var(--tapas-btn-font-desktop);
  letter-spacing: var(--tapas-btn-letter-spacing);
  line-height: 1.1;

  text-transform: none !important;
  text-decoration: none !important;

  box-shadow: var(--tapas-btn-shadow);
  transition:
    background-color .18s ease,
    transform .12s ease,
    box-shadow .18s ease,
    opacity .18s ease;
}

/* Hover */
:where(
  .button,
  button,
  input[type="button"],
  input[type="submit"],
  input[type="reset"],
  a.button,
  .ast-button,
  .wp-block-button__link,
  .elementor-button,
  .woocommerce a.button,
  .woocommerce button.button,
  .woocommerce input.button,
  .wpcf7-submit
):hover{
  background: var(--tapas-primary-hover) !important;
  box-shadow: var(--tapas-btn-shadow-hover);
}

/* Active */
:where(
  .button,
  button,
  input[type="button"],
  input[type="submit"],
  input[type="reset"],
  a.button,
  .ast-button,
  .wp-block-button__link,
  .elementor-button,
  .woocommerce a.button,
  .woocommerce button.button,
  .woocommerce input.button,
  .wpcf7-submit
):active{
  background: var(--tapas-primary-active) !important;
  transform: translateY(1px);
  box-shadow: var(--tapas-btn-shadow);
}

/* Focus (доступность) */
:where(
  .button,
  button,
  input[type="button"],
  input[type="submit"],
  input[type="reset"],
  a.button,
  .ast-button,
  .wp-block-button__link,
  .elementor-button,
  .woocommerce a.button,
  .woocommerce button.button,
  .woocommerce input.button,
  .wpcf7-submit
):focus-visible{
  outline: 3px solid rgba(200,169,131,.35);
  outline-offset: 3px;
}

/* Mobile sizing */
@media (max-width: 767px){
  :where(
    .button,
    button,
    input[type="button"],
    input[type="submit"],
    input[type="reset"],
    a.button,
    .ast-button,
    .wp-block-button__link,
    .elementor-button,
    .woocommerce a.button,
    .woocommerce button.button,
    .woocommerce input.button,
    .wpcf7-submit
  ){
    font-size: var(--tapas-btn-font-mobile);
    padding: 12px 18px;
    min-height: 44px;
  }
}

/* 4) CF7 fields — same cozy look */
:where(.wpcf7 input[type="text"],
       .wpcf7 input[type="tel"],
       .wpcf7 input[type="email"],
       .wpcf7 input[type="url"],
       .wpcf7 input[type="password"],
       .wpcf7 textarea,
       .wpcf7 select){
  width: 100%;
  background: var(--tapas-input-bg);
  color: var(--tapas-input-text);

  border: 1px solid var(--tapas-border);
  border-radius: var(--tapas-radius-field);

  padding: 12px 14px;
  outline: none;

  transition: border-color .15s ease, box-shadow .15s ease, background-color .15s ease;
}

:where(.wpcf7 input[type="text"],
       .wpcf7 input[type="tel"],
       .wpcf7 input[type="email"],
       .wpcf7 input[type="url"],
       .wpcf7 input[type="password"],
       .wpcf7 textarea)::placeholder{
  color: var(--tapas-input-placeholder);
}

:where(.wpcf7 input[type="text"],
       .wpcf7 input[type="tel"],
       .wpcf7 input[type="email"],
       .wpcf7 input[type="url"],
       .wpcf7 input[type="password"],
       .wpcf7 textarea,
       .wpcf7 select):focus{
  border-color: rgba(200,169,131,.55);
  box-shadow: 0 0 0 4px rgba(200,169,131,.18);
  background: rgba(255,255,255,.92);
}

/* CF7 error polish */
.wpcf7-not-valid{
  border-color: rgba(187, 64, 64, .45) !important;
  box-shadow: 0 0 0 4px rgba(187, 64, 64, .12) !important;
}
.wpcf7 form .wpcf7-response-output{
  border-radius: 14px;
  padding: 12px 14px;
}

/* 5) Elementor sometimes injects inline button styles — pin them */
.elementor .elementor-button{
  background-color: var(--tapas-primary) !important;
  color: #fff !important;
}
.elementor .elementor-button:hover{
  background-color: var(--tapas-primary-hover) !important;
}
.elementor .elementor-button:active{
  background-color: var(--tapas-primary-active) !important;
}

/* ================================
   Contact Form 7 — unified style
   ================================ */

/* 1. Вертикальные отступы между полями */
.wpcf7 form p {
  margin-bottom: 12px;
}

/* Если поля внутри span */
.wpcf7 form .wpcf7-form-control-wrap {
  display: block;
  margin-bottom: 12px;
}

/* 2. Инпуты и textarea — чтобы не наезжали */
.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 textarea {
  width: 100%;
  box-sizing: border-box;
}

/* 3. Кнопка отправки — как все кнопки сайта */
.wpcf7 input[type="submit"],
.wpcf7 button[type="submit"] {
  width: 100%;
  min-height: 48px;

  border-radius: 999px;
  background-color: #C8A983;
  color: #ffffff;

  font-size: 16px;
  font-weight: 600;
  text-transform: none;

  border: none;
  cursor: pointer;

  display: flex;
  align-items: center;
  justify-content: center;

  transition: background-color .18s ease, transform .12s ease;
}

/* Hover */
.wpcf7 input[type="submit"]:hover,
.wpcf7 button[type="submit"]:hover {
  background-color: #B8936B;
}

/* Active */
.wpcf7 input[type="submit"]:active,
.wpcf7 button[type="submit"]:active {
  transform: translateY(1px);
}

/* 4. Убрать мелкие inline-стили CF7 */
.wpcf7 form .wpcf7-submit {
  margin-top: 8px;
}

/* =====================================
   CF7 spacing + responsive width tweak
   ===================================== */

/* 1) Уменьшаем расстояние между полями (было ~12px → делаем ~4px) */
.wpcf7 form p {
  margin-bottom: 4px;
}

.wpcf7 form .wpcf7-form-control-wrap {
  margin-bottom: 4px;
}

/* 2) Ограничиваем ширину формы на десктопе */
@media (min-width: 768px){
  .wpcf7 form{
    max-width: 90%;
    margin-left: auto;
    margin-right: auto;
  }
}

/* 3) На мобильных — почти на всю ширину, но с воздухом */
@media (max-width: 767px){
  .wpcf7 form{
    max-width: 90%;
    margin-left: auto;
    margin-right: auto;
  }
}

/* =====================================
   Buttons: unify typography + shadow
   Icons: force coffee color
   ===================================== */

/* 1) ЕДИНЫЕ КНОПКИ (Elementor + CF7 + WP) */
:where(
  .elementor-button,
  .wpcf7-submit,
  .wp-block-button__link,
  button,
  input[type="submit"],
  input[type="button"],
  input[type="reset"],
  a.button
){
  font-size: 16px !important;
  line-height: 1.1 !important;
  font-weight: 600 !important;
  letter-spacing: 0 !important;
  text-transform: none !important;

  border-radius: 999px !important;
  padding: 14px 22px !important;
  min-height: 48px !important;

  background: var(--tapas-primary) !important;
  border-color: transparent !important;
  color: #fff !important;

  /* лёгкая “дорогая” тень, одинаковая для всех */
  box-shadow: 0 10px 26px rgba(31,35,40,.12) !important;
  transition: background-color .18s ease, transform .12s ease, box-shadow .18s ease, opacity .18s ease !important;
}

:where(
  .elementor-button,
  .wpcf7-submit,
  .wp-block-button__link,
  button,
  input[type="submit"],
  input[type="button"],
  input[type="reset"],
  a.button
):hover{
  background: var(--tapas-primary-hover) !important;
  color: #fff !important;
  box-shadow: 0 12px 30px rgba(31,35,40,.16) !important;
}

:where(
  .elementor-button,
  .wpcf7-submit,
  .wp-block-button__link,
  button,
  input[type="submit"],
  input[type="button"],
  input[type="reset"],
  a.button
):active{
  background: var(--tapas-primary-active) !important;
  transform: translateY(1px) !important;
  box-shadow: 0 8px 18px rgba(31,35,40,.12) !important;
}

/* 2) CF7: на всякий случай фикс “маленькая кнопка слева” */
.wpcf7 form .wpcf7-submit{
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
}

/* 3) ИКОНКИ: делаем кофейными (включая SVG) */
:where(.elementor-icon, .elementor-icon i, .elementor-icon svg){
  color: var(--tapas-primary) !important;
}

:where(.elementor-icon svg path, .elementor-icon svg circle, .elementor-icon svg rect, .elementor-icon svg polygon){
  fill: var(--tapas-primary) !important;
}

/* 4) Если это Elementor Social Icons (часто белые по умолчанию) */
.elementor-social-icon i,
.elementor-social-icon svg{
  color: var(--tapas-primary) !important;
}

.elementor-social-icon svg path{
  fill: var(--tapas-primary) !important;
}

/* =====================================
   Icons hover + CF7 text rendering fix
   ===================================== */

/* 1) ИКОНКИ — hover как у кнопок */
.elementor-icon,
.elementor-social-icon{
  transition:
    color .18s ease,
    transform .12s ease,
    opacity .18s ease;
}

.elementor-icon:hover,
.elementor-social-icon:hover{
  color: var(--tapas-primary-hover) !important;
  transform: translateY(-1px);
}

/* SVG внутри */
.elementor-icon:hover svg path,
.elementor-icon:hover svg circle,
.elementor-icon:hover svg rect,
.elementor-social-icon:hover svg path{
  fill: var(--tapas-primary-hover) !important;
}

/* 2) CF7 — делаем рендер текста идентичным обычным кнопкам */
.wpcf7 input[type="submit"],
.wpcf7 button[type="submit"]{
  font-family: inherit !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  line-height: 1.1 !important;

  /* одинаковое сглаживание текста */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  /* тот же box-shadow, что и у обычных кнопок */
  box-shadow: 0 10px 26px rgba(31,35,40,.12) !important;
}

/* Hover у CF7 */
.wpcf7 input[type="submit"]:hover,
.wpcf7 button[type="submit"]:hover{
  box-shadow: 0 12px 30px rgba(31,35,40,.16) !important;
}

/* Active */
.wpcf7 input[type="submit"]:active,
.wpcf7 button[type="submit"]:active{
  box-shadow: 0 8px 18px rgba(31,35,40,.12) !important;
}

/* ===== Force sticky/fixed Astra header ===== */

/* Основной контейнер шапки Astra */
#masthead {
  position: fixed !important;
  top: 0;
  left: 0;
  right: 0;
  z-index: 9999;
}

/* Чтобы контент не уезжал под фиксированную шапку */
body {
  padding-top: 110px; /* подгони: 80-140px, чтобы ровно совпало с высотой шапки */
}

/* Если включена админ-панель WP сверху */
body.admin-bar #masthead {
  top: 32px;
}

@media (max-width: 782px) {
  body.admin-bar #masthead {
    top: 46px;
  }
}

/* ===== Astra mobile hamburger: no background + readable colors ===== */

/* 1) Убираем фон/обводку у кнопки гамбургера */
.ast-button-wrap .menu-toggle,
.ast-button-wrap .menu-toggle:hover,
.ast-button-wrap .menu-toggle:focus {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

/* 2) Цвет "полосок" гамбургера (иконка) */
.ast-button-wrap .menu-toggle .ast-mobile-svg,
.ast-button-wrap .menu-toggle .ast-mobile-svg svg {
  fill: #3c2f2a !important; /* тёмно-кофейный */
}

/* Иногда иконка рисуется stroke'ом */
.ast-button-wrap .menu-toggle .ast-mobile-svg svg * {
  stroke: #3c2f2a !important;
}

/* 3) Off-canvas: цвет текста/ссылок, чтобы не сливались с фоном */
.ast-header-break-point .ast-mobile-popup-drawer,
.ast-header-break-point .ast-mobile-popup-inner {
  color: #3c2f2a !important;
}

.ast-header-break-point .ast-mobile-popup-drawer a,
.ast-header-break-point .ast-mobile-popup-drawer .menu-link {
  color: #3c2f2a !important;
}

.ast-header-break-point .ast-mobile-popup-drawer a:hover,
.ast-header-break-point .ast-mobile-popup-drawer .menu-link:hover {
  color: #bfa27a !important; /* твой кофейный акцент */
}

/* =====================================
   Tapas blocks (Astra): light/dark cards
   + smooth hero-to-block transition
   ===================================== */

/* Базовый light-block (как было раньше) */
.tapas-light-block{
  position: relative;
  background: var(--tapas-surface);
  color: var(--tapas-text);
  border-radius: 18px;
  border: 1px solid var(--tapas-border);

  /* мягкая “дорогая” глубина */
  box-shadow: 0 18px 44px rgba(31,35,40,.08);

  /* чтобы внутренности не прилипали к краям */
  padding: 28px;
}

/* На мобиле чуть компактнее */
@media (max-width: 767px){
  .tapas-light-block{ padding: 18px; }
}

/* Ссылки внутри блока */
.tapas-light-block a{
  color: var(--tapas-primary);
}
.tapas-light-block a:hover{
  color: var(--tapas-primary-hover);
}

/* Плавный переход сверху (градиент-вуаль), чтобы красиво “сходило” с hero */
.tapas-light-block::before{
  content: "";
  position: absolute;
  left: 0; right: 0;
  top: -64px;
  height: 64px;
  pointer-events: none;

  /* сверху прозрачный, вниз в цвет блока */
  background: linear-gradient(
    to bottom,
    rgba(247,243,237,0) 0%,
    rgba(247,243,237,.85) 55%,
    rgba(247,243,237,1) 100%
  );

  /* чтобы градиент визуально мягче */
  filter: blur(0.2px);
}

/* Если нужно “без карточки”, а просто секция светлая на всю ширину:
   добавь этот класс на секцию рядом с tapas-light-block: tapas-light-section */
.tapas-light-section{
  background: var(--tapas-surface);
}
/* =====================================
   Tapas light-block links (coffee style)
   ===================================== */

.tapas-light-block a:not(.elementor-button):not(.ast-button):not(.button){
  color: var(--tapas-primary);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;

  transition: color .18s ease, text-decoration-color .18s ease;
}

/* Hover — как у кнопок */
.tapas-light-block a:not(.elementor-button):not(.ast-button):not(.button):hover{
  color: var(--tapas-primary-hover);
  text-decoration-color: var(--tapas-primary-hover);
}
/* Tapas light-block as seamless section (no card look) */
.tapas-light-block{
  border-radius: 0 !important;
}

/* Remove Astra container side padding that causes white stripes */
.ast-container,
.site-content .ast-container{
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* Elementor sections full bleed */
.elementor-section.elementor-section-boxed > .elementor-container{
  max-width: 1200px; /* оставь свой контент-лимит */
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;  /* внутренний “воздух” для текста */
  padding-right: 20px;
}

