/* My Sailworks (sailworks/my_sailworks.py) – dunkel wie sailworks.de, hell, wenn das Gerät auf hell steht.
   Entwurf: docs/my-sailworks.md, Abschnitt 14. Farben nur über die Variablen. */
:root {
	--grund: #0d0d0d; --flaeche: #161616; --flaeche-2: #1a1a1a; --leiste: #111111;
	--rand: #252525; --rand-feld: #333333;
	--text: #e0e0e0; --text-stark: #ffffff; --text-leise: #a3a3a3; --text-mittel: #cfcfcf;
	--akzent: #2ec4be; --akzent-flaeche: #10302f; --knopf: #007f7b; --knopf-text: #ffffff;
	--warn: #f0b56a; --warn-rand: #3a3226; --fehler: #f08a8a;
	--balken: #009e99; --balken-aus: #333333;
	color-scheme: dark;
}
@media (prefers-color-scheme: light) {
	:root {
		--grund: #f4f6f6; --flaeche: #ffffff; --flaeche-2: #ffffff; --leiste: #ffffff;
		--rand: #e1e6e6; --rand-feld: #cfd6d6;
		--text: #1f2626; --text-stark: #111818; --text-leise: #56605f; --text-mittel: #3d4747;
		--akzent: #00726e; --akzent-flaeche: #e3f3f2; --knopf: #007f7b; --knopf-text: #ffffff;
		--warn: #9a5600; --warn-rand: #f0d9b8; --fehler: #b42318;
		--balken: #009e99; --balken-aus: #d9dede;
		color-scheme: light;
	}
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--grund); color: var(--text); font-family: Montserrat, system-ui, sans-serif;
	font-size: 15px; line-height: 1.5; -webkit-text-size-adjust: 100%; }
a { color: var(--akzent); }
a:hover { opacity: .85; }
h1 { margin: 0; color: var(--text-stark); font-size: 24px; font-weight: 700; line-height: 1.2; }
h2 { margin: 0 0 10px; color: var(--text-stark); font-size: 17px; font-weight: 700; }
p { margin: 0; }

.my-kopf { display: flex; justify-content: space-between; align-items: center; padding: 18px 20px; gap: 12px; }
.my-logo img { height: 20px; width: auto; display: block; }
.my-kreis { width: 40px; height: 40px; border-radius: 20px; background: var(--flaeche-2); border: 1px solid var(--rand-feld);
	display: flex; align-items: center; justify-content: center; color: var(--text-stark); text-decoration: none;
	font-weight: 700; font-size: 14px; }
.my-rahmen { display: flex; gap: 32px; max-width: 1360px; margin: 0 auto; padding: 0 20px 110px; }
.my-seite { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 16px; max-width: 760px; }
.my-seitenmenue { display: none; }
.my-hinweis { background: var(--akzent-flaeche); color: var(--text-stark); border-radius: 12px; padding: 10px 14px; font-size: 13px; }

.my-karte { background: var(--flaeche); border: 1px solid var(--rand); border-radius: 16px; padding: 18px;
	display: flex; flex-direction: column; gap: 10px; }
