/* VP pradžia (plans 010 + 010b). Loaded on the "VP pradžia" template only, after the taste skill's kit (assets/kit/, unchanged copies)
   and assets/brand.css (the fonts and the printed :root, shared with the vp-blocksy theme since plan 011a).
   Page CSS only where the skill's references say page CSS (inside a visual, a frame's ratio, the moment's frame). */

/* WCAG 2.4.11: a focused control is never hidden under the fixed nav or the phone's action bar (the kit keeps scroll-padding-top 0
   for its screen tiles; this page puts the focus first) */
html { scroll-padding-top: calc(var(--nav, 72px) + 8px); scroll-padding-bottom: calc(var(--bar, 0px) + 8px); }
/* ...while an anchor jump (#kursai) still lands on the section's screen tile, as the kit intends (layout-v4.md section 2) */
main > section[id], footer.closing[id] { scroll-margin-top: calc(-1 * (var(--nav, 72px) + 8px)); }

/* the logo (the client's own mark, not the dealt one): its wordmark needs more than the kit's 24px to stay legible */
.vph-logo img { height: 30px; width: auto; }
@media (max-width: 639px) { .vph-logo img { height: 24px; } }

/* the hero's notice line is a link to the next intake (a whole tap target on a phone: system.css gives .link 44px there) */
.vph-hero__next { color: inherit; }

/* the photographs in their frames: cover the frame, the frame's ratio is the picture's (4:3) */
.vph-frame { --ratio: 75%; }
.vph-frame > .frame__img[hidden] { display: none; }   /* the images carry the kit's .frame__img (absolute, cover) */
@media (max-width: 639px) { .vph-frame { --ratio: 100%; } }

/* the peek rows: the row's link under its line */
.vph-paths__rows .vph-row__act { grid-column: 1; margin: 0; }

/* intakes: the formats as plain lines inside the row */
.vph-intake__fmt { list-style: none; margin: 0; padding: 0; grid-column: 1; }
.vph-intake__date { grid-column: 1; color: var(--muted); }
.vph-intakes__list .rows__value { align-self: center; }
@media (max-width: 639px) { .vph-intakes__list .rows__value { grid-column: 1; grid-row: auto; text-align: left; max-width: none; } }


/* picture-develops (the dealt moment): the section's one photograph, as tall as the text beside it (in-page-service.html) */
.develop { margin: 0; border-radius: var(--r-lg); overflow: hidden; height: min(560px, var(--ly-fit)); }
.develop > img { display: block; width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 1023px) { .develop { height: auto; aspect-ratio: 4 / 3; margin-top: var(--s-7); } }

/* a phone: the licence path and the intakes are two screens (--hm: 2, so no neighbour shows in their tiles); their picture grows
   into what the words leave, so the second screen ends on the picture, not on an empty band (the gap to the next section stays one) */
@media (max-width: 639px) {
	#kelias, #grupes { display: flex; flex-direction: column; }
	#kelias > .wrap, #grupes > .wrap, #kelias .grid, #grupes .grid { flex: 1 1 auto; display: flex; flex-direction: column; }
	#kelias .develop, #grupes .vph-frame { flex: 1 1 auto; position: relative; aspect-ratio: auto; height: auto; min-height: 256px; --ratio: 0px; }
	#kelias .develop > img { position: absolute; inset: 0; }
}

/* the tablet (640 to 1023, layout-v4.md section 2): the stacked sections run 1,130 to 1,860px, so they take two screens there (the one
   page-CSS rule on a section), the split sections' picture grows into what the words leave, and the footer's columns pair up */
@media (min-width: 640px) and (max-width: 1023px) {
	#kursai, #kelias, #grupes { --h: 2; }
	#instruktoriai .grid > .tile { grid-column: auto / span 4; --tile-ratio: 9 / 16; }   /* three portraits across: one screen */
	#klausimai .section-head > p { display: none; }   /* the FAQ's grey line goes at the tablet: one screen (layout-v4.md section 2) */
	#kursai, #kelias, #grupes { display: flex; flex-direction: column; }
	#kursai > .wrap, #kelias > .wrap, #grupes > .wrap, #kursai .grid, #kelias .grid, #grupes .grid { flex: 1 1 auto; display: flex; flex-direction: column; }
	#kursai .vph-frame, #kelias .develop, #grupes .vph-frame { flex: 1 1 auto; position: relative; aspect-ratio: auto; height: auto; min-height: 320px; --ratio: 0px; margin-top: var(--s-7); }
	#kelias .develop > img { position: absolute; inset: 0; }
	.closing__links > .grid > * { grid-column: auto / span 6; }
}

/* the instructors: square portraits keep the row inside one screen */
#instruktoriai .tile { --tile-ratio: 1 / 1; }
#instruktoriai .tile__media > img { object-position: 50% 30%; }


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