@font-face {
    font-family: latin modern;
    src: url(/assets/LM-regular.woff2)format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap
}

@font-face {
    font-family: latin modern;
    src: url(/assets/LM-italic.woff2)format("woff2");
    font-weight: 400;
    font-style: italic;
    font-display: swap
}

@font-face {
    font-family: latin modern;
    src: url(/assets/LM-bold.woff2)format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: swap
}

@font-face {
    font-family: latin modern;
    src: url(/assets/LM-bold-italic.woff2)format("woff2");
    font-weight: 700;
    font-style: italic;
    font-display: swap
}

:root {
    interpolate-size: allow-keywords;
    --text: "Latin Modern", "Latin Modern Roman", "Computer Modern Serif", "CMU Serif", Georgia, serif;
    --mono: "Latin Modern Mono", "CMU Typewriter Text", ui-monospace, Menlo, Consolas, monospace;
    
}
aside {
    margin-left: 2rem;
    p {
	color: #454545;
    }
}

article {
    display: flex;
    flex-direction: column;
    padding-left: 2rem;
    hgroup {
	display: flex;
	flex-direction: column;
    }
    p {
	display: block;
	padding-bottom: 2rem;
    }
}

.float-toggle {
    cursor: pointer;
    font-size: 0.7rem;
    padding: 0.15rem 0.4rem;
    border: 1px solid silver;
    border-radius: 4px;
    background: gainsboro;
    user-select: none;
    line-height: 1;
}

.float-toggle:hover {
    background: #d0d0d0;
}

section {
    display: flex;
    flex-direction: column;
    align-items: center;
    h2 {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
    }
    hgroup {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	/* I like the hgroups to be a bit tighter */
	h2 {
	    margin-block-end: auto;
	}
	p {
	    margin-block-start: 0.5rem;
	}
    }

}
/* Detached floating state using modern 2026 viewport units & logical properties */
section:has(#detach-videos:checked) {
    position: fixed;
    inset-block-end: 1.5rem;
    inset-inline-end: 1.5rem;
    z-index: 9999;

    inline-size: min(90dvw, 480px);
    max-block-size: 85svh; /* Safe even when mobile toolbars are expanded */
    overflow-y: auto;
    resize: both;

    background: Canvas;
    padding: 1rem;
    border: 2px solid silver;
    border-radius: 10px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.25);
}

/* Highlight the toggle icon when detached */
section:has(#detach-videos:checked) .float-toggle {
    background: oklch(from silver none none -180);
    border-color: navy;
    color: white;
}

/* 2. Column sizing, fold-out animation, and rotating arrow */
details {
    width: 60%;          /* Responsive width on mobile/tablet */
    max-width: 720px;    /* Caps the column width on desktop */
    margin-bottom: 0.75rem;

    summary {
	cursor: pointer;
	text-align: center;
	border: 1px solid silver;
	padding: 0.5rem 0.75rem;
	border-radius: 6px;
	transition: border-radius 0.1s ease-out 0.4s, background-color 0.3s ease;

	/* Hide native marker and add rotatable arrow */
	list-style: none;
	&::-webkit-details-marker {
	    display: none;
	}

	&::before {
	    content: "▶";
	    display: inline-block;
	    margin-inline-end: 0.5rem;
	    font-size: 0.8em;
	    transition: rotate 0.4s ease-out;
	}
    }

    &::details-content {
	height: 0;
	overflow: hidden;
	border-radius: 0 0 6px 6px;
	border-color: silver;
	border-style: solid;
	border-width: 0 1px 0 1px;
	padding-inline: 0.5rem;
	transition:
	    all 0.4s ease-out,
	    border-width 0.4s step-end;
    }

    /* 3. Responsive 16:9 YouTube iframe sizing */
    iframe {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 16 / 9;
	border: none;
    }

    &:open {
	summary {
	    border-radius: 6px 6px 0 0;
	    transition: border-radius step-start, background-color 0.3s ease;

	    &::before {
		rotate: 90deg;
	    }
	}

	&::details-content {
	    border-width: 0 2px 2px 2px;
	    padding-block: 0.5rem;
	    height: auto;
	    transition:
		all 0.4s ease-out,
		border-width step-start;
	}
    }
}

/* fun cyclic things */

#music-videos .cycle-btn,
#music-videos details[data-set] {
    display: none;
}

#music-videos:has(#set-1:checked) {
    details[data-set="1"] { display: block; }
    .to-2                 { display: inline-block; }
}

#music-videos:has(#set-2:checked) {
    details[data-set="2"] { display: block; }
    .to-3                 { display: inline-block; }
}

#music-videos:has(#set-3:checked) {
    details[data-set="3"] { display: block; }
    .to-1                 { display: inline-block; }
}

html {
    min-height: 100%;
    background-color: oklch(0.92 0.035 280); /* Soft lavender-periwinkle base */
    background-image:
	/* Top-left: Warm peach / soft pink glow */
	radial-gradient(circle at 12% 10%, oklch(0.90 0.065 35 / 0.85) 0%, transparent 52%),
	/* Top-right: Soft mint / seafoam cyan glow */
	radial-gradient(circle at 88% 12%, oklch(0.91 0.065 185 / 0.85) 0%, transparent 55%),
	/* Center: Airy violet-pink bridge */
	radial-gradient(circle at 50% 48%, oklch(0.92 0.055 315 / 0.75) 0%, transparent 60%),
	/* Bottom-left: Richer periwinkle / sky blue */
	radial-gradient(circle at 15% 88%, oklch(0.88 0.075 255 / 0.90) 0%, transparent 58%),
	/* Bottom-right: Soft orchid / rose-lavender */
	radial-gradient(circle at 88% 88%, oklch(0.89 0.065 310 / 0.85) 0%, transparent 55%);
    background-attachment: fixed;
    background-repeat: no-repeat;
}

body {
    margin: 0;
    min-height: 100vh;
    background: transparent;
    color: oklch(0.22 0.015 265);
    font: 1.125rem/1.4 var(--text);
    font-kerning: normal;
    font-variant-ligatures: common-ligatures;
    text-rendering: optimizeLegibility
    hr {
	border: 0;
	height: 2px;
	background: radial-gradient(circle,rgba(63, 94, 251, 1) 0%, rgba(252, 70, 107, 1) 100%);
    }
    p {
	color: oklch(0.40 0.16 260.75);
	margin-inline-start: 0.75rem;
	margin-inline-end: 0.75rem;
    }
    a:-webkit-any-link {
	color: oklch(0.42 0.24 286.55 / 1);
    }


}

/* fix weird */
@layer reset-resize {
    section:has(#detach-videos:not(:checked)) {
	inline-size: auto !important;
	block-size: auto !important;
    }
}