.my-karte.warn { border-color: var(--warn-rand); }
.my-marke { color: var(--akzent); font-size: 11px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; }
.my-marke.warn { color: var(--warn); }
.my-titel { color: var(--text-stark); font-weight: 700; font-size: 16px; }
.my-leise { color: var(--text-leise); font-size: 13px; }
.my-mittel { color: var(--text-mittel); font-size: 13px; }
.my-zeile { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.my-betrag { color: var(--text-stark); font-weight: 700; font-size: 18px; white-space: nowrap; }
.my-weiter { color: var(--akzent); font-size: 14px; font-weight: 600; text-decoration: none; }
.my-knopf { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 16px;
	border-radius: 10px; background: var(--knopf); color: var(--knopf-text); font: inherit; font-size: 14px; font-weight: 700;
	text-decoration: none; border: 0; cursor: pointer; }
.my-knopf.leise { background: transparent; color: var(--text); border: 1px solid var(--rand-feld); font-weight: 500; }
.my-knopf:disabled { opacity: .6; cursor: wait; }

.my-balken { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.my-balken span { height: 6px; border-radius: 3px; background: var(--balken-aus); }
.my-balken span.an { background: var(--balken); }
.my-stufen { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; font-size: 10.5px; line-height: 1.3;
	color: var(--text-leise); }
.my-stufen span { min-width: 0; overflow-wrap: anywhere; hyphens: auto; }
.my-stufen .an { color: var(--text); }
.my-stufen .jetzt { color: var(--akzent); font-weight: 600; }

.my-schritt { display: flex; gap: 12px; align-items: flex-start; }
.my-punkt { width: 22px; height: 22px; border-radius: 11px; flex-shrink: 0; border: 2px solid var(--balken-aus);
	display: flex; align-items: center; justify-content: center; }
.my-punkt.an { background: var(--balken); border-color: var(--balken); }

.my-liste { background: var(--flaeche); border: 1px solid var(--rand); border-radius: 16px; padding: 4px 18px; }
.my-liste > a, .my-liste > div { display: flex; justify-content: space-between; align-items: center; gap: 12px;
	min-height: 58px; border-bottom: 1px solid var(--rand); color: var(--text); text-decoration: none; padding: 8px 0; }
.my-liste > :last-child { border-bottom: 0; }
.my-liste .rechts { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; text-align: right; flex-shrink: 0; }
.my-liste .links { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.my-liste .stark { color: var(--text-stark); }
.my-etikett { font-size: 11px; font-weight: 700; color: var(--akzent); }
.my-etikett.warn { color: var(--warn); }
.my-etikett.leise { color: var(--text-leise); font-weight: 500; }

.my-schnell { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.my-schnell a { display: flex; flex-direction: column; gap: 8px; background: var(--flaeche-2); border: 1px solid var(--rand);
	border-radius: 14px; padding: 16px; text-decoration: none; color: var(--text-stark); font-weight: 600; font-size: 14px; }
.my-schnell svg { stroke: var(--akzent); }
.my-schnell a.spaeter { opacity: .55; pointer-events: none; }

.my-raster { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 16px; }
.my-raster .wert { color: var(--text-stark); font-size: 14px; }
.my-raster .name { color: var(--text-leise); font-size: 11px; }

.my-giro { display: flex; gap: 16px; align-items: center; background: #ffffff; border-radius: 12px; padding: 14px; color: #222222; }
.my-giro img { width: 116px; height: 116px; flex-shrink: 0; }
.my-giro strong { font-size: 13px; }
.my-giro span { font-size: 12px; line-height: 1.4; }

.my-feld { display: flex; flex-direction: column; gap: 8px; }
.my-feld label { font-size: 13px; color: var(--text-mittel); }
.my-feld input { height: 52px; background: var(--flaeche); border: 1px solid var(--rand-feld); border-radius: 10px;
	color: var(--text-stark); font: inherit; font-size: 16px; padding: 0 16px; }

.my-unten { position: fixed; left: 0; right: 0; bottom: 0; height: calc(72px + env(safe-area-inset-bottom));
	padding-bottom: env(safe-area-inset-bottom); background: var(--leiste); border-top: 1px solid var(--rand);
	display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); z-index: 10; }
.my-unten a, .my-seitenmenue a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
	color: var(--text-leise); text-decoration: none; font-size: 11px; }
.my-unten a.aktiv { color: var(--akzent); font-weight: 700; }
.my-unten svg, .my-seitenmenue svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2;
	stroke-linejoin: round; stroke-linecap: round; }
.my-fuss { display: flex; gap: 16px; flex-wrap: wrap; color: var(--text-leise); font-size: 12px; padding: 24px 0 8px; }
.my-fuss a { color: var(--text-leise); }

/* am Rechner: Menü links statt der Leiste unten */
@media (min-width: 900px) {
	.my-kopf { padding: 18px 32px; border-bottom: 1px solid var(--rand); margin-bottom: 24px; }
	.my-logo img { height: 22px; }
	.my-rahmen { padding: 0 32px 48px; }
	.my-unten { display: none; }
	.my-seitenmenue { display: flex; flex-direction: column; gap: 4px; flex: 0 0 240px; }
	.my-seitenmenue a { flex-direction: row; justify-content: flex-start; gap: 12px; min-height: 44px; padding: 0 14px;
		border-radius: 10px; color: var(--text-mittel); font-size: 14px; }
	.my-seitenmenue a.aktiv { background: var(--akzent-flaeche); color: var(--text-stark); font-weight: 600; }
	.my-seite { max-width: 980px; }
}

/* Stufe 2: Formulare, Fotos, Tools */
.my-fehler { background: transparent; color: var(--fehler); font-size: 13px; }
.my-form { display: flex; flex-direction: column; gap: 14px; }
.my-form label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--text-mittel); }
.my-form input, .my-form select, .my-form textarea { background: var(--flaeche-2); border: 1px solid var(--rand-feld); border-radius: 10px;
	color: var(--text-stark); font: inherit; font-size: 15px; padding: 12px; min-height: 46px; width: 100%; }
