/* Your Health Clinic — global styles */

:root {
    --color-navy: #152036;
    --color-orange: #f4991a;
    --color-orange-hot: #f7751f;
    --color-green: #136e47;
    --color-muted: #5d6573;
    --color-muted-soft: rgba(93, 101, 115, 0.5);
    --color-cream: #f7f6f2;
    --color-soft: #f3f5f8;
    --color-border: #d8dce2;
    --color-divider: #dde0e4;
    --color-footer-border: #354157;
    --color-footer-muted: #cbd3de;
    --color-footer-link: #dce2ea;
    --color-white: #ffffff;
    --color-black-50: rgba(0, 0, 0, 0.5);
    --font: "Plus Jakarta Sans", "Google Sans", sans-serif;
    --container: 1180px;
    --gutter: 93px;
    --gutter-sm: 84px;
    --radius: 12px;
    --transition: 0.25s ease;
    --transition-media: 0.45s ease;
    --shadow-hover: 0 12px 28px rgba(21, 32, 54, 0.1);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.5;
    color: var(--color-navy);
    background: var(--color-white);
    -webkit-font-smoothing: antialiased;
}

html[lang="ar"] body {
    font-family: "Noto Sans Arabic", var(--font);
}

html[dir="rtl"] .topbar__inner,
html[dir="rtl"] .nav__inner {
    direction: rtl;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
    color: inherit;
}

button {
    cursor: pointer;
    border: 0;
    background: none;
    padding: 0;
}

ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

h1,
h2,
h3,
h4,
p {
    margin: 0;
}

.container {
    width: 100%;
    max-width: calc(var(--container) + var(--gutter) * 2);
    margin: 0 auto;
    padding-left: var(--gutter);
    padding-right: var(--gutter);
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.divider {
    width: 100%;
    height: 1px;
    border: 0;
    background: var(--color-divider);
    margin: 0;
}

/* Buttons */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 52px;
    padding: 14px 24px;
    border: 1px solid transparent;
    border-radius: var(--radius);
    font-size: 16px;
    font-weight: 500;
    line-height: 1.5;
    color: var(--color-white);
    transition:
        background var(--transition),
        color var(--transition),
        border-color var(--transition),
        box-shadow var(--transition),
        transform var(--transition);
    text-align: center;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(21, 32, 54, 0.14);
}

.btn:active {
    transform: translateY(0);
    box-shadow: none;
}

.btn--orange {
    background: var(--color-orange);
}

.btn--orange:hover {
    background: var(--color-orange-hot);
}

.btn--outline {
    background: transparent;
    color: var(--color-navy);
    border-color: var(--color-navy);
}

.btn--outline:hover {
    background: var(--color-navy);
    color: var(--color-white);
    border-color: var(--color-navy);
}

.btn--green {
    background: var(--color-green);
    min-width: 230px;
}

.btn--green:hover {
    background: #0f5a39;
}

.btn--lg {
    padding: 18px 32px;
}

/* Section titles */

.section-title {
    font-size: 39px;
    font-weight: 400;
    line-height: 1.2;
    color: var(--color-navy);
    text-align: center;
}

.section-title--left {
    text-align: left;
}

.section-title--light {
    color: var(--color-white);
}

.section-lead {
    max-width: 880px;
    margin: 0 auto;
    text-align: center;
    color: var(--color-muted);
    font-size: 16px;
    line-height: 1.5;
}

/* Inner page intro (shared) */

.page-intro {
    padding: 60px 0;
    background: var(--color-white);
}

.page-intro__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    text-align: center;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    line-height: 1.5;
    color: var(--color-muted);
}

.breadcrumb a {
    transition: color var(--transition);
}

.breadcrumb a:hover {
    color: var(--color-navy);
}

.breadcrumb__sep {
    opacity: 0.7;
}

.breadcrumb__current {
    color: var(--color-muted);
}

.page-intro__copy {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    max-width: 980px;
    width: 100%;
}

.page-intro__title {
    font-size: 49px;
    font-weight: 400;
    line-height: 1.2;
    color: var(--color-navy);
}

.page-intro__lead {
    max-width: 880px;
    font-size: 20px;
    line-height: 1.5;
    color: var(--color-muted);
}

/* Header */

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--color-white);
}

.topbar {
    background: var(--color-cream);
    padding: 10px 0;
}

.topbar__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    max-width: calc(var(--container) + var(--gutter-sm) * 2);
    padding-left: var(--gutter-sm);
    padding-right: var(--gutter-sm);
}

