/**
 * Base styles
 *
 * Element-level styles shared by the front end and the editor
 * (also loaded in the editor via add_editor_style() in inc/editor.php).
 *
 * Fonts, colors, font sizes, line heights and button/link colors are set in
 * theme.json. Only write here what theme.json cannot express.
 *
 * Do not reset the margins of p, h1-h6, ul, figure, etc. WordPress sets the
 * spacing between blocks with zero-specificity selectors, and a margin reset
 * here would override it.
 */

/* Box sizing
--------------------------------------------- */
*,
*::before,
*::after {
	box-sizing: border-box;
}

/* Document
--------------------------------------------- */
html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
}

/* No font smoothing setting: it makes text thinner on Mac than in the design. */
body {
	margin: 0;

	/* Japanese line breaking (kinsoku). Unsupported browsers simply ignore these. */
	line-break: strict;
	word-break: normal;
	overflow-wrap: break-word;
}

/* Headings
--------------------------------------------- */
h1,
h2,
h3,
h4,
h5,
h6 {
	/* Break Japanese headings between phrases, not in the middle of a word (Chrome/Edge). */
	word-break: auto-phrase;

	/* Tighten the spacing of Japanese punctuation in headings. */
	font-feature-settings: "palt";
}

/* Extra space above headings in post content. */
.is-layout-constrained > h2,
.is-layout-flow > h2 {
	margin-block-start: var(--wp--preset--spacing--70);
}

.is-layout-constrained > :is(h3, h4, h5, h6),
.is-layout-flow > :is(h3, h4, h5, h6) {
	margin-block-start: var(--wp--preset--spacing--60);
}

/* Text
--------------------------------------------- */
a {
	text-underline-offset: 0.2em;
}

strong,
b {
	font-weight: 700;
}

small {
	font-size: var(--wp--preset--font-size--small);
}

code,
kbd,
pre,
samp {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.9em;
}

ul,
ol {
	padding-inline-start: 1.5em;
}

/* Media
--------------------------------------------- */
img,
svg,
video {
	max-width: 100%;
	height: auto;
}

iframe {
	max-width: 100%;
}

/* Tables
--------------------------------------------- */
table {
	border-collapse: collapse;
	width: 100%;
}

/* Forms
--------------------------------------------- */
button,
input,
select,
textarea {
	font: inherit;
	letter-spacing: inherit;
}

/* Focus
--------------------------------------------- */
:focus-visible {
	outline: 2px solid var(--wp--preset--color--primary);
	outline-offset: 2px;
}

/* Accessibility
 * .screen-reader-text is WordPress's own class (also output by core),
 * so it keeps its name instead of a u- prefix.
--------------------------------------------- */
.screen-reader-text {
	border: 0;
	clip-path: inset(50%);
	height: 1px;
	margin: -1px;
	overflow: hidden;
	padding: 0;
	position: absolute !important;
	width: 1px;
	word-wrap: normal !important;
}

.screen-reader-text:focus {
	background-color: var(--wp--preset--color--base);
	border-radius: var(--wp--custom--radius--small);
	box-shadow: 0 0 2px 2px rgb(0 0 0 / 60%);
	clip-path: none;
	color: var(--wp--preset--color--contrast);
	display: block;
	font-size: var(--wp--preset--font-size--small);
	font-weight: 700;
	height: auto;
	left: 5px;
	line-height: normal;
	padding: 15px 23px 14px;
	text-decoration: none;
	top: 5px;
	width: auto;
	z-index: 100000;
}

/* Content written with the classic editor
--------------------------------------------- */
.wp-caption {
	max-width: 100%;
}

.wp-caption-text {
	color: var(--wp--preset--color--muted);
	font-size: var(--wp--preset--font-size--small);
	margin-block-start: 0.5em;
}
