/*
 * 고객지원 mega layout for the live header (15388) and the private draft (21975).
 * Colours, type and spacing stay in the Elementor document. These selectors only
 * hold layout the controls cannot express (gutter, dividers, decorative icon).
 */

/* Same gutter rule as the Product panel: the panel is a descendant of the header's
 * right group, so it reads that group's own Elementor padding-right. */
:is(.elementor-15388, .elementor-21975) .elementor-element-4c49c403 {
	--ednc-gutter: var(--padding-right);
}

@media (min-width: 1025px) {
	:is(.elementor-15388, .elementor-21975) .ednc-csmega-widget .e-n-menu-content > .ednc-csmega.e-con {
		width: 100%;
		max-width: none;
		margin-inline: 0;
		padding-inline-start: calc(var(--ednc-gutter) - var(--ednc-col-pad));
		padding-inline-end: calc(var(--ednc-gutter) - var(--ednc-col-pad));
		box-sizing: border-box;
	}
}

/* One shared surface, thin dividers. */
:is(.elementor-15388, .elementor-21975) .ednc-csmega.e-con {
	border-top-color: rgba(255, 255, 255, 0.1) !important;
}

:is(.elementor-15388, .elementor-21975) .ednc-csmega-col.e-con + .ednc-csmega-col.e-con {
	box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.1) !important;
}

/* Contact card: no red side bar; the red lives in the CTA only. */
:is(.elementor-15388, .elementor-21975) .ednc-csmega-card--contact.e-con {
	box-shadow: none !important;
}

/* Cards: height follows content, equalised per breakpoint below. */
:is(.elementor-15388, .elementor-21975) .ednc-csmega-card.e-con {
	height: auto !important;
	max-height: none !important;
	min-height: var(--ednc-cs-card-h, 208px) !important;
}

/* Equal card height across the 4 columns: the tallest natural card at each
 * width band (measured 1025–1920) plus a small margin. Only this header. */
:is(.elementor-15388, .elementor-21975) .ednc-csmega { --ednc-cs-card-h: 208px; }                   /* ≥1500: tallest 201 */
@media (max-width: 1499px) { :is(.elementor-15388, .elementor-21975) .ednc-csmega { --ednc-cs-card-h: 224px; } } /* tallest 222 */
@media (max-width: 1264px) { :is(.elementor-15388, .elementor-21975) .ednc-csmega { --ednc-cs-card-h: 248px; } } /* tallest 247 */
@media (max-width: 1129px) { :is(.elementor-15388, .elementor-21975) .ednc-csmega { --ednc-cs-card-h: 272px; } } /* tallest 272 */
@media (max-width: 1024px) { :is(.elementor-15388, .elementor-21975) .ednc-csmega { --ednc-cs-card-h: 208px; } } /* tablet 2-col: tallest 201 */
@media (max-width: 799px)  { :is(.elementor-15388, .elementor-21975) .ednc-csmega { --ednc-cs-card-h: 224px; } } /* tallest 222 */
@media (max-width: 767px)  { :is(.elementor-15388, .elementor-21975) .ednc-csmega { --ednc-cs-card-h: 0px; } }   /* mobile accordion: content height */

/* Tablet 2-col: only the right-hand column of each row carries the divider. */
@media (max-width: 1024px) {
	:is(.elementor-15388, .elementor-21975) .ednc-csmega-col.e-con:nth-child(odd) {
		box-shadow: none !important;
	}
}

/* Decorative line icon, top-right, behind the copy. */
:is(.elementor-15388, .elementor-21975) .ednc-csmega-card.e-con > .ednc-csmega-deco {
	position: absolute !important;
	left: auto !important; /* Elementor also prints the default left offset; only the right one applies */
	width: auto !important;
	z-index: 1 !important;
	pointer-events: none;
	line-height: 0;
}