.my-form textarea { min-height: 110px; resize: vertical; }
.my-form input:focus, .my-form select:focus, .my-form textarea:focus { outline: none; border-color: var(--akzent); }
.my-wahl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.my-wahl label { flex-direction: row; align-items: center; gap: 8px; min-height: 46px; padding: 0 12px; border: 1px solid var(--rand-feld);
	border-radius: 10px; background: var(--flaeche-2); color: var(--text); cursor: pointer; }
.my-wahl input { width: auto; min-height: 0; accent-color: var(--balken); }
.my-wahl label:has(input:checked) { border-color: var(--balken); background: var(--akzent-flaeche); color: var(--text-stark); font-weight: 600; }
.my-knoepfe { display: flex; gap: 8px; flex-wrap: wrap; }
.my-knoepfe .my-knopf { flex: 1 1 140px; }
.my-werkstattfotos ul { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.my-werkstattfotos img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; border: 1px solid var(--rand); }
.my-fotos ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.my-fotos li { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--text-mittel); }
.my-fotos li img { width: 48px; height: 48px; object-fit: cover; border-radius: 8px; border: 1px solid var(--rand); }
.my-fotos li span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.my-fotos li button { background: none; border: 0; color: var(--text-leise); font-size: 18px; cursor: pointer; min-width: 36px; min-height: 36px; }
.my-hochladen { display: flex; align-items: center; justify-content: center; min-height: 52px; border: 1px dashed var(--rand-feld);
	border-radius: 10px; background: var(--flaeche-2); color: var(--akzent); font-weight: 600; font-size: 14px; cursor: pointer; text-align: center; }