.topbar__location {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.topbar__copy {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    min-width: 0;
    font-size: 13px;
    font-weight: 500;
    line-height: 20px;
    color: var(--color-navy);
    white-space: nowrap;
}

.topbar__copy--dental {
    font-weight: 500;
}

.topbar__brand {
    font-weight: 700;
}

.topbar__sep {
    color: var(--color-muted-soft);
    margin: 0 0.35em;
}

.icon {
    display: inline-block;
    flex-shrink: 0;
    vertical-align: middle;
}

.icon--external {
    margin-left: 0.3em;
    position: relative;
    top: -0.05em;
}

.footer-bottom__link {
    display: inline-flex;
    align-items: center;
}

.topbar__address {
    min-width: 0;
}

.topbar__phone {
    transition: color var(--transition);
}

.topbar__phone:hover {
    color: var(--color-orange);
}

.topbar__socials {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.topbar__icon {
    flex-shrink: 0;
    display: flex;
    opacity: 0.9;
    transition: opacity var(--transition);
}

.topbar__icon:hover {
    opacity: 1;
}

.topbar__lang {
    position: relative;
    z-index: 2;
    flex-shrink: 0;
}

.lang-switch {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 0;
    border: 0;
    background: transparent;
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.5;
    color: var(--color-navy);
    cursor: pointer;
    transition: color var(--transition);
}

.lang-switch:hover {
    color: var(--color-orange);
}

.lang-switch img:first-child,
.lang-switch__chevron {
    opacity: 0.5;
}

.lang-switch__chevron {
    transition: transform var(--transition);
}

[data-dropdown].is-open .lang-switch__chevron,
[data-dropdown].is-open .nav__link--has-sub img {
    transform: rotate(180deg);
}

.nav {
    position: relative;
    background: var(--color-white);
    padding: 18px 0;
}

.nav__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    max-width: calc(var(--container) + var(--gutter-sm) * 2);
    padding-left: var(--gutter-sm);
    padding-right: var(--gutter-sm);
}

.nav__logo {
    flex-shrink: 0;
    width: 150px;
    transition: opacity var(--transition);
}

.nav__logo:hover {
    opacity: 0.82;
}

.nav__logo img {
    width: 150px;
    height: 45px;
    object-fit: contain;
}

.nav__menu {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav__item {
    position: relative;
}

.nav__link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 0;
    border: 0;
    background: transparent;
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    line-height: 20px;
    color: var(--color-navy);
    white-space: nowrap;
    cursor: pointer;
    transition: color var(--transition);
}

.nav__link:hover,
.nav__link--btn:hover,
.nav__item.is-open > .nav__link {
    color: var(--color-orange);
}

.nav__link--has-sub img {
    transition: transform var(--transition);
}

.dropdown {
    position: absolute;
    z-index: 120;
    margin: 0;
    padding: 12px;
    list-style: none;
    background: var(--color-white);
    border: 1px solid var(--color-divider);
    border-radius: 2px;
    box-shadow: 0 16px 40px rgba(21, 32, 54, 0.12);
}

.dropdown[hidden] {
    display: none;
}

.dropdown--lang {
    top: calc(100% + 8px);
    right: 0;
    min-width: 88px;
    padding: 8px;
}

.dropdown--simple {
    top: calc(100% + 14px);
    left: 0;
    min-width: 220px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px;
}

.dropdown--services {
    top: calc(100% + 14px);
    left: 0;
    width: min(760px, calc(100vw - 48px));
    padding: 20px;
}

.dropdown__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4px 16px;
}

.dropdown__link,
.dropdown__option {
    display: block;
    width: 100%;
    padding: 10px 12px;
    border: 0;
    border-radius: 2px;
    background: transparent;
    font-family: inherit;
    font-size: 14px;
    text-decoration: none;
    color: inherit;
    box-sizing: border-box;
    text-align: left;
    cursor: pointer;
    font-weight: 400;
    line-height: 1.4;
    color: var(--color-navy);
    text-align: left;
    white-space: normal;
    cursor: pointer;
    transition: background var(--transition), color var(--transition);
}

.dropdown__option {
    font-size: 13px;
    font-weight: 500;
}

.dropdown__link:hover,
.dropdown__option:hover,
.dropdown__option.is-active {
    background: var(--color-soft);
    color: var(--color-orange);
}

.dropdown__footer {
    display: inline-flex;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--color-divider);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    color: var(--color-navy);
    transition: color var(--transition);
}

