/*
Theme Name:     CSPBallet v2
Theme URI:      https://knowhalim.com
Template:       kadence
Author:         Knowhalim
Author URI:     https://knowhalim.com
Description:    CSP Ballet — a Kadence child theme for a Royal Academy of Dance ballet school in Yishun, Singapore. Version 2 carries the design in Kadence's own settings — global typography, palette, footer options and per-block attributes — so this stylesheet is only the handful of rules Kadence cannot express. Includes a one-click content importer.
Version:        2.0.0
License:        GNU General Public License v3.0 (or later)
License URI:    https://www.gnu.org/licenses/gpl-3.0.html
Text Domain:    cspballet
*/

/* ==========================================================================
   This file is deliberately short.
   ==========================================================================

   Everything that CAN be a Kadence setting IS one, and lives somewhere the
   client can edit it:

     Typography, colours, spacing per block  →  block attributes
                                                (inc/class-cspballet-blocks.php,
                                                 the presets() array)
     Site-wide fonts, headings, palette      →  Kadence theme options
                                                (functions.php)
     Footer layout, colours, widget type     →  Kadence footer options
                                                (inc/class-cspballet-footer.php)
     Section layout and responsive collapse  →  kadence/rowlayout columns

   What is left below is the residue: four things Kadence has no setting for.
   Each one is explained. If a future Kadence release adds a control for any
   of them, delete the rule and set the attribute instead.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Draft markers.

   {tbc}…{/tbc} in inc/csp-content.php becomes this span. It underlines a
   phrase *inside* a sentence — "class length: <u>to confirm</u>" — and no
   block-level setting reaches inside a run of text. Delete this rule once
   every outstanding detail has come back from Miss Chew and the markers are
   gone from the content file.
   -------------------------------------------------------------------------- */

.csp-tbc {
	border-bottom: 1px dotted #B79098;
}

/* --------------------------------------------------------------------------
   2. Tick markers on the class-level bullet lists.

   core/list has no icon support. Kadence's own kadence/iconlist does, but its
   saved markup embeds Kadence's icon SVG inline, which an importer cannot
   generate reliably across plugin versions — so the bullets are a plain core
   list and the tick is drawn here.

   To make this fully native instead: rebuild those lists by hand once, using
   Kadence's Icon List block with the check icon, and delete this rule.
   -------------------------------------------------------------------------- */

.csp-ticks {
	list-style: none;
	padding-left: 0;
}

.csp-ticks li {
	position: relative;
	padding-left: 2rem;
	margin-bottom: 1rem;
}

.csp-ticks li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0.7em;
	width: 0.85rem;
	height: 0.42rem;
	border-left: 2px solid #7D8FA6;
	border-bottom: 2px solid #7D8FA6;
	transform: rotate(-45deg);
}

/* --------------------------------------------------------------------------
   3. WordPress's own block gap.

   WordPress core puts margin-block-start: var(--wp--style--block-gap) on every
   direct child of .wp-site-blocks. On a page built from full-bleed rows that
   24px shows as a stripe above the hero and between sections. This is a core
   behaviour, not a Kadence one, so there is no Kadence setting for it.
   -------------------------------------------------------------------------- */

.wp-site-blocks > * + *,
.entry-content > * + * {
	margin-block-start: 0;
}

.site-main .entry-content {
	margin-top: 0;
}

/* --------------------------------------------------------------------------
   4. Footer widget-title letter-spacing.

   Customizer → Footer → Middle Row exposes the widget title's size, weight,
   family and colour, but not letter-spacing or text-transform. The titles are
   typed in capitals in the widget itself; only the tracking needs this rule.
   -------------------------------------------------------------------------- */

.site-middle-footer-inner-wrap .widget-title {
	letter-spacing: 0.28em;
}

/* --------------------------------------------------------------------------
   5. Centred-logo header: true mathematical centring.

   Kadence's 5-zone header row (left / left-center / center / right-center /
   right) sizes each zone to its own content by default, so a centre zone
   only sits at the visual midpoint when the left and right sides carry equal
   width. Our split nav doesn't (different item-label lengths), so without
   this the logo drifts off-centre. Forcing matching flex-basis on the two
   zone-pairs either side of centre is the one thing the customizer has no
   control for — hence a stylesheet rule instead of a theme option.

   (Nav type size is set natively via primary_navigation_typography /
   secondary_navigation_typography in class-cspballet-header.php — no CSS
   override needed for that anymore.)

   Desktop/tablet only: below that the header collapses to the hamburger
   drawer, where this split doesn't apply.
   -------------------------------------------------------------------------- */

@media (min-width: 1025px) {
	.site-header-main-section-left,
	.site-header-main-section-right {
		flex: 1 1 0;
		min-width: 0;
	}
	.site-header-main-section-left-center,
	.site-header-main-section-right-center {
		flex: 3 1 0;
		min-width: 0;
	}
	.site-header-main-section-left-center {
		justify-content: flex-end;
	}
	.site-header-main-section-right-center {
		justify-content: flex-start;
	}
	.site-header-main-section-center {
		flex: 0 0 auto;
	}
}

/* --------------------------------------------------------------------------
   6. The contact form (inc/class-cspballet-contact-form.php).

   A plain server-rendered <form>, not a Kadence block, so its styling is
   plain CSS too — kadence/form turned out not to be reconstructable from
   hand-authored attributes (see the docblock on
   CSPBallet_Blocks::contact_form() for why).
   -------------------------------------------------------------------------- */

.csp-contact-form-wrap {
	text-align: left;
	margin-top: 40px;
}

.csp-form-notice {
	padding: 14px 18px;
	border-radius: 6px;
	margin-bottom: 24px;
	font-family: 'Jost', sans-serif;
	font-size: 16px;
}
.csp-form-notice--success {
	background: #E6E4DF;
	color: #333B44;
	border: 1px solid #7D8FA6;
}
.csp-form-notice--error {
	background: #FAF9F7;
	color: #4B5563;
	border: 1px solid #B79098;
}

.csp-form-grid {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
}
.csp-form-row {
	flex: 1 1 100%;
	display: flex;
	flex-direction: column;
	gap: 6px;
}
.csp-form-row--half {
	flex: 1 1 calc(50% - 10px);
}
.csp-form-row label {
	font-family: 'Jost', sans-serif;
	font-size: 14px;
	font-weight: 500;
	color: #4B5563;
}
.csp-form-row input,
.csp-form-row textarea {
	font-family: 'Jost', sans-serif;
	font-size: 17px;
	color: #4B5563;
	background: #FFFFFF;
	border: 1px solid #D9DDE2;
	border-radius: 6px;
	padding: 12px 14px;
	width: 100%;
}
.csp-form-row input:focus,
.csp-form-row textarea:focus {
	outline: none;
	border-color: #7D8FA6;
	box-shadow: 0 0 0 3px rgba(125,143,166,0.2);
}

.csp-form-honeypot {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.csp-form-submit {
	margin-top: 24px;
	font-family: 'Jost', sans-serif;
	font-size: 17px;
	font-weight: 600;
	color: #FFFFFF;
	background: #4B5563;
	border: none;
	border-radius: 999px;
	padding: 16px 36px;
	cursor: pointer;
}
.csp-form-submit:hover {
	background: #333B44;
}

@media (max-width: 600px) {
	.csp-form-row--half {
		flex: 1 1 100%;
	}
}