.my-hochladen input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.my-mass { display: flex; align-items: center; gap: 10px; min-height: 56px; border-bottom: 1px solid var(--rand); }
.my-mass:last-child { border-bottom: 0; }
.my-mass .nr { width: 26px; height: 26px; border-radius: 13px; background: var(--akzent-flaeche); color: var(--akzent); font-size: 11px;
	font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.my-mass label { flex: 1; font-size: 13px; color: var(--text); line-height: 1.3; }
.my-mass .pflicht { color: var(--warn); }
.my-mass input, .my-mass select { width: 120px; min-height: 42px; background: var(--flaeche-2); border: 1px solid var(--rand-feld);
	border-radius: 8px; color: var(--text-stark); font: inherit; font-size: 15px; padding: 0 10px; text-align: right; }
.my-mass input[type=text] { text-align: left; }
.my-ergebnis { display: flex; align-items: baseline; gap: 10px; padding: 10px 14px; border-radius: 10px; background: var(--akzent-flaeche); }
.my-ergebnis strong { color: var(--akzent); font-size: 24px; }
.my-ergebnis span { color: var(--text-mittel); font-size: 13px; }
details.my-werkzeug { background: var(--flaeche); border: 1px solid var(--rand); border-radius: 16px; padding: 4px 18px; }
details.my-werkzeug summary { list-style: none; cursor: pointer; min-height: 52px; display: flex; align-items: center; justify-content: space-between;
	color: var(--text-stark); font-weight: 700; }
details.my-werkzeug summary::after { content: "+"; color: var(--akzent); font-size: 20px; }
details.my-werkzeug[open] summary::after { content: "−"; }
details.my-werkzeug > div { padding: 4px 0 18px; display: flex; flex-direction: column; gap: 12px; }

/* Konto: Benachrichtigungen an/aus */
.my-form label.my-schalter { flex-direction: row; align-items: center; gap: 12px; min-height: 44px; font-size: 15px; color: var(--text-stark); }
.my-form .my-schalter input { width: 22px; height: 22px; min-height: 0; padding: 0; accent-color: var(--balken); flex: none; }
.my-knopf.gefahr { color: var(--fehler); border-color: var(--fehler); }

/* Fehlerseiten (404, Fehler, Meldungen) */
.my-fehlerseite { max-width: 520px; display: flex; flex-direction: column; gap: 14px; padding-top: 24px; }
.my-fehlerseite h1 { font-size: 28px; }
.my-fehlerseite.rot h1 { color: var(--fehler); }
.my-technik summary { cursor: pointer; color: var(--text-mittel); font-size: 13px; }
.my-technik pre { white-space: pre-wrap; font-size: 11px; max-height: 360px; overflow: auto; background: var(--flaeche-2);
	padding: 12px; border-radius: 10px; }

/* Konfiguratoren (Stackpack, Rollfockpersenning) – Aufbau wie auf sailworks.de, untereinander statt nebeneinander */
.kf { display: flex; flex-direction: column; gap: 16px; }
.kf-buehne { position: relative; border: 1px solid var(--rand); border-radius: 14px; overflow: hidden; background: #0d0d0d; }
.kf-buehne iframe { display: block; width: 100%; height: 420px; border: 0; opacity: 0; transition: opacity .35s; }
.kf-buehne iframe.bereit { opacity: 1; }
.kf-warn { position: absolute; left: 10px; right: 10px; bottom: 10px; background: rgba(30, 18, 14, .96); border: 1px solid #7a4a22;
	color: #f0b98a; border-radius: 8px; padding: 8px 10px; font-size: 12px; white-space: pre-line; }
.kf-warn[hidden] { display: none; }
.kf-feld { gap: 10px; }
.kf-titel { color: var(--akzent); font-size: 11px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; margin-top: 12px; }
.kf-titel:first-child { margin-top: 0; }
.kf-text { color: var(--text-mittel); font-size: 13px; }
.kf-zeile { display: flex; align-items: center; gap: 12px; }
.kf-zeile[hidden] { display: none; }
.kf-zeile label { flex: 1; font-size: 13px; color: var(--text); }
.kf-zeile input { width: 120px; background: var(--flaeche-2); border: 1px solid var(--rand-feld); border-radius: 10px; color: var(--text-stark);
	font: inherit; font-size: 15px; padding: 10px; text-align: right; }
.kf-zeile input:focus { outline: none; border-color: var(--akzent); }
.kf-regler { width: 100%; accent-color: var(--balken); }
.kf-wahl { display: flex; border: 1px solid var(--rand-feld); border-radius: 10px; overflow: hidden; }
.kf-wahl button { flex: 1; background: var(--flaeche-2); border: 0; color: var(--text-mittel); font: inherit; font-size: 13px; padding: 11px 4px;
	cursor: pointer; min-height: 44px; }
.kf-wahl button.an { background: var(--knopf); color: var(--knopf-text); font-weight: 600; }
.kf-wahl button[disabled] { opacity: .35; cursor: not-allowed; }
.kf-farben { display: grid; grid-template-columns: repeat(8, 1fr); gap: 8px; max-width: 440px; }
.kf-farben button { aspect-ratio: 1; border-radius: 8px; border: 2px solid var(--rand); cursor: pointer; padding: 0; }
.kf-farben button.an { border-color: var(--text-stark); box-shadow: 0 0 0 2px var(--balken); }
.kf-farbname { color: var(--text-leise); font-size: 12px; min-height: 16px; }
.kf-mehr { border: 1px solid var(--rand); border-radius: 10px; padding: 0 12px; }
.kf-mehr summary { cursor: pointer; padding: 12px 0; color: var(--text-mittel); font-size: 13px; }
.kf-mehr .kf-zeile { margin-bottom: 10px; }
.kf-fotoliste { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.kf-fotoliste li { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--text-leise); }
.kf-fotoliste img { width: 36px; height: 36px; object-fit: cover; border-radius: 6px; }
.kf-fotoliste span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kf-fotoliste button { background: none; border: 0; color: var(--text-leise); font-size: 18px; cursor: pointer; }
.kf-aufschluesselung { margin-top: 10px; }
.kf-aufschluesselung div { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; color: var(--text-mittel); padding: 2px 0; }
.kf-aufschluesselung span:last-child { color: var(--text); white-space: nowrap; }
.kf-preis { display: flex; justify-content: space-between; align-items: baseline; border-top: 1px solid var(--rand); padding-top: 12px; }
.kf-preis strong { color: var(--text-stark); font-size: 26px; display: block; text-align: right; }
.kf-preis small { color: var(--text-leise); font-size: 11px; display: block; text-align: right; }
.kf-recht { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--rand-feld); border-radius: 10px; padding: 12px;
	font-size: 12px; color: var(--text-mittel); cursor: pointer; }
.kf-recht input { width: 18px; height: 18px; accent-color: var(--balken); flex: none; margin-top: 2px; }
.kf-recht strong { color: var(--text-stark); }
.kf-falsch, input.kf-falsch { border-color: var(--fehler) !important; }
/* „So wird gemessen“ am Stackpack (TK-2026-00129) */
.kf-hilfe { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 13px; }
.kf-hilfe button, .kf-hilfe a { background: none; border: 0; padding: 0; color: var(--akzent); font: inherit; font-weight: 600; cursor: pointer;
	text-decoration: underline; }
.kf-dlg { width: calc(100% - 24px); max-width: 860px; max-height: calc(100% - 24px); padding: 0; background: var(--flaeche); color: var(--text);
	border: 1px solid var(--rand); border-radius: 16px; }
.kf-dlg::backdrop { background: rgba(0, 0, 0, .7); }
.kf-dlg-innen { padding: 18px; display: flex; flex-direction: column; gap: 14px; }
.kf-dlg-kopf { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.kf-dlg-kopf h2 { margin: 0; }
.kf-dlg-zu { background: none; border: 0; color: var(--text-leise); font-size: 28px; line-height: 1; cursor: pointer; padding: 0 4px; min-width: 44px; min-height: 44px; }
.kf-dlg-bild { background: #fff; border-radius: 10px; padding: 8px; }
.kf-dlg-bild img { display: block; width: 100%; height: auto; }
.kf-dlg-bild.klein { max-width: 200px; }
.kf-dlg-zwei { display: grid; gap: 14px; }
.kf-dlg-liste { list-style: none; margin: 0; padding: 0; }
.kf-dlg-liste li { display: flex; gap: 10px; align-items: baseline; padding: 6px 0; border-bottom: 1px solid var(--rand); font-size: 13px; }
.kf-dlg-liste b { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 12px;
	border: 1px solid var(--balken); color: var(--text-stark); font-size: 11px; }
.kf-dlg-fuss { font-size: 13px; color: var(--text-leise); }
@media (min-width: 700px) { .kf-dlg-zwei { grid-template-columns: minmax(0, 1fr) 200px; align-items: start; } .kf-dlg-innen { padding: 24px; } }
@media (min-width: 900px) { .kf-buehne iframe { height: 560px; } }

/* Massblatt Schritt für Schritt mit Zeichnung (www/my/massblatt.html) */
.my-mb { display: flex; flex-direction: column; gap: 14px; scroll-margin-top: 80px; }
.my-mb-stand { display: flex; align-items: center; gap: 12px; font-size: 13px; color: var(--text-leise); }
.my-mb-leiste { flex: 1; height: 6px; border-radius: 3px; background: var(--flaeche-2); overflow: hidden; }
.my-mb-leiste span { display: block; height: 100%; width: 0; background: var(--akzent); transition: width .2s; }
.my-mb-schritt h2 { font-size: 20px; margin: 4px 0 6px; }
.my-mb-inhalt { display: grid; gap: 16px; }
.my-mb-bilder { display: grid; gap: 10px; }
.my-mb-bild { position: relative; background: #fff; border-radius: 12px; border: 1px solid var(--rand); overflow: hidden; margin: 0 auto; width: 100%; }
.my-mb-bild img { width: 100%; height: auto; display: block; }
.my-mb-punkt { position: absolute; transform: translate(-50%, -50%); width: 14px; height: 14px; border-radius: 7px;
	background: rgba(0, 158, 153, .22); border: 2px solid rgba(0, 158, 153, .55); pointer-events: none; transition: all .15s; }
.my-mb-punkt.aktiv { width: 28px; height: 28px; border-radius: 14px; background: rgba(230, 70, 30, .35); border-color: #e6461e;
	box-shadow: 0 0 0 5px rgba(230, 70, 30, .2); }
.my-mass.aktiv .nr { background: var(--akzent); color: #fff; }
.my-mass-hinweis { display: block; font-size: 12px; margin-top: 2px; }
.my-mb-selten summary { cursor: pointer; color: var(--text-leise); padding: 10px 0; font-size: 13px; }
.my-mb-nav { justify-content: space-between; }
@media (min-width: 900px) {
	.my-mb-inhalt.mit-bild { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: start; }
	.my-mb-inhalt.mit-bild .my-mb-bilder { position: sticky; top: 90px; }
}
.my-mb [hidden], .my-mb-ende[hidden] { display: none !important; }
