/*
Theme Name: HeartCare One
Theme URI: https://drfaezebanazade.ir
Author: HeartCare Studio
Description: قالب اختصاصی، راست‌چین و قابل شخصی‌سازی برای وب‌سایت پزشکان و کلینیک‌های قلب.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Requires at least: 6.4
Tested up to: 7.0
Requires PHP: 8.1
Text Domain: heartcare-one
Tags: rtl-language-support, custom-logo, custom-colors, featured-images, accessibility-ready, blog
*/

:root {
  --hc-primary: #0d4f8b;
  --hc-secondary: #d73545;
  --hc-accent: #24a6a1;
  --hc-dark: #10243a;
  --hc-text: #405269;
  --hc-bg: #f5f8fc;
  --hc-card: #ffffff;
  --hc-border: #dce6f0;
  --hc-muted: #6f8195;
  --hc-shadow: 0 18px 50px rgba(16, 36, 58, .09);
  --hc-container: 1180px;
  --hc-radius: 24px;
  --hc-button-radius: 14px;
  --hc-section-space: 88px;
  --hc-card-padding: 28px;
  --hc-font-size: 16px;
  --hc-font: "Vazirmatn", "IRANSansX", Tahoma, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  direction: rtl;
  color: var(--hc-text);
  background: var(--hc-bg);
  font: 400 var(--hc-font-size)/1.9 var(--hc-font);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
body.admin-bar .hc-header.is-sticky { top: 32px; }
img { max-width: 100%; height: auto; }
a { color: var(--hc-primary); text-decoration: none; transition: .2s ease; }
a:hover { color: var(--hc-secondary); }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
h1, h2, h3, h4, h5, h6 {
  margin: 0 0 .65em;
  color: var(--hc-dark);
  line-height: 1.35;
  font-weight: 800;
}
p { margin: 0 0 1.2em; }
ul, ol { padding-inline-start: 1.4rem; }
.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;
}
.screen-reader-text:focus {
  z-index: 100000; top: 8px; right: 8px; width: auto; height: auto;
  padding: 12px 18px; clip: auto; background: #fff; color: #111;
}
.hc-container { width: min(calc(100% - 40px), var(--hc-container)); margin-inline: auto; }
.hc-section { padding-block: var(--hc-section-space); }
.hc-section--white { background: #fff; }
.hc-section--tint { background: linear-gradient(135deg, #eef7fb, #f7f9fd); }
.hc-grid { display: grid; gap: 24px; }
.hc-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.hc-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.hc-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.hc-eyebrow {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 14px;
  color: var(--hc-primary); font-size: .88rem; font-weight: 800;
  letter-spacing: -.01em;
}
.hc-eyebrow::before { content: ""; width: 22px; height: 3px; border-radius: 8px; background: var(--hc-secondary); }
.hc-section-heading { max-width: 720px; margin: 0 auto 42px; text-align: center; }
.hc-section-heading h2 { font-size: clamp(1.8rem, 3vw, 2.65rem); }
.hc-section-heading p { color: var(--hc-muted); font-size: 1.05rem; }
.hc-card {
  position: relative; padding: var(--hc-card-padding); border: 1px solid var(--hc-border);
  border-radius: var(--hc-radius); background: var(--hc-card); box-shadow: 0 10px 34px rgba(16,36,58,.055);
}
.hc-card--lift { transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease; }
.hc-card--lift:hover { transform: translateY(-6px); border-color: rgba(13,79,139,.25); box-shadow: var(--hc-shadow); }
.hc-icon-box {
  display: inline-grid; place-items: center; width: 58px; height: 58px; margin-bottom: 18px;
  color: #fff; border-radius: 18px; background: linear-gradient(135deg, var(--hc-primary), #187bc4);
  box-shadow: 0 12px 28px rgba(13,79,139,.22);
}
.hc-icon-box svg { width: 28px; height: 28px; }
.hc-button {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  min-height: 50px; padding: 11px 23px; border: 1px solid transparent;
  border-radius: var(--hc-button-radius); font-weight: 800; line-height: 1.4;
}
.hc-button--primary { color: #fff; background: linear-gradient(135deg, var(--hc-primary), #176fad); box-shadow: 0 12px 28px rgba(13,79,139,.2); }
.hc-button--primary:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 16px 32px rgba(13,79,139,.27); }
.hc-button--secondary { color: #fff; background: linear-gradient(135deg, var(--hc-secondary), #ef5967); box-shadow: 0 12px 28px rgba(215,53,69,.18); }
.hc-button--secondary:hover { color: #fff; transform: translateY(-2px); }
.hc-button--outline { color: var(--hc-primary); border-color: rgba(13,79,139,.25); background: #fff; }
.hc-button--outline:hover { color: #fff; background: var(--hc-primary); }
.hc-button svg { width: 20px; height: 20px; }

/* Header */
.hc-topbar { color: #dceaf6; background: var(--hc-dark); font-size: .87rem; }
.hc-topbar__inner { display: flex; justify-content: space-between; align-items: center; min-height: 39px; gap: 18px; }
.hc-topbar__links { display: flex; gap: 18px; align-items: center; }
.hc-topbar a { color: #fff; }
.hc-topbar svg { width: 16px; vertical-align: -4px; }
.hc-header { z-index: 999; background: rgba(255,255,255,.96); border-bottom: 1px solid rgba(220,230,240,.85); backdrop-filter: blur(14px); }
.hc-header.is-sticky { position: sticky; top: 0; }
.hc-header__inner { display: flex; align-items: center; min-height: 82px; gap: 28px; }
.hc-brand { display: flex; align-items: center; gap: 12px; min-width: max-content; color: var(--hc-dark); }
.hc-brand:hover { color: var(--hc-dark); }
.hc-brand__mark { display: grid; place-items: center; width: 46px; height: 46px; color: #fff; border-radius: 15px; background: linear-gradient(135deg, var(--hc-secondary), var(--hc-primary)); }
.hc-brand__mark svg { width: 28px; }
.hc-brand__text strong { display: block; font-size: 1rem; line-height: 1.35; }
.hc-brand__text small { display: block; color: var(--hc-muted); font-size: .72rem; }
.custom-logo-link img { width: auto; max-height: 58px; }
.hc-nav { margin-inline-start: auto; }
.hc-menu { display: flex; align-items: center; gap: 7px; margin: 0; padding: 0; list-style: none; }
.hc-menu li { position: relative; }
.hc-menu a { display: block; padding: 10px 12px; color: var(--hc-dark); border-radius: 10px; font-size: .94rem; font-weight: 700; }
.hc-menu a:hover, .hc-menu .current-menu-item > a { color: var(--hc-primary); background: #eef5fb; }
.hc-menu .sub-menu {
  position: absolute; top: calc(100% + 8px); right: 0; min-width: 210px; margin: 0; padding: 9px;
  list-style: none; opacity: 0; visibility: hidden; transform: translateY(7px); background: #fff;
  border: 1px solid var(--hc-border); border-radius: 14px; box-shadow: var(--hc-shadow); transition: .2s ease;
}
.hc-menu li:hover > .sub-menu, .hc-menu li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }
.hc-header__cta { margin-inline-start: 6px; }
.hc-menu-toggle { display: none; width: 46px; height: 46px; border: 0; border-radius: 13px; color: var(--hc-dark); background: #edf3f8; }
.hc-menu-toggle svg { width: 24px; }

/* Hero */
.hc-hero { position: relative; overflow: hidden; padding: 74px 0 52px; background: radial-gradient(circle at 20% 20%, rgba(36,166,161,.15), transparent 31%), linear-gradient(135deg, #f9fbfe 0%, #edf5fb 100%); }
.hc-hero::before, .hc-hero::after { content: ""; position: absolute; border-radius: 50%; pointer-events: none; }
.hc-hero::before { width: 390px; height: 390px; left: -190px; bottom: -210px; background: rgba(13,79,139,.07); }
.hc-hero::after { width: 270px; height: 270px; right: -120px; top: -120px; background: rgba(215,53,69,.06); }
.hc-hero__grid { position: relative; z-index: 2; display: grid; grid-template-columns: 1.05fr .95fr; align-items: center; gap: 62px; }
.hc-hero h1 { max-width: 700px; font-size: clamp(2.15rem, 4.7vw, 4.3rem); letter-spacing: -.045em; }
.hc-hero h1 em { color: var(--hc-secondary); font-style: normal; }
.hc-hero__lead { max-width: 670px; color: var(--hc-text); font-size: clamp(1rem, 1.5vw, 1.2rem); }
.hc-hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hc-hero__visual { position: relative; min-height: 510px; }
.hc-hero__image-wrap {
  position: absolute; inset: 0 30px 0 0; overflow: hidden; border-radius: 48% 48% var(--hc-radius) var(--hc-radius);
  background: linear-gradient(150deg, #dbeaf5, #f8fbfd); box-shadow: 0 32px 80px rgba(13,79,139,.17);
}
.hc-hero__image { width: 100%; height: 100%; object-fit: cover; object-position: center top; }
.hc-hero__placeholder { display: grid; place-items: center; height: 100%; color: rgba(13,79,139,.23); }
.hc-hero__placeholder svg { width: 52%; height: auto; }
.hc-floating-card { position: absolute; z-index: 3; display: flex; align-items: center; gap: 13px; padding: 15px 18px; border: 1px solid rgba(255,255,255,.8); border-radius: 17px; background: rgba(255,255,255,.92); box-shadow: var(--hc-shadow); backdrop-filter: blur(10px); }
.hc-floating-card--top { top: 58px; left: -5px; }
.hc-floating-card--bottom { bottom: 42px; right: -8px; }
.hc-floating-card__icon { display: grid; place-items: center; width: 42px; height: 42px; color: #fff; border-radius: 13px; background: var(--hc-accent); }
.hc-floating-card strong { display: block; color: var(--hc-dark); font-size: .9rem; }
.hc-floating-card small { display: block; color: var(--hc-muted); font-size: .72rem; }
.hc-trust-strip { position: relative; z-index: 4; display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 52px; overflow: hidden; border: 1px solid rgba(220,230,240,.8); border-radius: 21px; background: rgba(255,255,255,.84); box-shadow: 0 14px 42px rgba(16,36,58,.06); }
.hc-trust-item { display: flex; align-items: center; justify-content: center; gap: 11px; min-height: 76px; padding: 15px; color: var(--hc-dark); font-weight: 750; }
.hc-trust-item + .hc-trust-item { border-right: 1px solid var(--hc-border); }
.hc-trust-item svg { width: 24px; color: var(--hc-primary); }

/* Services, booking and about */
.hc-service-card h3, .hc-booking-card h3 { font-size: 1.23rem; }
.hc-service-card p { color: var(--hc-muted); font-size: .94rem; }
.hc-service-card__link { display: inline-flex; align-items: center; gap: 5px; margin-top: 8px; font-weight: 800; }
.hc-about { display: grid; grid-template-columns: .9fr 1.1fr; align-items: center; gap: 70px; }
.hc-about__visual { position: relative; }
.hc-about__image { width: 100%; aspect-ratio: .9; object-fit: cover; object-position: center top; border-radius: var(--hc-radius); box-shadow: var(--hc-shadow); }
.hc-about__placeholder { display: grid; place-items: center; aspect-ratio: .9; border-radius: var(--hc-radius); color: rgba(13,79,139,.22); background: #eaf2f8; }
.hc-about__placeholder svg { width: 45%; }
.hc-about__badge { position: absolute; left: -24px; bottom: 35px; padding: 19px 22px; color: #fff; border-radius: 18px; background: linear-gradient(135deg, var(--hc-primary), #1673b5); box-shadow: 0 16px 34px rgba(13,79,139,.24); }
.hc-about__badge strong { display: block; font-size: 1.2rem; }
.hc-about__content h2 { font-size: clamp(1.9rem, 3.2vw, 3rem); }
.hc-check-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px 20px; margin: 24px 0; padding: 0; list-style: none; }
.hc-check-list li { display: flex; align-items: center; gap: 9px; color: var(--hc-dark); font-weight: 650; }
.hc-check-list svg { width: 20px; color: var(--hc-accent); }
.hc-booking-card { overflow: hidden; min-height: 330px; padding: 38px; }
.hc-booking-card::after { content: ""; position: absolute; width: 180px; height: 180px; left: -75px; bottom: -90px; border-radius: 50%; background: rgba(255,255,255,.1); }
.hc-booking-card--visit { color: #e8f3fc; background: linear-gradient(145deg, var(--hc-primary), #1675b9); border: 0; }
.hc-booking-card--online { color: #ffeff1; background: linear-gradient(145deg, #b92739, var(--hc-secondary)); border: 0; }
.hc-booking-card h3, .hc-booking-card p { color: inherit; }
.hc-booking-card .hc-icon-box { color: var(--hc-primary); background: #fff; box-shadow: none; }
.hc-booking-card--online .hc-icon-box { color: var(--hc-secondary); }
.hc-booking-card .hc-button { position: absolute; right: 38px; bottom: 38px; color: var(--hc-dark); background: #fff; }

/* CTA, posts, testimonials, contact */
.hc-question-cta { display: grid; grid-template-columns: 1.25fr .75fr; align-items: center; gap: 28px; padding: 44px 48px; color: #eaf3fb; border-radius: calc(var(--hc-radius) + 5px); background: radial-gradient(circle at 15% 20%, rgba(36,166,161,.35), transparent 35%), linear-gradient(135deg, var(--hc-dark), #153d63); box-shadow: var(--hc-shadow); }
.hc-question-cta h2 { color: #fff; font-size: clamp(1.65rem, 3vw, 2.45rem); }
.hc-question-cta p { margin-bottom: 0; color: #ccdae8; }
.hc-question-cta__action { text-align: left; }
.hc-post-card { overflow: hidden; padding: 0; }
.hc-post-card__image { display: block; overflow: hidden; aspect-ratio: 16/10; background: #eaf1f7; }
.hc-post-card__image img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.hc-post-card:hover .hc-post-card__image img { transform: scale(1.045); }
.hc-post-card__content { padding: 24px; }
.hc-post-card__meta { display: flex; gap: 13px; color: var(--hc-muted); font-size: .79rem; }
.hc-post-card h3 { margin-top: 10px; font-size: 1.12rem; }
.hc-testimonial-card { padding-top: 34px; }
.hc-testimonial-card::before { content: "“"; position: absolute; top: 4px; right: 22px; color: rgba(13,79,139,.13); font: 800 5rem/1 Georgia, serif; }
.hc-testimonial-card__author { display: flex; align-items: center; gap: 12px; margin-top: 18px; }
.hc-testimonial-card__avatar { display: grid; place-items: center; width: 45px; height: 45px; color: #fff; border-radius: 50%; background: var(--hc-primary); font-weight: 800; }
.hc-testimonial-card__author small { display: block; color: var(--hc-muted); }
.hc-contact-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 34px; }
.hc-contact-list { display: grid; gap: 14px; margin: 24px 0 0; padding: 0; list-style: none; }
.hc-contact-list li { display: flex; gap: 13px; }
.hc-contact-list svg { flex: 0 0 auto; width: 21px; margin-top: 5px; color: var(--hc-secondary); }
.hc-map { min-height: 390px; overflow: hidden; border: 1px solid var(--hc-border); border-radius: var(--hc-radius); background: #eaf1f7; }
.hc-map iframe { width: 100%; height: 100%; min-height: 390px; border: 0; }
.hc-map__placeholder { display: grid; place-items: center; height: 390px; color: var(--hc-muted); text-align: center; }

/* Inner pages */
.hc-page-hero { padding: 58px 0; color: #dce8f3; background: linear-gradient(135deg, var(--hc-dark), #174a75); }
.hc-page-hero h1 { color: #fff; font-size: clamp(2rem, 4vw, 3.25rem); }
.hc-breadcrumbs { color: #b9cbe0; font-size: .86rem; }
.hc-breadcrumbs a { color: #fff; }
.hc-content-wrap { padding-block: 62px 90px; }
.hc-entry { padding: clamp(24px, 4vw, 48px); border: 1px solid var(--hc-border); border-radius: var(--hc-radius); background: #fff; box-shadow: 0 10px 34px rgba(16,36,58,.05); }
.hc-entry__featured { margin: -20px -20px 30px; overflow: hidden; border-radius: calc(var(--hc-radius) - 4px); }
.hc-entry__featured img { width: 100%; max-height: 600px; object-fit: cover; }
.hc-entry-content > * { max-width: 100%; }
.hc-entry-content h2 { margin-top: 1.6em; }
.hc-entry-content a { text-decoration: underline; text-underline-offset: 3px; }
.hc-entry-content table { width: 100%; border-collapse: collapse; }
.hc-entry-content th, .hc-entry-content td { padding: 12px; border: 1px solid var(--hc-border); }
.hc-entry-content blockquote { margin: 28px 0; padding: 20px 24px; border-right: 4px solid var(--hc-secondary); border-radius: 10px; background: #f5f8fb; }
.hc-archive-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 24px; }
.nav-links { display: flex; justify-content: center; gap: 8px; margin-top: 36px; }
.nav-links .page-numbers { display: grid; place-items: center; min-width: 42px; height: 42px; padding: 0 10px; border-radius: 10px; background: #fff; border: 1px solid var(--hc-border); }
.nav-links .current { color: #fff; background: var(--hc-primary); }
.hc-empty { padding: 50px; text-align: center; }

/* Forms */
input[type="text"], input[type="email"], input[type="tel"], input[type="date"], input[type="time"], input[type="number"], input[type="password"], input[type="url"], select, textarea {
  width: 100%; min-height: 49px; padding: 11px 14px; color: var(--hc-dark); border: 1px solid #cfdae5; border-radius: 12px; background: #fff; outline: none;
}
textarea { min-height: 130px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--hc-primary); box-shadow: 0 0 0 3px rgba(13,79,139,.1); }
label { color: var(--hc-dark); font-weight: 700; }

/* Footer */
.hc-footer { color: #c5d4e3; background: #0c1d2f; }
.hc-footer__grid { display: grid; grid-template-columns: 1.25fr .75fr .75fr 1fr; gap: 36px; padding-block: 66px 48px; }
.hc-footer h3 { color: #fff; font-size: 1.05rem; }
.hc-footer a { color: #d7e3ef; }
.hc-footer a:hover { color: #fff; }
.hc-footer ul { margin: 0; padding: 0; list-style: none; }
.hc-footer li { margin-bottom: 8px; }
.hc-footer__brand { max-width: 330px; }
.hc-socials { display: flex; gap: 9px; margin-top: 18px; }
.hc-socials a { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 11px; background: rgba(255,255,255,.08); }
.hc-socials svg { width: 19px; }
.hc-footer__bottom { padding: 18px 0; border-top: 1px solid rgba(255,255,255,.09); color: #94a8bc; font-size: .84rem; text-align: center; }

@media (max-width: 1050px) {
  .hc-grid--4 { grid-template-columns: repeat(2, 1fr); }
  .hc-footer__grid { grid-template-columns: repeat(2, 1fr); }
  .hc-header__cta { display: none; }
}
@media (max-width: 900px) {
  body.admin-bar .hc-header.is-sticky { top: 46px; }
  .hc-topbar { display: none; }
  .hc-header__inner { min-height: 72px; }
  .hc-menu-toggle { display: grid; place-items: center; margin-inline-start: auto; }
  .hc-nav { position: absolute; top: 72px; right: 20px; left: 20px; display: none; margin: 0; padding: 12px; border: 1px solid var(--hc-border); border-radius: 17px; background: #fff; box-shadow: var(--hc-shadow); }
  .hc-nav.is-open { display: block; }
  .hc-menu { display: block; }
  .hc-menu a { padding: 12px; }
  .hc-menu .sub-menu { position: static; display: block; min-width: 0; padding: 0 16px; opacity: 1; visibility: visible; transform: none; border: 0; box-shadow: none; }
  .hc-hero { padding-top: 50px; }
  .hc-hero__grid, .hc-about, .hc-contact-grid { grid-template-columns: 1fr; }
  .hc-hero__visual { min-height: 470px; }
  .hc-about { gap: 40px; }
  .hc-about__visual { max-width: 580px; margin-inline: auto; }
  .hc-question-cta { grid-template-columns: 1fr; }
  .hc-question-cta__action { text-align: right; }
  .hc-archive-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  :root { --hc-section-space: 62px; --hc-card-padding: 22px; }
  .hc-container { width: min(calc(100% - 28px), var(--hc-container)); }
  .hc-brand__text small { display: none; }
  .hc-grid--2, .hc-grid--3, .hc-grid--4, .hc-archive-grid { grid-template-columns: 1fr; }
  .hc-hero h1 { font-size: 2.25rem; }
  .hc-hero__actions .hc-button { width: 100%; }
  .hc-hero__visual { min-height: 390px; }
  .hc-hero__image-wrap { inset-right: 0; border-radius: 42% 42% 22px 22px; }
  .hc-floating-card--top { top: 26px; left: -5px; }
  .hc-floating-card--bottom { right: -4px; bottom: 22px; }
  .hc-trust-strip { grid-template-columns: 1fr; }
  .hc-trust-item + .hc-trust-item { border-top: 1px solid var(--hc-border); border-right: 0; }
  .hc-check-list { grid-template-columns: 1fr; }
  .hc-about__badge { left: 14px; bottom: 18px; }
  .hc-booking-card { min-height: 310px; padding: 28px; }
  .hc-booking-card .hc-button { right: 28px; bottom: 28px; }
  .hc-question-cta { padding: 32px 25px; }
  .hc-footer__grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}
