/*
Theme Name: Hossam Amin Medical
Theme URI: https://example.com/
Author: OpenAI
Description: Premium, responsive bilingual Arabic-English medical website theme for Dr. Hossam Amin, Consultant Plastic Surgery. Built without Elementor or paid plugins.
Version: 1.8.0
Requires at least: 6.0
Tested up to: 6.9
Requires PHP: 7.4
Text Domain: hossam-amin-medical
License: GPL-2.0-or-later
*/

:root {
  --ink: #182125;
  --muted: #677377;
  --paper: #fbfaf8;
  --white: #ffffff;
  --gold: #b79a63;
  --gold-dark: #927744;
  --sage: #8a9a95;
  --sage-light: #e9eeec;
  --line: #e8e3dc;
  --dark: #151b1d;
  --shadow: 0 18px 50px rgba(24,33,37,.08);
  --radius: 22px;
  --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin:0; color:var(--ink); background:var(--paper); font-family: "Cairo", "Manrope", Arial, sans-serif; line-height:1.8; }
body.ltr { font-family: "Manrope", "Cairo", Arial, sans-serif; }
body.admin-bar { padding-top: 0; }
a { color:inherit; text-decoration:none; }
img { max-width:100%; height:auto; display:block; }
button, input, textarea, select { font:inherit; }
.container { width:min(calc(100% - 40px), var(--container)); margin-inline:auto; }

