/**
 * Emerald Dance Academy — Redesign Design System
 *
 * Tokens and shared component styles ported from the Figma redesign
 * (app/redesign/src/styles/theme.css + component classes).
 * Loaded site-wide by astra-child/functions.php.
 */

/* ════════════════════════════════════════════════════════
   1. DESIGN TOKENS
   ════════════════════════════════════════════════════════ */
:root {
	/* Brand */
	--eda-primary: #10b981;
	--eda-primary-dark: #059669;
	--eda-primary-darker: #047857;
	--eda-primary-light: #34d399;
	--eda-mint: #6ee7b7;
	--eda-mint-pale: #a7f3d0;
	--eda-deep-green: #064e3b;
	--eda-deep-green-mid: #065f46;
	--eda-hero-dark: #0a1f16;
	--eda-gold: #fbbf24;
	--eda-cream: #fef3c7;
	--eda-amber: #f59e0b;

	/* Neutrals */
	--eda-ink: #0a0a0a;
	--eda-paper: #fafaf8;
	--eda-gray-700: #374151;
	--eda-gray-500: #717182;
	--eda-border: #e5e7eb;

	/* Class category accents */
	--eda-cat-ballet: #f472b6;
	--eda-cat-hiphop: #fbbf24;
	--eda-cat-jazz: #fb923c;
	--eda-cat-lyrical: #c084fc;
	--eda-cat-creative: #f0abfc;
	--eda-cat-summer: #34d399;

	/* Typography */
	--eda-font-display: 'Playfair Display', Georgia, serif;
	--eda-font-ui: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
	--eda-font-elegant: 'Cormorant Garamond', Georgia, serif;

	/* Radii */
	--eda-radius: 10px;
	--eda-radius-lg: 16px;
	--eda-radius-xl: 24px;
	--eda-radius-pill: 999px;

	/* Shadows */
	--eda-shadow-card: 0 1px 2px rgba(0, 0, 0, 0.05);
	--eda-shadow-card-hover: 0 20px 25px -5px rgba(229, 231, 235, 0.5), 0 8px 10px -6px rgba(229, 231, 235, 0.5);
	--eda-shadow-cta: 0 10px 15px -3px rgba(16, 185, 129, 0.2), 0 4px 6px -4px rgba(16, 185, 129, 0.2);
	--eda-shadow-header: 0 1px 3px rgba(0, 0, 0, 0.05), 0 8px 30px rgba(0, 0, 0, 0.04);
	--eda-shadow-modal: 0 25px 50px -12px rgba(0, 0, 0, 0.25);

	/* Gradients */
	--eda-gradient-brand: linear-gradient(90deg, #059669 0%, #10b981 50%, #34d399 100%);
	--eda-gradient-deep: linear-gradient(135deg, #064e3b 0%, #065f46 100%);
	--eda-gradient-hero: linear-gradient(180deg, rgba(6, 78, 59, 0.55) 0%, rgba(10, 31, 22, 0.85) 100%);

	/* Layout */
	--eda-header-height: 70px;
}

@media (min-width: 1025px) {
	:root {
		--eda-header-height: 76px;
	}
}

/* ════════════════════════════════════════════════════════
   2. BASE
   ════════════════════════════════════════════════════════ */
body {
	font-family: var(--eda-font-ui);
	background-color: #ffffff;
	color: var(--eda-gray-700);
	-webkit-font-smoothing: antialiased;
}

::selection {
	background: var(--eda-primary);
	color: #ffffff;
}

h1, h2, h3, h4, h5,
.eda-display {
	font-family: var(--eda-font-display);
	color: var(--eda-ink);
}

/* ════════════════════════════════════════════════════════
   3. SHARED UTILITIES (used inside Elementor templates)
   ════════════════════════════════════════════════════════ */
.eda-section-label {
	font-family: var(--eda-font-ui);
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: var(--eda-primary-dark);
}

.eda-elegant {
	font-family: var(--eda-font-elegant);
	font-size: 1.375rem;
	line-height: 1.5;
	color: var(--eda-gray-500);
}

.eda-gradient-text {
	background: var(--eda-gradient-brand);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	color: transparent;
}

.eda-accent-line {
	display: inline-block;
	width: 64px;
	height: 3px;
	border-radius: 999px;
	background: var(--eda-gradient-brand);
}

/* Cards */
.eda-card {
	background: #ffffff;
	border: 1px solid var(--eda-border);
	border-radius: var(--eda-radius-lg);
	box-shadow: var(--eda-shadow-card);
	transition: box-shadow 0.3s ease, transform 0.3s ease, border-color 0.3s ease;
	overflow: hidden;
}

.eda-card:hover {
	box-shadow: var(--eda-shadow-card-hover);
	transform: translateY(-4px);
	border-color: rgba(16, 185, 129, 0.25);
}

.eda-card--xl {
	border-radius: var(--eda-radius-xl);
}

/* Pills / badges */
.eda-pill {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 14px;
	border-radius: var(--eda-radius-pill);
	font-family: var(--eda-font-ui);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.eda-pill--emerald {
	background: rgba(16, 185, 129, 0.1);
	color: var(--eda-primary-dark);
}

.eda-pill--gold {
	background: var(--eda-cream);
	color: #92400e;
}

.eda-pill--dark {
	background: rgba(255, 255, 255, 0.1);
	color: #ffffff;
	backdrop-filter: blur(8px);
}

/* Category badges (color set inline or via category class) */
.eda-cat-badge {
	display: inline-block;
	padding: 5px 12px;
	border-radius: var(--eda-radius-pill);
	font-family: var(--eda-font-ui);
	font-size: 10.5px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--eda-ink);
	background: var(--eda-cat-color, var(--eda-mint-pale));
}

.eda-cat-badge--ballet { --eda-cat-color: var(--eda-cat-ballet); color: #fff; }
.eda-cat-badge--hip-hop { --eda-cat-color: var(--eda-cat-hiphop); }
.eda-cat-badge--jazz { --eda-cat-color: var(--eda-cat-jazz); color: #fff; }
.eda-cat-badge--lyrical { --eda-cat-color: var(--eda-cat-lyrical); color: #fff; }
.eda-cat-badge--creative-movement { --eda-cat-color: var(--eda-cat-creative); }
.eda-cat-badge--summer { --eda-cat-color: var(--eda-cat-summer); }
.eda-cat-badge--tap { --eda-cat-color: var(--eda-mint); }
.eda-cat-badge--kinder-dance { --eda-cat-color: var(--eda-cream); }

/* Dark sections */
.eda-section-dark {
	background-color: var(--eda-hero-dark);
}

.eda-section-dark h1,
.eda-section-dark h2,
.eda-section-dark h3,
.eda-section-dark h4 {
	color: #ffffff;
}

.eda-section-dark .eda-section-label {
	color: var(--eda-mint);
}

.eda-section-paper {
	background-color: var(--eda-paper);
}

/* ════════════════════════════════════════════════════════
   4. BUTTONS (Astra/Woo parity with Elementor kit)
   ════════════════════════════════════════════════════════ */
.ast-button,
.button,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit,
.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce input.button.alt,
.wc-block-components-button,
body .wpforms-form button[type="submit"] {
	font-family: var(--eda-font-ui) !important;
	font-size: 13px !important;
	font-weight: 600 !important;
	letter-spacing: 0.1em !important;
	text-transform: uppercase !important;
	color: #ffffff !important;
	background: var(--eda-primary-dark) !important;
	border: none !important;
	border-radius: var(--eda-radius-pill) !important;
	padding: 14px 30px !important;
	transition: background 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease !important;
	box-shadow: none;
}

.ast-button:hover,
.button:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce #respond input#submit:hover,
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover,
.woocommerce input.button.alt:hover,
.wc-block-components-button:hover,
body .wpforms-form button[type="submit"]:hover {
	background: var(--eda-primary-darker) !important;
	box-shadow: var(--eda-shadow-cta) !important;
	transform: translateY(-1px);
}

/* Secondary / outline button helper */
.eda-btn-outline .elementor-button,
.eda-btn-outline.elementor-button {
	background: transparent !important;
	color: var(--eda-primary-dark) !important;
	border: 1.5px solid var(--eda-primary-dark) !important;
}

.eda-btn-outline .elementor-button:hover,
.eda-btn-outline.elementor-button:hover {
	background: var(--eda-primary-dark) !important;
	color: #ffffff !important;
}

/* White ghost button for dark/hero sections */
.eda-btn-ghost .elementor-button,
.eda-btn-ghost.elementor-button {
	background: rgba(255, 255, 255, 0.1) !important;
	color: #ffffff !important;
	border: 1.5px solid rgba(255, 255, 255, 0.35) !important;
	backdrop-filter: blur(8px);
}

.eda-btn-ghost .elementor-button:hover,
.eda-btn-ghost.elementor-button:hover {
	background: rgba(255, 255, 255, 0.2) !important;
	border-color: rgba(255, 255, 255, 0.6) !important;
}

/* Gold CTA */
.eda-btn-gold .elementor-button,
.eda-btn-gold.elementor-button {
	background: var(--eda-gold) !important;
	color: var(--eda-ink) !important;
}

.eda-btn-gold .elementor-button:hover,
.eda-btn-gold.elementor-button:hover {
	background: #f59e0b !important;
}

/* ════════════════════════════════════════════════════════
   5. FORMS
   ════════════════════════════════════════════════════════ */
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
body .wpforms-form input[type="text"],
body .wpforms-form input[type="email"],
body .wpforms-form input[type="tel"],
body .wpforms-form textarea,
body .wpforms-form select {
	font-family: var(--eda-font-ui);
	background: #ffffff;
	border: 1px solid var(--eda-border);
	border-radius: 12px;
	padding: 12px 16px;
	color: var(--eda-ink);
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus,
body .wpforms-form input:focus,
body .wpforms-form textarea:focus {
	border-color: var(--eda-primary);
	box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
	outline: none;
}

/* ════════════════════════════════════════════════════════
   6. WOOCOMMERCE POLISH
   ════════════════════════════════════════════════════════ */
.woocommerce span.onsale {
	background: var(--eda-gold);
	color: var(--eda-ink);
	border-radius: var(--eda-radius-pill);
	font-family: var(--eda-font-ui);
	font-weight: 700;
	font-size: 11px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	padding: 6px 14px;
	line-height: 1.4;
	min-width: 0;
	min-height: 0;
}

.woocommerce .price,
.woocommerce div.product p.price,
.woocommerce ul.products li.product .price {
	color: var(--eda-primary-dark);
	font-family: var(--eda-font-ui);
	font-weight: 700;
}

.woocommerce ul.products li.product {
	background: #ffffff;
	border: 1px solid var(--eda-border);
	border-radius: var(--eda-radius-lg);
	box-shadow: var(--eda-shadow-card);
	overflow: hidden;
	transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.woocommerce ul.products li.product:hover {
	box-shadow: var(--eda-shadow-card-hover);
	transform: translateY(-4px);
}

.woocommerce ul.products li.product .woocommerce-loop-product__title {
	font-family: var(--eda-font-display);
	font-size: 1.125rem;
	color: var(--eda-ink);
	padding: 12px 16px 4px;
}

.woocommerce ul.products li.product .price,
.woocommerce ul.products li.product .button {
	margin-left: 16px;
	margin-right: 16px;
}

.woocommerce ul.products li.product .button {
	margin-bottom: 16px;
}

/* Quantity inputs */
.woocommerce .quantity .qty {
	border: 1px solid var(--eda-border);
	border-radius: 10px;
	padding: 8px;
	font-family: var(--eda-font-ui);
}

/* Notices */
.woocommerce-message,
.woocommerce-info {
	border-top-color: var(--eda-primary);
	background: #ecfdf5;
	color: var(--eda-deep-green);
	border-radius: 12px;
}

.woocommerce-message::before,
.woocommerce-info::before {
	color: var(--eda-primary);
}

/* Checkout & cart tables */
.woocommerce table.shop_table {
	border: 1px solid var(--eda-border);
	border-radius: var(--eda-radius-lg);
	overflow: hidden;
}

.woocommerce table.shop_table th {
	font-family: var(--eda-font-ui);
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--eda-gray-500);
	background: var(--eda-paper);
}

/* Steps indicator look for checkout */
.woocommerce-checkout h3,
.woocommerce-billing-fields h3 {
	font-family: var(--eda-font-display);
	color: var(--eda-ink);
}

/* ════════════════════════════════════════════════════════
   7. SCROLLBAR + MISC
   ════════════════════════════════════════════════════════ */
.eda-scrollbar-none {
	-ms-overflow-style: none;
	scrollbar-width: none;
}

.eda-scrollbar-none::-webkit-scrollbar {
	display: none;
}

.eda-backdrop-blur {
	backdrop-filter: blur(24px);
	-webkit-backdrop-filter: blur(24px);
}

@keyframes eda-shimmer {
	0% { background-position: -200% center; }
	100% { background-position: 200% center; }
}

.eda-shimmer {
	background: linear-gradient(110deg, rgba(255, 255, 255, 0) 40%, rgba(255, 255, 255, 0.18) 50%, rgba(255, 255, 255, 0) 60%);
	background-size: 200% 100%;
	animation: eda-shimmer 3.5s linear infinite;
}

@keyframes eda-fade-up {
	from { opacity: 0; transform: translateY(24px); }
	to { opacity: 1; transform: translateY(0); }
}

.eda-fade-up {
	animation: eda-fade-up 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@media (prefers-reduced-motion: reduce) {
	.eda-fade-up,
	.eda-shimmer {
		animation: none;
	}
}

/* ════════════════════════════════════════════════════════
   7b. FORM CONTRAST INSURANCE — entered text must always be
   crisp ink-on-white (or white-on-dark in the dark finder)
   ════════════════════════════════════════════════════════ */
body input[type="text"],
body input[type="email"],
body input[type="tel"],
body input[type="number"],
body input[type="search"],
body input[type="password"],
body input[type="url"],
body textarea,
body select,
body .elementor-field-group .elementor-field,
body .elementor-popup-modal .elementor-field {
	color: var(--eda-ink);
}

body ::placeholder {
	color: #9ca3af;
	opacity: 1;
}

body select option {
	color: var(--eda-ink);
	background: #ffffff;
}

/* Exception: fields on the dark footer (newsletter) stay white-on-dark */
body [data-elementor-type="footer"] .elementor-field-group .elementor-field {
	color: #ffffff;
	background-color: rgba(255, 255, 255, 0.08);
}

body [data-elementor-type="footer"] ::placeholder {
	color: rgba(255, 255, 255, 0.4);
}

/* Visible keyboard focus for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
	outline: 2px solid var(--eda-primary);
	outline-offset: 2px;
	border-radius: 4px;
}

/* Autofill: keep dark text on white, never the browser's yellow */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
	-webkit-text-fill-color: var(--eda-ink);
	-webkit-box-shadow: 0 0 0 1000px #ffffff inset;
	transition: background-color 9999s ease-in-out 0s;
}

.eda-wizard__panel--dark input:-webkit-autofill,
.eda-wizard__panel--dark input:-webkit-autofill:focus {
	-webkit-text-fill-color: rgba(255, 255, 255, 0.92);
	-webkit-box-shadow: 0 0 0 1000px #0d2b1f inset;
}

.eda-wizard__panel--dark ::placeholder {
	color: rgba(255, 255, 255, 0.3);
}

/* ════════════════════════════════════════════════════════
   7c. ELEMENTOR POPUP / FORM POLISH
   ════════════════════════════════════════════════════════ */
.elementor-popup-modal .dialog-close-button {
	background: #f9fafb !important;
	border-radius: 999px;
	width: 36px;
	height: 36px;
	display: flex !important;
	align-items: center;
	justify-content: center;
	transition: background 0.2s ease;
}

.elementor-popup-modal .dialog-close-button:hover {
	background: #f3f4f6 !important;
}

.elementor-popup-modal .dialog-close-button i,
.elementor-popup-modal .dialog-close-button svg {
	color: #9ca3af !important;
	fill: #9ca3af !important;
	font-size: 14px;
}

/* Multi-step form indicators: emerald, not Elementor blue */
body .elementor-form {
	--e-form-steps-indicator-progress-color: #059669;
	--e-form-steps-indicator-progress-background-color: #e5e7eb;
	--e-form-steps-indicator-progress-meter-color: #059669;
	--e-form-steps-indicators-icon-color: #9ca3af;
	--e-form-steps-indicators-label-color: #9ca3af;
	--e-form-steps-indicators-icon-active-color: #059669;
	--e-form-steps-indicators-label-active-color: #059669;
	--e-form-steps-indicators-icon-completed-color: #059669;
	--e-form-steps-indicators-label-completed-color: #059669;
	--e-form-steps-divider-color: #e5e7eb;
}

body .elementor-form .e-form__indicators__indicator__progress__meter {
	background-color: #059669;
}

body .elementor-form .e-form__buttons__wrapper__button-previous {
	background: transparent !important;
	color: #374151 !important;
	border: 1.5px solid #d1d5db !important;
	box-shadow: none !important;
}

body .elementor-form .e-form__buttons__wrapper__button-previous:hover {
	border-color: var(--eda-primary-dark) !important;
	color: var(--eda-primary-dark) !important;
}

/* Form validation + messages */
body .elementor-message.elementor-message-success {
	color: var(--eda-primary-dark);
	font-family: var(--eda-font-ui);
}

body .elementor-message.elementor-message-danger {
	font-family: var(--eda-font-ui);
}

/* Accordion polish (help popup, FAQs) */
.elementor-accordion .elementor-accordion-item {
	border-radius: 12px;
	overflow: hidden;
	margin-bottom: 8px;
	border: 1px solid var(--eda-border) !important;
}

.elementor-accordion .elementor-tab-title {
	padding: 14px 16px;
}

.elementor-accordion .elementor-tab-content {
	border-top: 1px solid #f3f4f6 !important;
}

/* ════════════════════════════════════════════════════════
   8. FOOTER HELPERS
   ════════════════════════════════════════════════════════ */
.eda-footer-topline {
	position: relative;
}

.eda-footer-topline::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 2px;
	background: linear-gradient(90deg, transparent 0%, var(--eda-primary) 50%, transparent 100%);
}

.eda-footer-divider {
	border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.eda-gradient-text-mint {
	background: linear-gradient(90deg, #34d399, #6ee7b7);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	color: transparent;
}
