/* style.css */

:root {
    --panel-bg: rgba(40, 46, 50, 0.82);
    --text-color: #f5f5f3;
    --text-muted: #cfd3d4;
    --link-color: #ffffff;
    --radius: 10px;
    --gap: 12px;
    --max-width: 900px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    height: 100%;
}

body {
    min-height: 100dvh;
    color: var(--text-color);
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    line-height: 1.6;
    background-color: #2a2e30;
    background-image: url('/media/bg-mobile.jpg');
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    display: flex;
    flex-direction: column;
}

@supports (background-image: image-set(url('/media/bg-mobile.webp') type('image/webp'))) {
    body {
        background-image: image-set(
            url('/media/bg-mobile.webp') type('image/webp')
        );
    }
}

a {
    color: var(--link-color);
    text-decoration: none;
}
a:hover, a:focus {
    text-decoration: underline;
}

main a { text-decoration: underline; text-decoration-color: rgba(255,255,255,0.7);background-color: rgba(178,147,86,0.5) }
main a:hover { text-decoration-color: currentColor; }
main a:active { opacity: 0.7; }
main a { -webkit-tap-highlight-color: transparent; }
main a:focus-visible { outline: 1px solid var(--link-color); outline-offset: 2px; }
/* main a::after { content: " (" attr(href) ")"; } */
main img { max-width:100%; float:left; padding: 5px 5px 5px 0; }

@media (min-width: 761px) {
    body {
        background-image: url('/media/bg-desktop.jpg');
        background-attachment: fixed;
    }
    @supports (background-image: image-set(url('/media/bg-desktop.webp') type('image/webp'))) {
        body {
            background-image: image-set(
                url('/media/bg-desktop.webp') type('image/webp')
            );
            background-attachment: fixed;
        }
    }
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

.skip-link {
    position: absolute;
    left: -999px;
    top: 0;
    background: #000;
    color: #fff;
    padding: 8px 12px;
    z-index: 100;
}
.skip-link:focus {
    left: 8px;
    top: 8px;
}

/* ---------- Header / nav ---------- */

.site-header {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: var(--gap);
    line-height:1;
}

.nav-block {
    background: var(--panel-bg);
    border-radius: var(--radius);
    overflow: hidden;
}

.menu-toggle summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    font-size: 1.1rem;
    font-weight: 600;
}
.menu-toggle summary::-webkit-details-marker {
    display: none;
}

.menu-icon {
    display: inline-flex;
    flex-shrink: 0;
}
.menu-toggle .icon-close {
    display: none;
}
.menu-toggle[open] .icon-menu {
    display: none;
}
.menu-toggle[open] .icon-close {
    display: inline-flex;
}

.menu-panel ul {
    list-style: none;
}
.menu-panel li a {
    display: block;
    padding: 12px 16px;
}
.menu-panel li a:hover,
.menu-panel li a:focus {
    background: rgba(255, 255, 255, 0.08);
    text-decoration: none;
}
.menu-panel li a.current {
    font-weight: 700;
    border-left: 3px solid var(--link-color);
}

/* Row 2: about / contact / lang, equal-width grid regardless of label length */
.secondary-nav {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
}
.secondary-nav > a,
.secondary-nav > .lang-switch {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 8px;
    text-align: center;
    gap: 6px;
}
.secondary-nav > a.current {
    font-weight: 700;
}
.lang-switch a[aria-current="true"] {
    font-weight: 700;
    text-decoration: underline;
}

/* ---------- Main content ---------- */

main {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--gap) var(--gap);
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: var(--gap);
}

.page-col {
    background: var(--panel-bg);
    border-radius: var(--radius);
    padding: 16px;
}

.page-col h2 {
    margin-bottom: 0.5em;
}
.page-col p {
    margin-bottom: 1em;
}
.page-col p:last-child {
    margin-bottom: 0;
}

/* ---------- Media embeds ---------- */

.player {
    text-align: center;
    margin: 12px 0;
}
.player audio,
.player video {
    max-width: 100%;
    border-radius: var(--radius);
}
.media-descr {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.embed-container {
	display:flex;
	gap:5px;
	justify-content:center;
	flex-wrap:wrap;
}
.video-embed {
    position: relative;
    width: 100%;
    max-width: 150px; /* keeps a Short from becoming absurdly tall on wide screens */
    /*margin: 0 auto;*/
}
.video-embed--portrait {
    aspect-ratio: 9 / 16;
}
.video-embed--landscape {
    aspect-ratio: 16 / 9;
    max-width: 100%; /* landscape videos can go full-width */
}
.video-embed iframe {
    width: 100%;
    height: 100%;
    border-radius: var(--radius);
}
.yt-facade {
    position: relative;
    cursor: pointer;
}
.yt-facade img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.yt-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 25%; /* scales cleanly with the container, unlike YouTube's own button */
    max-width: 68px;
}

/* ---------- Footer ---------- */

.site-footer {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: var(--gap);
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* ---------- Wider screens ---------- */

@media (min-width: 761px) {
    .site-header {
        padding: 20px;
    }
    main {
        padding: 0 20px 20px;
    }
    .menu-toggle summary {
        font-size: 1.3rem;
    }
}