.site-header { position:sticky; top:0; z-index:1000; background:rgba(251,250,248,.94); backdrop-filter:blur(14px); border-bottom:1px solid rgba(232,227,220,.75); }
.header-inner { min-height:82px; display:flex; align-items:center; justify-content:space-between; gap:26px; }
.brand { display:flex; align-items:center; gap:12px; font-weight:800; }
.brand-mark { width:42px; height:42px; }
.brand-copy small { display:block; color:var(--gold-dark); font-size:11px; letter-spacing:.09em; text-transform:uppercase; direction:ltr; }
.brand-copy strong { font-size:17px; }
.nav-toggle { display:none; background:none; border:0; font-size:26px; }
.primary-menu { display:flex; align-items:center; gap:22px; }
.primary-menu .nav-list { display:flex; align-items:center; gap:22px; list-style:none; padding:0; margin:0; }
.primary-menu a { color:#455155; font-size:14px; font-weight:700; }
.primary-menu a:hover { color:var(--gold-dark); }
.header-actions { display:flex; align-items:center; gap:14px; margin-inline-start:auto; }
.lang-switch { display:inline-flex; align-items:center; gap:6px; padding:4px 9px; border:1px solid var(--line); border-radius:999px; background:var(--white); font-size:11px; font-weight:800; color:var(--muted); white-space:nowrap; }
.lang-switch a { padding:3px 5px; color:var(--muted); border-radius:999px; }
.lang-switch a.active { color:var(--dark); background:#eee8df; }
.header-cta { background:var(--dark); color:var(--white); padding:11px 17px; border-radius:999px; font-size:13px; font-weight:800; }
.ltr .primary-menu { direction:ltr; }

.hero { padding:76px 0 70px; background:radial-gradient(circle at 10% 0%, rgba(183,154,99,.12), transparent 38%), linear-gradient(180deg,#fbfaf8,#f5f1eb); overflow:hidden; }
.hero-grid { display:grid; grid-template-columns:1.08fr .92fr; align-items:center; gap:52px; }
.kicker { display:inline-flex; align-items:center; gap:8px; color:var(--gold-dark); font-size:12px; font-weight:900; letter-spacing:.09em; text-transform:uppercase; direction:ltr; }
.kicker::before { content:""; width:30px; height:1px; background:var(--gold); }
.hero h1 { margin:16px 0 16px; font-size:clamp(38px,5vw,70px); line-height:1.14; letter-spacing:-.03em; }
.hero h1 em { font-style:normal; color:var(--gold-dark); }
.hero p { max-width:660px; color:var(--muted); font-size:17px; }
.actions { display:flex; flex-wrap:wrap; gap:12px; margin-top:28px; }
.btn { display:inline-flex; justify-content:center; align-items:center; gap:8px; border-radius:999px; padding:13px 20px; font-weight:800; font-size:14px; transition:transform .2s ease, box-shadow .2s ease, background .2s ease; }
.btn:hover { transform:translateY(-2px); }
.btn-primary { background:var(--dark); color:var(--white); box-shadow:0 10px 22px rgba(21,27,29,.14); }
.btn-secondary { background:var(--white); border:1px solid var(--line); }
.hero-art { position:relative; }
.hero-card { border-radius:32px; overflow:hidden; box-shadow:var(--shadow); background:var(--white); border:1px solid rgba(232,227,220,.8); }
.hero-card img { width:100%; aspect-ratio: 4 / 5; object-fit:cover; }
.floating-note { position:absolute; right:-18px; bottom:28px; width:190px; background:var(--dark); color:var(--white); padding:17px; border-radius:18px; box-shadow:var(--shadow); }
.floating-note strong { display:block; font-size:13px; }
.floating-note span { display:block; color:#d7dddb; font-size:11px; margin-top:2px; }

.section { padding:84px 0; }
.section.alt { background:#f1ede7; }
.section-head { max-width:720px; margin-bottom:36px; }
.eyebrow { color:var(--gold-dark); text-transform:uppercase; letter-spacing:.08em; font-size:11px; font-weight:900; direction:ltr; }
.section h2 { margin:8px 0 12px; font-size:clamp(28px,3.2vw,45px); line-height:1.25; letter-spacing:-.02em; }
.section-head p { color:var(--muted); margin:0; }

.cards { display:grid; grid-template-columns:repeat(3,1fr); gap:18px; }
.services-catalog { grid-template-columns:repeat(4,1fr); gap:16px; }
.service-card { padding:14px; display:flex; flex-direction:column; min-height:100%; }
.service-card img { aspect-ratio: 16 / 10; margin-bottom:14px; border-radius:14px; }
.service-card-copy { padding:0 6px 5px; }
.service-card h3 { font-size:16px; margin-bottom:6px; }
.service-card p { font-size:12px; line-height:1.7; }
.before-after-home { border-top:1px solid var(--line); }
.ba-home-head { display:flex; align-items:flex-end; justify-content:space-between; gap:22px; }
.ba-slider { position:relative; padding:6px 58px 46px; }
.ba-track { position:relative; min-height:0; overflow:hidden; border-radius:24px; }
.ba-slide { display:none; background:var(--white); border:1px solid var(--line); border-radius:24px; overflow:hidden; box-shadow:var(--shadow); }
.ba-slide.is-active { display:block; animation:hamFade .35s ease; }
@keyframes hamFade { from { opacity:.45; transform:translateY(4px); } to { opacity:1; transform:none; } }
.ba-slide-media { position:relative; background:#eee8df; }
.ba-slide-media img { width:100%; aspect-ratio:16 / 9; object-fit:cover; }
.ba-badge { position:absolute; inset-inline-start:16px; inset-block-start:16px; background:rgba(21,27,29,.9); color:#fff; padding:7px 10px; border-radius:999px; font-size:11px; font-weight:800; }
.ba-slide-copy { padding:16px 18px 18px; }
.ba-slide-copy > div { display:flex; align-items:center; justify-content:space-between; gap:16px; }
.ba-slide-copy strong { font-size:16px; }
.ba-slide-copy span { color:var(--muted); font-size:11px; white-space:nowrap; }
.ba-slider-arrow { position:absolute; top:50%; transform:translateY(-65%); width:42px; height:42px; border:1px solid var(--line); background:var(--white); color:var(--dark); border-radius:50%; display:grid; place-items:center; font-size:26px; line-height:1; cursor:pointer; box-shadow:0 8px 18px rgba(21,27,29,.08); z-index:2; }
.ba-slider-arrow:hover { background:var(--dark); color:#fff; }
.ba-prev { inset-inline-start:0; }
.ba-next { inset-inline-end:0; }
.ba-dots { position:absolute; inset-inline:0; bottom:7px; display:flex; justify-content:center; gap:7px; }
.ba-dot { width:7px; height:7px; border:0; border-radius:50%; background:#c8c1b7; padding:0; cursor:pointer; }
.ba-dot.is-active { width:22px; border-radius:999px; background:var(--dark); }
.ba-no-cases { margin-top:8px; }
.ba-empty-image { width:100%; aspect-ratio:16 / 9; display:grid; place-items:center; padding:30px; color:var(--muted); background:#f1ede7; text-align:center; }

.ba-category-cards { display:grid; grid-template-columns:repeat(3,1fr); gap:16px; margin-bottom:22px; }
.ba-category-card { display:flex; align-items:center; gap:12px; padding:10px; background:var(--white); border:1px solid var(--line); border-radius:18px; box-shadow:0 8px 24px rgba(24,33,37,.05); transition:transform .2s ease, border-color .2s ease, box-shadow .2s ease; }
.ba-category-card:hover { transform:translateY(-2px); border-color:rgba(183,154,99,.6); box-shadow:0 12px 28px rgba(24,33,37,.08); }
.ba-category-card.is-active { border-color:var(--gold); box-shadow:0 12px 28px rgba(183,154,99,.12); }
.ba-category-card img { width:74px; height:54px; object-fit:cover; border-radius:12px; background:#eee8df; flex:0 0 auto; }
.ba-category-card span { font-weight:800; font-size:13px; line-height:1.3; }
@media (max-width:820px){ .ba-category-cards{grid-template-columns:repeat(2,1fr);} }
@media (max-width:560px){ .ba-category-cards{grid-template-columns:1fr;} .ba-category-card img{width:82px;height:58px;} }

.ba-cases-grid figure { min-width:0; }
.ba-case-card img, .ba-case-card .ba-empty-image { width:100%; aspect-ratio:16 / 10; object-fit:cover; border-radius:12px; }
.ba-case-card figcaption { display:flex; align-items:baseline; justify-content:space-between; gap:12px; line-height:1.6; }
.ba-case-card figcaption strong { color:var(--ink); font-size:13px; }
.ba-case-card figcaption span { color:var(--muted); font-size:11px; white-space:nowrap; }
.card { background:var(--white); border:1px solid var(--line); border-radius:var(--radius); padding:24px; box-shadow:0 8px 28px rgba(24,33,37,.035); }
.card img { width:100%; aspect-ratio: 16 / 10; object-fit:cover; border-radius:16px; margin-bottom:18px; }
.card h3 { margin:0 0 8px; font-size:20px; }
.card p { margin:0; color:var(--muted); font-size:14px; }
.card-link { display:inline-flex; margin-top:17px; font-weight:800; color:var(--gold-dark); font-size:13px; }

.split { display:grid; grid-template-columns: .88fr 1.12fr; gap:48px; align-items:center; }
.split.reverse { grid-template-columns: 1.12fr .88fr; }
.media-card { border-radius:30px; overflow:hidden; border:1px solid var(--line); box-shadow:var(--shadow); background:var(--white); }
.media-card img { width:100%; aspect-ratio: 1 / 1; object-fit:cover; }
.checks { display:grid; gap:13px; margin:24px 0 0; }
.check { display:flex; gap:12px; align-items:flex-start; }
.check-icon { flex:0 0 28px; width:28px; height:28px; border-radius:50%; background:var(--sage-light); display:grid; place-items:center; color:#41544e; font-weight:900; font-size:13px; }
.check strong { display:block; font-size:14px; }
.check span { display:block; color:var(--muted); font-size:13px; }

.steps { display:grid; grid-template-columns:repeat(4,1fr); gap:14px; }
.step { padding:22px; border:1px solid var(--line); border-radius:20px; background:var(--white); }
.step-num { width:34px; height:34px; border-radius:50%; background:var(--dark); color:#fff; display:grid; place-items:center; font-size:12px; font-weight:900; margin-bottom:17px; }
.step h3 { margin:0 0 7px; font-size:16px; }
.step p { margin:0; color:var(--muted); font-size:13px; }

.testimonials { display:grid; grid-template-columns:repeat(3,1fr); gap:18px; }
.quote { background:var(--white); border:1px solid var(--line); border-radius:22px; padding:24px; }
.quote-mark { color:var(--gold); font-size:35px; line-height:1; }
.quote p { margin:8px 0 16px; color:#454f52; font-size:14px; }
.quote small { color:var(--muted); }
.notice { padding:14px 18px; border:1px solid #ded8ca; background:#f8f5ef; border-radius:14px; color:#5f5b52; font-size:12px; }

.cta { padding:66px 0; background:var(--dark); color:#fff; }
.cta-inner { display:flex; align-items:center; justify-content:space-between; gap:30px; }
.cta h2 { margin:0 0 8px; font-size:clamp(28px,3vw,42px); }
.cta p { color:#c5cecc; margin:0; }
.btn-light { background:#fff; color:var(--dark); }

.page-hero { padding:70px 0 52px; background:linear-gradient(180deg,#f3eee7,#fbfaf8); }
.page-hero h1 { margin:0 0 10px; font-size:clamp(35px,4vw,58px); line-height:1.2; }
.page-hero p { margin:0; max-width:700px; color:var(--muted); }
.content-narrow { width:min(100%,880px); }
.content-narrow h2 { margin-top:38px; }
.content-narrow p, .content-narrow li { color:#536064; font-size:15px; }
.service-grid { display:grid; grid-template-columns:repeat(2,1fr); gap:18px; }
.service-feature { display:grid; grid-template-columns:74px 1fr; gap:18px; align-items:start; padding:22px; background:#fff; border:1px solid var(--line); border-radius:20px; }
.service-feature img { width:74px; height:74px; object-fit:cover; border-radius:18px; }
.service-feature h3 { margin:0 0 6px; }

.gallery { display:grid; grid-template-columns:repeat(3,1fr); gap:16px; }
.gallery figure { margin:0; background:#fff; padding:10px; border:1px solid var(--line); border-radius:18px; }
.gallery img { width:100%; aspect-ratio: 1 / 1; object-fit:cover; border-radius:12px; }
.gallery figcaption { padding:10px 4px 3px; color:var(--muted); font-size:12px; }

.contact-grid { display:grid; grid-template-columns:.9fr 1.1fr; gap:22px; }
.contact-card { background:#fff; border:1px solid var(--line); border-radius:24px; padding:28px; }
.contact-row { display:flex; gap:13px; padding:14px 0; border-bottom:1px solid var(--line); }
.contact-row:last-child { border-bottom:0; }
.contact-row strong { display:block; font-size:13px; }
.contact-row span { color:var(--muted); font-size:13px; }
.form-grid { display:grid; grid-template-columns:1fr 1fr; gap:13px; }
.form-field { display:grid; gap:6px; }
.form-field.full { grid-column:1 / -1; }
.form-field label { font-size:12px; font-weight:800; }
.form-field input, .form-field textarea { border:1px solid var(--line); border-radius:14px; padding:12px 13px; background:#fcfbf9; outline:none; }
.form-field textarea { min-height:145px; resize:vertical; }
.form-field input:focus, .form-field textarea:focus { border-color:#b9ab8e; box-shadow:0 0 0 4px rgba(183,154,99,.1); }
.honeypot { position:absolute !important; left:-9999px !important; width:1px !important; height:1px !important; overflow:hidden !important; }

.site-footer { background:#111617; color:#dfe5e3; padding:54px 0 20px; }
.footer-grid { display:grid; grid-template-columns:1.2fr .8fr .8fr; gap:30px; }
.site-footer p, .site-footer li, .site-footer a { color:#aeb8b6; font-size:13px; }
.site-footer h3 { color:#fff; font-size:15px; margin:0 0 12px; }
.footer-menu { list-style:none; margin:0; padding:0; display:grid; gap:7px; }
.footer-bottom { display:flex; justify-content:space-between; gap:20px; border-top:1px solid #252d2f; margin-top:30px; padding-top:18px; font-size:11px; color:#899492; }

.floating-whatsapp { position:fixed; bottom:20px; left:20px; z-index:1100; width:54px; height:54px; border-radius:50%; background:#1fae60; color:#fff; display:grid; place-items:center; box-shadow:0 12px 28px rgba(0,0,0,.16); font-size:21px; font-weight:900; }

.rtl-note { direction:rtl; }
.lang-switch { font-size:12px; font-weight:800; color:var(--gold-dark); }
.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; }


/* Dynamic Before & After case pages and category filters */
.ba-category-nav { display:flex; flex-wrap:wrap; gap:9px; margin:0 0 26px; }
.ba-category-nav a { padding:9px 14px; border:1px solid var(--line); border-radius:999px; background:var(--white); color:var(--muted); font-size:12px; font-weight:800; }
.ba-category-nav a.is-active, .ba-category-nav a:hover { background:var(--dark); color:#fff; border-color:var(--dark); }
.ba-case-card { display:flex; flex-direction:column; }
.ba-case-card > a { display:block; }
.ba-case-card .ba-case-image-wrap { overflow:hidden; border-radius:12px; background:#f1ede7; }
.ba-case-card img { transition:transform .35s ease; }
.ba-case-card > a:hover img { transform:scale(1.025); }
.ba-case-meta { padding:12px 4px 3px; display:flex; flex-direction:column; gap:2px; }
.ba-case-meta strong { color:var(--ink); font-size:14px; }
.ba-case-meta span { color:var(--muted); font-size:11px; }
.case-detail-head { display:flex; flex-direction:column; gap:8px; max-width:850px; }
.case-category { color:var(--gold-dark); font-size:11px; font-weight:900; letter-spacing:.08em; text-transform:uppercase; direction:ltr; }
.case-detail-title { margin:0; font-size:clamp(30px,4vw,56px); line-height:1.18; }
.case-detail-date { color:var(--muted); font-size:12px; }
.case-main-image { margin:32px 0 0; border-radius:24px; overflow:hidden; background:#f1ede7; border:1px solid var(--line); box-shadow:var(--shadow); }
.case-main-image img { width:100%; aspect-ratio:16 / 10; object-fit:cover; }
.case-gallery-title { margin:54px 0 20px; }
.case-gallery-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:16px; }
.case-gallery-grid a { display:block; overflow:hidden; border-radius:18px; border:1px solid var(--line); background:#fff; }
.case-gallery-grid img { width:100%; aspect-ratio:1 / 1; object-fit:cover; transition:transform .3s ease; }
.case-gallery-grid a:hover img { transform:scale(1.025); }
.case-copy { margin-top:34px; }
.case-copy p { color:#536064; font-size:15px; }
.case-back { margin-top:34px; }


@media (max-width: 980px) {
  .header-actions { gap:10px; }
  .primary-menu { display:none; position:absolute; top:82px; inset-inline:20px; padding:16px; border:1px solid var(--line); border-radius:18px; background:var(--white); box-shadow:var(--shadow); flex-direction:column; align-items:stretch; }
  .primary-menu.is-open { display:flex; }
  .nav-toggle { display:block; }
  .hero-grid, .split, .split.reverse, .contact-grid { grid-template-columns:1fr; }
  .hero-art { max-width:720px; margin-inline:auto; width:100%; }
  .cards, .testimonials { grid-template-columns:1fr 1fr; }
  .case-gallery-grid { grid-template-columns:1fr 1fr; }
  .services-catalog { grid-template-columns:repeat(3,1fr); }
  .before-after-grid { grid-template-columns:1fr 1fr; }
  .steps { grid-template-columns:1fr 1fr; }
  .footer-grid { grid-template-columns:1fr 1fr; }
}
@media (max-width: 680px) {
  .container { width:min(calc(100% - 28px), var(--container)); }
  .site-header { top:0; }
  .header-inner { min-height:74px; }
  .primary-menu { top:74px; inset-inline:14px; }
  .header-cta { display:none; }
  .lang-switch { margin-inline-start:auto; }
  .hero { padding:52px 0 52px; }
  .section { padding:64px 0; }
  .cards, .testimonials, .service-grid, .gallery, .steps, .footer-grid, .before-after-grid { grid-template-columns:1fr; }
  .ba-home-head { align-items:flex-start; flex-direction:column; }
  .ba-slider { padding-inline:44px; }
  .ba-slide-copy > div { align-items:flex-start; flex-direction:column; gap:4px; }
  .case-gallery-grid { grid-template-columns:1fr; }
  .services-catalog { grid-template-columns:1fr 1fr; }
  .cta-inner { flex-direction:column; align-items:flex-start; }
  .form-grid { grid-template-columns:1fr; }
  .form-field.full { grid-column:auto; }
  .floating-note { right:10px; bottom:15px; width:165px; }
  .footer-bottom { flex-direction:column; gap:4px; }
}