.dropdown__footer:hover {
    color: var(--color-orange);
}

.nav__toggle {
    display: none;
    width: 40px;
    height: 40px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 6px;
}

.nav__toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--color-navy);
    transition: transform var(--transition), opacity var(--transition);
}

.nav__toggle.is-open span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.nav__toggle.is-open span:nth-child(2) {
    opacity: 0;
}

.nav__toggle.is-open span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Footer */

.site-footer {
    background: var(--color-navy);
    color: var(--color-white);
    padding: 64px 0 24px;
}

.footer-top {
    display: grid;
    grid-template-columns: 360px 1fr 1fr;
    gap: 20px;
    margin-bottom: 40px;
}

.topbar__inner--dental {
    justify-content: space-between;
}

.topbar__inner--dental .topbar__lang {
    margin-left: auto;
}

.topbar--dental .topbar__copy {
    font-weight: 700;
}

.footer-top--dental {
    grid-template-columns: 360px 390px;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.footer-brand__logo img {
    width: 150px;
    height: auto;
}

.footer-brand__text {
    font-size: 16px;
    line-height: 24px;
    max-width: 360px;
}

.footer-brand__license {
    font-size: 13px;
    line-height: 1.5;
    color: var(--color-footer-muted);
}

.footer-contact {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
}

.footer-contact__label {
    font-size: 13px;
    font-weight: 500;
    line-height: 1.5;
}

.footer-contact__phone {
    font-size: 28px;
    font-weight: 400;
    line-height: 1;
    transition: color var(--transition), opacity var(--transition);
}

.footer-contact__phone:hover {
    color: var(--color-orange);
}

.footer-contact__btn {
    width: 270px;
    justify-content: space-between;
    font-size: 14px;
    line-height: 21px;
}

.footer-contact__btn img {
    flex-shrink: 0;
}

.footer-contact__email {
    font-size: 16px;
    line-height: 24px;
    transition: color var(--transition);
}

.footer-contact__email:hover {
    color: var(--color-orange);
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding-top: 40px;
    border-top: 1px solid var(--color-footer-border);
}

.footer-col {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-col--visit {
    gap: 20px;
}

.footer-col__title {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.5;
    text-align: left;
    color: var(--color-white);
    cursor: default;
}

.footer-col__chevron {
    display: none;
    flex-shrink: 0;
    width: 16px;
    height: 16px;
}

.footer-col__panel {
    display: block;
}

.footer-col__panel-inner {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-col--visit .footer-col__panel-inner {
    gap: 20px;
}

.footer-col__city {
    font-size: 25px;
    line-height: 1.3;
    color: var(--color-footer-link);
}

.footer-col__list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-col__list a,
.footer-visit {
    font-size: 16px;
    line-height: 24px;
    color: var(--color-footer-link);
}

.footer-col__list a:hover {
    color: var(--color-white);
}

.footer-visit strong {
    font-weight: 700;
}

.footer-visit__hours {
    margin-top: 8px;
    font-size: 13px;
    line-height: 1.5;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-top: 40px;
    padding-top: 24px;
    border-top: 1px solid var(--color-footer-border);
    font-size: 13px;
    line-height: 1.5;
    color: var(--color-footer-muted);
}

.footer-bottom a:hover {
    color: var(--color-white);
}

/* FAQ (shared) */

.faq {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.faq__list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.faq__item {
    border-bottom: 1px solid var(--color-divider);
    padding-bottom: 16px;
}

.faq__question {
    display: flex;
    width: 100%;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    font-size: 20px;
    font-weight: 400;
    line-height: 1.5;
    text-align: left;
    color: var(--color-navy);
    transition: color var(--transition);
}

.faq__question:hover {
    color: var(--color-orange);
}

.faq__toggle {
    position: relative;
    flex-shrink: 0;
    width: 24px;
    height: 24px;
}

.faq__toggle-line {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 14px;
    height: 1.5px;
    background: var(--color-navy);
    border-radius: 1px;
    transition: transform 0.3s ease, opacity 0.25s ease;
}

.faq__toggle-line--h {
    transform: translate(-50%, -50%);
}

.faq__toggle-line--v {
    transform: translate(-50%, -50%) rotate(90deg);
}

.faq__item.is-open .faq__toggle-line--v {
    transform: translate(-50%, -50%) rotate(90deg) scaleX(0);
    opacity: 0;
}

.faq__answer {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.35s ease;
}

.faq__item.is-open .faq__answer {
    grid-template-rows: 1fr;
}

.faq__answer-inner {
    overflow: hidden;
    min-height: 0;
}

.faq__answer-inner p {
    padding-top: 16px;
    color: var(--color-muted);
    font-size: 16px;
    line-height: 1.5;
    opacity: 0;
    transform: translateY(-6px);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.faq__item.is-open .faq__answer-inner p {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.08s;
}

/* Forms (shared) */

.field-label {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.5;
    color: var(--color-navy);
}

.field {
    display: block;
    width: 100%;
    position: relative;
}

.field input,
.field select,
.field textarea {
    width: 100%;
    padding: 16px 20px;
    background: var(--color-white);
    border: 1px solid var(--color-border);
    border-radius: 0;
    outline: none;
    color: var(--color-navy);
    transition: border-color var(--transition);
}

.field input::placeholder,
.field textarea::placeholder {
    color: var(--color-muted);
}

.field select {
    appearance: none;
    color: var(--color-muted);
    padding-right: 48px;
}

.field select:valid,
.field select:focus {
    color: var(--color-navy);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    border-color: var(--color-navy);
}

.field__chevron {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
}

.field--textarea textarea {
    min-height: 112px;
    resize: vertical;
}

/* Book appointment modal */

.book-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.book-modal[hidden] {
    display: none;
}

.book-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(21, 32, 54, 0.55);
}

.book-modal__dialog {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 580px;
    max-height: calc(100vh - 48px);
    overflow: auto;
}

.book-modal__panel {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
    padding: 32px;
    background: var(--color-white);
}

.book-modal__panel[hidden] {
    display: none;
}

.book-modal__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    width: 100%;
}

.book-modal__title {
    margin: 0;
    flex: 1;
    font-size: 26px;
    font-weight: 400;
    line-height: 1.2;
    color: var(--color-navy);
}

.book-modal__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    transition: opacity var(--transition);
}

.book-modal__close:hover {
    opacity: 0.7;
}

.book-modal__close img {
    width: 24px;
    height: 24px;
}

.book-modal__lead {
    margin: 0;
    width: 100%;
    font-size: 16px;
    line-height: 1.5;
    color: var(--color-muted);
}

.book-modal__tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.book-modal__tab {
    display: inline-flex;
    padding: 12px 16px;
    border: 0;
    border-radius: 2px;
    background: #F5F5F5;
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.5;
    color: var(--color-navy);
    cursor: pointer;
    transition: background var(--transition), color var(--transition), border-radius var(--transition);
}

.book-modal__tab:not(.is-active):hover {
    background: var(--color-soft);
    color: var(--color-orange);
}

.book-modal__tab.is-active {
    border-radius: 12px;
    background: var(--color-orange);
    color: var(--color-white);
}

.book-modal__form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
}

.book-modal__form .field {
    width: 100%;
}

.book-modal__form .field input,
.book-modal__form .field select {
    padding: 16px;
    border: 1px solid var(--color-divider);
    border-radius: 2px;
    background: var(--color-white);
}

.book-modal__form .field select {
    padding-right: 44px;
}

.book-modal__form .field__chevron {
    right: 16px;
    width: 20px;
    height: 20px;
}

.book-modal__note {
    margin: 0;
    width: 100%;
    text-align: center;
    font-size: 13px;
    line-height: 1.5;
    color: var(--color-muted);
}

.book-modal__note a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.book-modal__submit {
    width: 100%;
    justify-content: flex-start;
}

.book-modal__submit img {
    width: 20px;
    height: 20px;
}

.book-modal__callback {
    margin: 0;
    width: 100%;
    font-size: 13px;
    line-height: 1.5;
    color: var(--color-muted);
}

body.is-book-modal-open {
    overflow: hidden;
}

.magicforms-flash {
    position: fixed;
    z-index: 1200;
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    width: min(420px, calc(100% - 2rem));
    pointer-events: none;
}

.magicforms-flash:empty {
    display: none;
}

.magicforms-flash .alert {
    pointer-events: auto;
    margin: 0;
    padding: 0.85rem 1rem;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.16);
    font-size: 14px;
    line-height: 1.45;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.08);
}

.magicforms-flash .alert-success {
    display: none;
}

.magicforms-flash .alert-danger,
.magicforms-flash .alert-error {
    border-color: rgba(220, 38, 38, 0.25);
    color: #991b1b;
    background: #fef2f2;
}

.magicforms-flash .alert .close {
    display: none;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}