/* Narrower columns: smaller deco so it stays clear of the card title; gone at 1366 and below. */
@media (max-width: 1499px) {
	:is(.elementor-15388, .elementor-21975) .ednc-csmega-card.e-con > .ednc-csmega-deco .elementor-icon {
		font-size: 48px !important;
	}
	:is(.elementor-15388, .elementor-21975) .ednc-csmega-card.e-con > .ednc-csmega-deco .elementor-icon svg {
		height: 48px !important;
	}
}

@media (max-width: 1366px) {
	:is(.elementor-15388, .elementor-21975) .ednc-csmega-card.e-con > .ednc-csmega-deco {
		display: none !important;
	}
}

:is(.elementor-15388, .elementor-21975) .ednc-csmega-cat .elementor-icon-list-items,
:is(.elementor-15388, .elementor-21975) .ednc-csmega-cat .elementor-icon-list-item {
	margin: 0;
	padding: 0;
}

/* Arrows use the EDNC red. */
:is(.elementor-15388, .elementor-21975) .ednc-csmega-more a::after,
:is(.elementor-15388, .elementor-21975) .ednc-csmega-item a::after {
	color: #c81020;
}

:is(.elementor-15388, .elementor-21975) .ednc-csmega a:focus-visible,
:is(.elementor-15388, .elementor-21975) .ednc-csmega [tabindex="0"]:focus-visible {
	outline-color: #ffffff;
}

/* Buttons: Elementor controls carry colour/padding; keep them on one line and one height. */
:is(.elementor-15388, .elementor-21975) .ednc-csmega-btn .elementor-button {
	min-height: 36px;
	white-space: nowrap;
}

@media (max-width: 767px) {
	:is(.elementor-15388, .elementor-21975) .ednc-csmega-col.e-con + .ednc-csmega-col.e-con {
		border-top-color: rgba(255, 255, 255, 0.1);
		box-shadow: none !important;
	}

	/* Accordion rows: the title is the tap target; even 18px above and below,
	 * the 22px title->card gap only when the row is open. */
	:is(.elementor-15388, .elementor-21975) .ednc-csmega-col.e-con {
		--padding-top: 18px !important;
		--padding-bottom: 18px !important;
		--padding-left: 12px !important;
		--padding-right: 12px !important;
	}

	/* Stacked rows touch; the 1px top border is the only separator. */
	:is(.elementor-15388, .elementor-21975) .ednc-csmega-grid.e-con {
		row-gap: 0 !important;
	}

	:is(.elementor-15388, .elementor-21975) .ednc-csmega-col.e-con:not(.is-open) > .ednc-csmega-cat {
		margin-bottom: 0 !important;
	}

	:is(.elementor-15388, .elementor-21975) .ednc-csmega-col.is-open.e-con {
		--padding-bottom: 28px !important;
	}

	:is(.elementor-15388, .elementor-21975) .ednc-csmega-cat {
		position: relative;
		cursor: pointer;
	}

	/* Chevron on the right; rotates when open. */
	:is(.elementor-15388, .elementor-21975) .ednc-csmega-cat::after {
		content: "";
		position: absolute;
		top: 50%;
		right: 4px;
		width: 9px;
		height: 9px;
		border-right: 2px solid #c9d1d6;
		border-bottom: 2px solid #c9d1d6;
		transform: translateY(-70%) rotate(45deg);
		transition: transform 0.2s ease;
	}

	:is(.elementor-15388, .elementor-21975) .ednc-csmega-col.is-open > .ednc-csmega-cat::after {
		transform: translateY(-30%) rotate(-135deg);
	}
}

/* Spacing is set per widget in Elementor (Advanced > Margin); the theme's paragraph
 * margin would add a second, invisible gap on top of it. */
:is(.elementor-15388, .elementor-21975) .ednc-csmega .elementor-widget-text-editor p {
	margin: 0;
}

/* "자세히 보기 →": arrow sits on the text line, same size as the label. */
:is(.elementor-15388, .elementor-21975) .ednc-csmega-more a::after {
	font: inherit;
	line-height: 1;
}
