/* ==========================================================================
   Esthetica – WordPress / Elementor integration layer
   (design system itself is in app.css, compiled from the original site)
   ========================================================================== */

body { background: #fffbf8; }
.skip-link { position: absolute; top: -40px; left: 0; background: #356574; color: #fff; padding: 8px 16px; z-index: 100; transition: top .3s; text-decoration: none; }
.skip-link:focus { top: 0; }
img { max-width: 100%; height: auto; }
[hidden] { display: none !important; }

/* --- Elementor wrappers around Esthetica sections: no gaps, no padding, full width --- */
.elementor-section.esth-sec { padding: 0 !important; margin: 0 !important; }
.elementor-section.esth-sec > .elementor-container { max-width: none !important; }
.elementor-section.esth-sec .elementor-column-gap-no > .elementor-column > .elementor-element-populated,
.elementor-section.esth-sec .elementor-widget-wrap,
.elementor-section.esth-sec .elementor-element-populated { padding: 0 !important; }
.elementor-section.esth-sec .elementor-widget:not(:last-child) { margin-bottom: 0 !important; }
.elementor .esth-sec .elementor-widget-container { margin: 0; padding: 0; }
[class*="elementor-widget-esth-"] { width: 100%; }
/* sticky sections (e.g. gallery filter bar) must stick relative to the page, not their wrapper */
.elementor-section.esth-sec:has(section.sticky) { position: sticky; top: 72px; z-index: 30; }
.elementor-section.esth-sec section.sticky { position: relative; top: auto; }
@media (max-width: 1023px) { .elementor-section.esth-sec:has(section.sticky) { top: 64px; } }

/* --- Scroll reveal (replaces framer-motion) --- */
[data-esth-r] { transition-property: opacity, transform; transition-duration: .7s; transition-timing-function: cubic-bezier(.2, .8, .2, 1); transition-delay: var(--esth-d, 0s); }
.esth-js [data-esth-r]:not(.esth-in) { opacity: 0; }
.esth-js [data-esth-r="up"]:not(.esth-in) { transform: translateY(24px); }
.esth-js [data-esth-r="down"]:not(.esth-in) { transform: translateY(-24px); }
.esth-js [data-esth-r="left"]:not(.esth-in) { transform: translateX(-30px); }
.esth-js [data-esth-r="right"]:not(.esth-in) { transform: translateX(30px); }
.esth-js [data-esth-r="scale"]:not(.esth-in) { transform: scale(.94); }
[data-esth-r="width"] { transition: width .8s cubic-bezier(.2, .8, .2, 1) var(--esth-d, 0s); }
.esth-js [data-esth-r="width"]:not(.esth-in) { width: 0 !important; opacity: 1; }
.elementor-editor-active [data-esth-r], [data-esth-noanim] [data-esth-r], [data-esth-noanim][data-esth-r] { opacity: 1 !important; transform: none !important; }
@media (prefers-reduced-motion: reduce) {
	[data-esth-r] { transition: none !important; }
	.esth-js [data-esth-r]:not(.esth-in) { opacity: 1; transform: none; }
}

/* --- Accordions --- */
[data-acc] { cursor: pointer; }
[data-acc] .lucide-chevron-down { transition: transform .3s ease; }
.esth-acc-open > [data-acc] .lucide-chevron-down { transform: rotate(180deg); }
[data-acc-panel] { transition: height .3s ease, opacity .3s ease; }

/* --- Tabs / slides --- */
[data-esth-tabs] > button { cursor: pointer; }
.esth-slide-in > * { animation: esthSlideIn .5s ease both; }
@keyframes esthSlideIn { from { opacity: 0; transform: translateX(40px); } to { opacity: 1; transform: none; } }
.esth-fade-in { animation: esthFade .45s ease both; }
@keyframes esthFade { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* --- Quiz --- */
[data-quiz-card].esth-q-anim { animation: esthQuiz .3s ease both; }
@keyframes esthQuiz { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: none; } }
[data-quiz-bar] { transition: width .3s ease; }
[data-quiz-opt] { transition: transform .2s ease, border-color .3s, background-color .3s; }
[data-quiz-opt]:hover { transform: scale(1.02); }
[data-quiz-opt]:active { transform: scale(.98); }

/* --- Forms --- */
.esth-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
form[data-esth-form] [type="submit"][disabled], form[data-esth-form] button[disabled] { opacity: .65; cursor: wait; }
.esth-form-msg { margin-top: .75rem; padding: .75rem 1rem; border-radius: .75rem; font-size: .875rem; }
.esth-form-msg.is-error { background: hsl(0 84% 60% / .1); color: hsl(0 72% 45%); }
.esth-form-msg.is-ok { background: hsl(194 37% 33% / .08); color: #356574; }

/* --- Header --- */
.esth-scrolled [data-esth-scrollshadow] { box-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1); }
[data-esth-mega-toggle][aria-expanded="true"] { color: #356574; }
[data-esth-mega-toggle] .lucide-chevron-down { transition: transform .2s; }
[data-esth-mega-toggle][aria-expanded="true"] .lucide-chevron-down,
[data-esth-sub-toggle][aria-expanded="true"] .lucide-chevron-down { transform: rotate(180deg); }
.esth-mega-panel { transform: translate(-50%, 8px); opacity: 0; transition: opacity .2s cubic-bezier(.2, .8, .2, 1), transform .2s cubic-bezier(.2, .8, .2, 1); }
.esth-mega-panel.esth-open { transform: translate(-50%, 0); opacity: 1; }
.esth-drawer { transform: translateX(100%); transition: transform .35s cubic-bezier(.22, 1, .36, 1); }
.esth-drawer.esth-open { transform: none; }
.esth-drawer-backdrop { opacity: 0; transition: opacity .25s; }
.esth-drawer-backdrop.esth-open { opacity: .4; }
body.esth-lock { overflow: hidden; }

/* --- Floating actions --- */
.esth-pop { animation: esthPop .45s cubic-bezier(.34, 1.56, .64, 1) both; }
.esth-pop:hover { transform: scale(1.1); }
@keyframes esthPop { from { opacity: 0; transform: translateX(-50px) scale(0); } to { opacity: 1; transform: none; } }
.esth-pulse { animation: esthPulse 1.5s ease-out infinite; }
@keyframes esthPulse { from { transform: scale(1); opacity: .5; } to { transform: scale(1.8); opacity: 0; } }

/* --- Reels / viewers --- */
.esth-reels-in { animation: esthReels .45s cubic-bezier(.22, 1, .36, 1) both; }
@keyframes esthReels { from { opacity: 0; transform: translateX(100px); } to { opacity: 1; transform: none; } }
.esth-modal-in { animation: esthFadeOnly .25s ease both; }
@keyframes esthFadeOnly { from { opacity: 0; } to { opacity: 1; } }
.scrollbar-none::-webkit-scrollbar, .scrollbar-hide::-webkit-scrollbar { display: none; }
.scrollbar-none, .scrollbar-hide { scrollbar-width: none; -ms-overflow-style: none; }

/* --- Blog content written in the block editor (imported articles carry their own classes) --- */
.prose-dental :where(h2:not([class]), h2.wp-block-heading) { font-family: var(--font-display); font-size: clamp(1.5rem, 2.5vw, 1.875rem); font-weight: 500; color: hsl(var(--foreground)); margin: 2.5rem 0 1rem; line-height: 1.25; }
.prose-dental :where(h3:not([class]), h3.wp-block-heading) { font-family: var(--font-display); font-size: 1.35rem; font-weight: 500; color: hsl(var(--foreground)); margin: 2rem 0 .75rem; }
.prose-dental :where(h4:not([class]), h4.wp-block-heading) { font-weight: 600; color: hsl(var(--foreground)); margin: 1.5rem 0 .5rem; }
.prose-dental :where(p:not([class]), p.has-text-align-left, p.has-text-align-center) { font-size: 17px; line-height: 1.75; color: hsl(var(--foreground) / .75); margin-bottom: 1.25rem; }
.prose-dental :where(ul:not([class]), ol:not([class]), ul.wp-block-list, ol.wp-block-list) { margin: 0 0 1.5rem 1.25rem; color: hsl(var(--foreground) / .75); line-height: 1.75; }
.prose-dental :where(ul:not([class]), ul.wp-block-list) { list-style: disc; }
.prose-dental :where(ol:not([class]), ol.wp-block-list) { list-style: decimal; }
.prose-dental :where(ul:not([class]), ol:not([class]), .wp-block-list) > :where(li) { margin-bottom: .4rem; }
.prose-dental :where(p:not([class]), li:not([class])) > :where(a:not([class])) { color: hsl(var(--primary)); text-decoration: underline; text-underline-offset: 3px; }
.prose-dental :where(blockquote:not([class]), .wp-block-quote) { border-left: 3px solid #E8A598; padding: .5rem 0 .5rem 1.25rem; margin: 1.5rem 0; font-style: italic; color: hsl(var(--foreground) / .8); }
.prose-dental :where(figure) > :where(img) { border-radius: 1.25rem; margin: 1.5rem 0; }
.prose-dental :where(table:not([class]), .wp-block-table table) { width: 100%; border-collapse: collapse; margin: 1.5rem 0; font-size: .95rem; }
.prose-dental :where(.wp-block-table, table:not([class])) :where(th, td) { border-bottom: 1px solid hsl(var(--foreground) / .08); padding: .65rem .75rem; text-align: left; }
.prose-dental :where(strong) { color: hsl(var(--foreground)); font-weight: 600; }
.prose-dental .alignwide, .prose-dental .alignfull { max-width: none; }

/* --- Pagination --- */
.esth-pagination .nav-links { display: flex; gap: .5rem; flex-wrap: wrap; justify-content: center; }
.esth-pagination .page-numbers { min-width: 2.5rem; height: 2.5rem; padding: 0 .75rem; display: inline-flex; align-items: center; justify-content: center; border-radius: 9999px; border: 1px solid hsl(var(--foreground) / .12); color: hsl(var(--foreground)); font-size: .9rem; }
.esth-pagination .page-numbers.current, .esth-pagination .page-numbers:hover { background: #356574; color: #fff; border-color: #356574; }
.screen-reader-text { border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute !important; width: 1px; word-wrap: normal !important; }

/* --- Comments --- */
#comments .comment-body { background: #fff; border-radius: 1rem; padding: 1.25rem; box-shadow: var(--shadow-card); }
#comments input[type=text], #comments input[type=email], #comments input[type=url], #comments textarea { width: 100%; padding: .75rem 1rem; border-radius: .75rem; border: 1px solid hsl(var(--foreground) / .12); background: #fff; }
#comments .submit { background: #356574; color: #fff; padding: .75rem 1.75rem; border-radius: 9999px; font-weight: 500; margin-top: 1rem; }
