/* ==========================================================================
   OCEES - "Selective global engagement"
   --------------------------------------------------------------------------
   Reference: otecorporation-ocees/app/globals.css
              .global .region-grid .global-note
              app/page.tsx  <section className="global section-pad">

   Elementor: Home page, tenth container - "Global"

   Structure - the same DOM the React build has:
     section.ocees-global.ocees-section.e-con
       |- .ocees-label            Heading (p)
       |- .ocees-global__title    Heading (h2)
       |- .ocees-regions.e-con        four hairline cells
       |    `- .ocees-region.e-con  x4
       |         |- .ocees-region__name    Heading (span)
       |         `- .ocees-region__places  Text Editor
       `- .ocees-global__note     Text Editor  (right-aligned, 760px)

   The cells use the same no-double-border trick as the other grids: top +
   left on the container, right + bottom on every cell.
   ========================================================================== */

:root {
	--ocees-global-rule: #50717c;
	--ocees-region-min-h: 180px;
	--ocees-region-pad: 25px;
	--ocees-region-name-fg: #56d4da;
	--ocees-region-places-fg: #d2e3e5;
	--ocees-global-note-fg: #a6bec4;
	--ocees-global-note-max: 760px;
}

/* --------------------------------------------------------------------------
   1. Section
   The band colour is set on the container in Elementor (Style > Background);
   the white text colour is set here, since containers have no colour control.
   -------------------------------------------------------------------------- */

.ocees-global.e-con {
	display: flex;
	flex-direction: column;
	gap: 0;
	width: 100%;
	max-width: none;
	color: #fff;
}

/* The blocks are spaced by their own margins, as in the reference. */
.ocees-global > .elementor-widget:not(:last-child) {
	margin-block-end: 0;
}

.ocees-global__title .elementor-heading-title {
	margin: 24px 0 75px;
	max-width: 1150px;
	color: inherit;
	font-family: var(--ocees-font-sans);
	font-size: clamp(3.2rem, 6.2vw, 7rem);
	font-weight: 500;
	line-height: 0.91;
	letter-spacing: -0.067em;
}

/* --------------------------------------------------------------------------
   2. Region grid
   -------------------------------------------------------------------------- */

.ocees-regions.e-con {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 0;
	width: 100%;
	max-width: none;
	padding: 0;
	border-top: 1px solid var(--ocees-global-rule);
	border-left: 1px solid var(--ocees-global-rule);
}

.ocees-region.e-con {
	display: flex;
	flex-direction: column;
	gap: 0;
	width: 100%;
	max-width: none;
	min-height: var(--ocees-region-min-h);
	padding: var(--ocees-region-pad);
	border-right: 1px solid var(--ocees-global-rule);
	border-bottom: 1px solid var(--ocees-global-rule);
}

.ocees-region__name .elementor-heading-title {
	display: block;
	margin: 0 0 54px;
	color: var(--ocees-region-name-fg);
	font-family: var(--ocees-font-sans);
	font-size: 0.64rem;
	font-weight: 700;
	line-height: 1.5;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.ocees-region__places p {
	margin: 0;
	color: var(--ocees-region-places-fg);
	font-family: var(--ocees-font-sans);
	font-size: 1.05rem;
	line-height: 1.55;
}

/* --------------------------------------------------------------------------
   3. Closing note
   React: `max-width: 760px` with `margin: 54px 0 0 auto`, which parks it at
   the right-hand edge of the section. Both sit on the paragraph rather than
   the widget - Elementor drives a container child's own max-width and margin
   at a specificity this stylesheet cannot match, and the paragraph inside has
   no competing rule.
   -------------------------------------------------------------------------- */

.ocees-global__note p {
	max-width: var(--ocees-global-note-max);
	margin: 54px 0 0 auto;
	color: var(--ocees-global-note-fg);
	font-family: var(--ocees-font-sans);
	font-size: 1rem;
	line-height: 1.7;
}

/* --------------------------------------------------------------------------
   4. Responsive
   -------------------------------------------------------------------------- */

/* Tablet and below - matches the React `@media (max-width: 980px)` block. */
@media (max-width: 980px) {
	.ocees-regions.e-con {
		grid-template-columns: repeat(2, 1fr);
	}
}

/* Phones - matches the React `@media (max-width: 620px)` block. */
@media (max-width: 620px) {
	.ocees-regions.e-con {
		grid-template-columns: 1fr;
	}
}
