MediaWiki:Common.css: Unterschied zwischen den Versionen
Admin (Diskussion | Beiträge) Keine Bearbeitungszusammenfassung |
Admin (Diskussion | Beiträge) Keine Bearbeitungszusammenfassung |
||
| Zeile 623: | Zeile 623: | ||
a:hover { color: #1c4d7d !important; } | a:hover { color: #1c4d7d !important; } | ||
img { filter: none !important; } | img { filter: none !important; } | ||
} | |||
/* ==== Mobile-Fix: Bild vollständig anzeigen ==== */ | |||
@media (max-width: 640px) { | |||
/* Einspaltig hast du bereits – hier die Bilddarstellung */ | |||
.mw-wnews-thumb { | |||
background: #000; /* schwarzer Rand falls Seitenverhältnis abweicht */ | |||
display: flex; | |||
align-items: center; | |||
justify-content: center; | |||
} | |||
/* Vorher war: height: 200/220px + object-fit: cover */ | |||
.mw-wnews-thumb img { | |||
width: 100%; | |||
height: auto !important; /* fixe Höhe überschreiben */ | |||
max-height: 60vh; /* nicht höher als 60% der Bildschirmhöhe */ | |||
object-fit: contain !important; /* ganzes Bild zeigen, ohne Beschnitt */ | |||
} | |||
} | } | ||
Version vom 16. Oktober 2025, 22:43 Uhr
/* Das folgende CSS wird für alle Benutzeroberflächen geladen. */
/* --- Layout für die drei Bewertungsboxen --- */
.whisky-rating {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
gap: 14px;
margin: 1rem 0 1.5rem;
}
.whisky-rating__item {
border: 1px solid #e5e7eb;
border-radius: 12px;
padding: 12px 14px;
box-shadow: 0 1px 3px rgba(0,0,0,.06);
background: #fff;
}
.whisky-rating__label {
font-weight: 600;
margin-bottom: .5rem;
color: #111827;
}
/* --- Container für die Gläser --- */
.whisky-rating__widget {
display: flex; /* flex statt inline-flex */
flex-wrap: wrap; /* erlaubt Umbruch bei kleinen Screens */
align-items: center;
}
/* --- Gläser (Button) --- */
.whisky-glass {
display: inline-block; /* verhindert Überlappungen */
width: 28px;
height: 28px;
margin: 0 6px 6px 0; /* Abstand zwischen den Gläsern */
border: 0;
padding: 0;
background: none;
cursor: pointer;
background-image: url("/index.php?title=Special:FilePath/Whisky_empty.png");
background-size: contain;
background-repeat: no-repeat;
background-position: center;
line-height: 0;
vertical-align: middle;
box-sizing: content-box;
opacity: .8;
transition: opacity .08s ease, filter .08s ease;
}
/* --- Aktive (gefüllte) Gläser --- */
.whisky-glass.is-active {
background-image: url("/index.php?title=Special:FilePath/Whisky_filled.png");
opacity: 1;
}
/* --- Hover/Fokus-Effekt --- */
.whisky-glass:hover,
.whisky-glass:focus {
opacity: 1;
outline: none;
filter: drop-shadow(0 0 0.4px rgba(0,0,0,.25));
}
/* --- Textbereich unter den Gläsern --- */
.whisky-rating__meta {
margin-top: .4rem;
font-size: .9rem;
color: #4b5563;
}
/* --- Zustand: nicht eingeloggt --- */
.whisky-rating--disabled .whisky-glass {
cursor: not-allowed;
filter: grayscale(0.3) opacity(.5);
}
/* --- Mobile: kleinere Gläser --- */
@media (max-width: 420px) {
.whisky-glass { width: 26px; height: 26px; margin: 0 5px 5px 0; }
}
.whisky-overall-badge {
display: inline-block;
margin-left: .5rem;
padding: .1rem .45rem;
border-radius: .5rem;
background: #111827;
color: #fff;
font-weight: 600;
font-size: .95rem;
line-height: 1.2;
}
/* Tabelle für Whisky-Bewertungen */
.whisky-summary__table {
border-collapse: collapse;
margin-top: 0.5em;
width: auto; /* oder 100% */
}
.whisky-summary__table th,
.whisky-summary__table td {
padding: 0.4em 0.8em;
text-align: left;
}
.whisky-summary__table th {
background: #f5f5f5;
font-weight: 600;
}
.whisky-summary__table tr:nth-child(even) td {
background: #fafafa;
}
/* Letzte Zeile (Gesamt) hervorheben */
.whisky-summary__table tr:last-child td {
padding-top: 0.6em;
padding-bottom: 0.6em;
border-top: 2px solid #333;
font-weight: bold;
background: #fff9e6;
}
/* Whisky Ø-Balken */
.whisky-bar {
display: flex;
align-items: center;
gap: .5rem;
min-width: 160px; /* Platz für den Balken */
}
.whisky-bar__track {
position: relative;
flex: 1 1 auto;
height: 10px;
background: #ececec;
border-radius: 999px;
overflow: hidden;
box-shadow: inset 0 1px 2px rgba(0,0,0,.06);
}
.whisky-bar__fill {
height: 100%;
width: 0%;
border-radius: 999px;
background: linear-gradient(90deg, #f0b429, #d97706); /* bernstein */
transition: width .35s ease;
}
.whisky-bar__value {
font-variant-numeric: tabular-nums;
min-width: 3ch; /* z. B. “7.5” */
text-align: right;
}
/* bessere Touch-Fläche */
.whisky-rating__widget {
display: flex;
gap: 6px;
flex-wrap: wrap;
}
/* Buttons: Größe & Klickfläche, aber Bild erhalten */
.whisky-glass {
width: 36px;
height: 36px;
padding: 0;
border: none;
background-color: transparent; /* NICHT: background: transparent; */
touch-action: manipulation;
/* falls noch nicht gesetzt: */
background-repeat: no-repeat;
background-position: center;
background-size: contain; /* oder 100% 100% */
display: inline-block; /* sicherheitshalber */
cursor: pointer;
}
@media (max-width: 480px) {
.whisky-glass { width: 32px; height: 32px; }
}
/* ===== Overlay & Modal ===== */
.mw-popup-overlay {
position: fixed;
inset: 0;
background: rgba(0,0,0,0.45);
z-index: 10000;
}
.mw-popup-modal {
position: fixed;
top: 50%; left: 50%;
transform: translate(-50%, -50%);
background: #fff;
max-width: 96%;
width: 640px;
padding: 20px 24px 24px;
border-radius: 12px;
z-index: 10001;
text-align: center;
box-shadow: 0 10px 28px rgba(0,0,0,0.35);
max-height: 94vh;
overflow-y: auto;
}
/* ===== Fireworks Canvas Bereich (oben) ===== */
/* ===== Overlay & Modal ===== */
.mw-popup-overlay {
position: fixed;
inset: 0;
background: rgba(0,0,0,0.45);
z-index: 10000;
}
.mw-popup-modal {
position: fixed;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
background: #fff;
max-width: 96%;
width: 720px;
padding: 24px 28px 34px;
border-radius: 14px;
z-index: 10001;
text-align: center;
box-shadow: 0 10px 28px rgba(0,0,0,0.35);
max-height: 94vh;
overflow-y: auto;
}
/* Overlay & Modal (verwende deine bestehende Popup-Optik gern weiter) */
.mw-popup-overlay {
position: fixed;
inset: 0;
background: rgba(0,0,0,0.45);
z-index: 10000;
}
.mw-popup-modal {
position: fixed;
top: 50%; left: 50%;
transform: translate(-50%, -50%);
background: #fff;
max-width: 96%;
width: 760px;
padding: 20px 24px 26px;
border-radius: 14px;
z-index: 10001;
text-align: center;
box-shadow: 0 10px 28px rgba(0,0,0,0.35);
max-height: 94vh;
overflow-y: auto;
}
/* Whisky-Canvas Bühne */
.mw-fw-canvas-wrap {
position: relative;
height: 260px;
margin: -8px -8px 14px;
border-radius: 10px;
overflow: hidden;
background: radial-gradient(ellipse at center, #0b1c38 0%, #061025 60%, #03060d 100%);
box-shadow: inset 0 0 30px rgba(0,0,0,0.65);
}
.mw-fw-canvas { display:block; width:100%; height:100%; }
/* Headline & Intro */
.mw-popup-modal h2 {
margin: 8px 0 6px;
font-size: 1.35em;
}
.mw-popup-content p {
margin: 0.5em 0;
font-size: 1.06em;
line-height: 1.5;
}
/* Kartenlayout für die zwei Abfüllungen */
.mw-wnews-cards {
margin-top: 10px;
display: grid;
grid-template-columns: 1fr 1fr;
gap: 12px;
}
.mw-wnews-card {
display: grid;
grid-template-rows: auto auto;
background: #f8f9fa;
border: 1px solid #e3e6e8;
border-radius: 10px;
text-decoration: none;
color: inherit;
overflow: hidden;
transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.mw-wnews-card:hover {
transform: translateY(-2px);
box-shadow: 0 8px 18px rgba(0,0,0,.12);
border-color: #d5dadd;
}
.mw-wnews-thumb img {
display:block;
width:100%;
height: 220px;
object-fit: cover;
}
.mw-wnews-meta {
padding: 10px 12px;
display:flex;
flex-direction:column;
gap: 6px;
}
.mw-wnews-title {
font-weight: 700;
font-size: 1.02em;
}
.mw-wnews-cta {
color: #36c;
font-weight: 600;
}
/* Button-Reihe */
.mw-popup-button-row {
display:flex; justify-content:center; gap:10px; margin-top: 12px; flex-wrap: wrap;
}
.mw-popup-close {
padding: 10px 16px;
border: none;
background: #36c;
color: #fff;
border-radius: 6px;
cursor: pointer;
font-size: 1em;
}
.mw-popup-close:hover { background:#258; }
/* Mobil */
@media (max-width: 640px) {
.mw-popup-modal { width: calc(100% - 20px); padding: 16px; }
.mw-fw-canvas-wrap { height: 220px; margin: -6px -6px 10px; }
.mw-wnews-cards { grid-template-columns: 1fr; }
.mw-wnews-thumb img { height: 200px; }
}
-----------------------------------------------------------------------------------
/* Top-5 Widget */
.whisky-top5 {
background: #fff;
border: 1px solid #eee;
border-radius: 12px;
padding: 12px;
box-shadow: 0 2px 8px rgba(0,0,0,.04);
}
.whisky-top5__item {
display: grid;
grid-template-columns: auto 1fr auto;
gap: 8px 12px;
align-items: center;
padding: 8px 4px;
border-bottom: 1px dashed #eee;
}
.whisky-top5__item:last-child { border-bottom: 0; }
.whisky-top5__rank {
width: 28px; height: 28px;
border-radius: 999px;
background: #fff1c7;
color: #7a4b00;
font-weight: 700;
display: flex; align-items: center; justify-content: center;
}
.whisky-top5__name a { text-decoration: none; color: #111; }
.whisky-top5__name a:hover { text-decoration: underline; }
/* kleiner Ø-Balken */
.whisky-mini {
display: flex; align-items: center; gap: .5rem;
}
.whisky-mini__track {
flex: 1 1 140px; height: 8px; background: #ececec; border-radius: 999px; overflow: hidden;
box-shadow: inset 0 1px 2px rgba(0,0,0,.06);
}
.whisky-mini__fill {
height: 100%; width: 0%;
background: linear-gradient(90deg, #f0b429, #d97706);
transition: width .35s ease;
}
.whisky-mini__val {
min-width: 3.2ch; text-align: right; font-variant-numeric: tabular-nums;
color: #222;
}
.whisky-top5__votes { color: #666; font-size: .9em; }
-----------------------------------------------------------------------------------
/* Layout Helpers */
.grid { display: grid; gap: 1rem; }
.grid-2 { grid-template-columns: 1fr; }
@media (min-width: 900px) { .grid-2 { grid-template-columns: 1.2fr 0.8fr; } }
.col { display: flex; flex-direction: column; gap: 1rem; }
.card {
background: #fff;
border: 1px solid #e6e6e6;
border-radius: 14px;
padding: 1rem 1.2rem;
box-shadow: 0 1px 3px rgba(0,0,0,.04);
}
.card > h2 { margin-top: 0; }
/* Hero */
.hero { background: linear-gradient(180deg,#f6f6f6,#ffffff); border: 1px solid #eee; border-radius: 16px; }
.hero-content { padding: 1.2rem 1.4rem; text-align: center; }
.hero h1 { margin: .2rem 0; font-size: 2rem; }
.hero-actions a {
display: inline-block; margin: .25rem; padding: .4rem .7rem; border: 1px solid #ddd;
border-radius: 999px; text-decoration: none; background: #fff;
}
.hero-actions a:hover { background: #f5f5f5; }
/* Lists & Pills */
.list.compact .news-item { display: flex; gap: .6rem; padding: .25rem 0; border-bottom: 1px dashed #eee; }
.list.compact .news-item:last-child { border-bottom: 0; }
.news-item .date { font-variant-numeric: tabular-nums; color:#666; min-width: 7ch; }
.pill-list a {
display:inline-block; margin:.25rem; padding:.35rem .7rem; border:1px solid #ddd; border-radius:999px; text-decoration:none;
}
.pill-list a:hover { background:#f8f8f8; }
/* Whisky cards */
.whisky-card { display: grid; grid-template-columns: 140px 1fr; gap: .9rem; align-items: start; }
.whisky-card .whisky-media img { border-radius: 10px; }
.whisky-card h3 { margin:.2rem 0; }
.whisky-card .meta { color:#666; font-size:.95rem; }
.whisky-card .note { margin:.4rem 0 0; }
.whisky-mini { display: block; padding:.35rem 0; }
.whisky-mini .dim { color:#666; }
/* Teaser grid (3 columns on wide) */
.teaser-grid { display:grid; grid-template-columns:1fr; gap:.25rem; }
@media (min-width: 700px){ .teaser-grid { grid-template-columns:1fr 1fr 1fr; } }
/* Recent changes block */
.recent-changes { max-height: 360px; overflow:auto; border:1px solid #eee; border-radius:10px; padding:.5rem; background:#fafafa; }
/* Simple star rating (rendered via JS) */
.rating { --stars: 0; position: relative; display:inline-block; font-size: 1.1rem; line-height: 1; }
.rating::before { content: "★★★★★"; letter-spacing: .1rem; color:#ddd; }
.rating::after { content: "★★★★★"; letter-spacing: .1rem; color:#f5b50a; position:absolute; left:0; top:0; width: calc(var(--stars) * 20%); overflow:hidden; }
/* Typo tweaks */
h2, h3 { scroll-margin-top: 80px; }
-----------------------------------------------------------------------------------
/* ===== ADOS: Mobile-first Layout & Styles ===== */
/* Typografie & Basis */
:root {
--bg: #fafafa;
--card: #ffffff;
--muted: #f6f7f8;
--border: #e6e6e6;
--text: #222;
--text-sub: #666;
--link: #2d6ca2;
--link-hover: #1c4d7d;
--radius: 14px;
--shadow: 0 1px 3px rgba(0,0,0,.06);
}
body { background: var(--bg); color: var(--text); line-height: 1.6; }
a { color: var(--link); text-decoration: none; }
a:hover { color: var(--link-hover); text-decoration: underline; }
img { max-width: 100%; height: auto; border-radius: 8px; }
/* Hero */
.ados-hero { text-align: center; padding: .8rem .5rem .3rem; }
.ados-hero h1 { margin: 0 0 .3rem; font-size: clamp(1.45rem, 2.8vw, 2.1rem); }
.ados-hero p { margin: 0 auto .7rem; max-width: 64ch; text-align: justify; }
/* Chips (horizontales Scrollen auf Handy) */
.ados-chips {
display: flex; gap: .5rem; overflow-x: auto; padding: .4rem .2rem .6rem;
scrollbar-width: thin;
}
.ados-chips a, .ados-chips span {
white-space: nowrap; border: 1px solid var(--border); background: var(--card);
padding: .45rem .7rem; border-radius: 999px; box-shadow: var(--shadow);
}
.ados-chips a:hover { background: var(--muted); }
/* Grid (1 Spalte mobil, 2 Spalten ab 900px) */
.ados-grid { display: grid; gap: 12px; }
.col { display: flex; flex-direction: column; gap: 10px; }
@media (min-width: 900px) {
.ados-grid { grid-template-columns: 1.15fr .85fr; align-items: start; }
}
/* Cards */
.card {
background: var(--card);
border: 1px solid var(--border);
border-radius: var(--radius);
box-shadow: var(--shadow);
padding: 12px 14px;
}
.card h2 {
margin: 0 0 .5rem; padding-bottom: .25rem;
border-bottom: 1px solid #eee; font-size: 1.12rem;
}
.card-muted { background: var(--muted); }
/* Listen + News */
.list.compact .news-item {
display: flex; gap: .6rem; padding: .36rem 0;
border-bottom: 1px dashed #eaeaea;
}
.list.compact .news-item:last-child { border-bottom: 0; }
.news-item .date { color: var(--text-sub); min-width: 7ch; font-variant-numeric: tabular-nums; }
/* Pill-Row (Kategorien als Wrap-Zeile) */
.pill-row {
display: flex; flex-wrap: wrap; gap: .45rem .55rem; align-items: center;
}
.pill-row a {
border: 1px solid var(--border); padding: .35rem .6rem; border-radius: 999px; background: var(--card);
}
.pill-row a:hover { background: var(--muted); }
/* Teaser grid */
.teaser-grid { display: grid; gap: .35rem; grid-template-columns: 1fr; }
@media (min-width: 700px) { .teaser-grid { grid-template-columns: repeat(3, 1fr); } }
/* Meta/Hinweis */
.meta, .hint { font-size: 90%; color: var(--text-sub); margin-top: .35rem; }
/* Navigation Einzeiler */
.navline { margin: 0; }
/* Footer */
.ados-footerdate { font-size: 80%; color: #777; margin-top: .6rem; }
.ados-footerinfo {
border-top: 1px solid var(--border); margin-top: .8rem; padding-top: .5rem;
font-size: 92%; color: var(--text-sub);
}
.ados-footernote { text-align: center; font-size: 90%; margin-top: .8rem; color: var(--text-sub); }
/* Touch-friendly auf sehr kleinen Displays */
@media (max-width: 480px) {
.card { padding: 12px; }
.card h2 { font-size: 1.05rem; }
.ados-chips { gap: .4rem; }
.ados-hero p { font-size: .98em; }
}
/* Leichtes Hover-Feedback (nur Desktop) */
@media (pointer: fine) {
.card:hover { box-shadow: 0 6px 18px rgba(0,0,0,.08); transition: box-shadow .2s; }
}
/* Top-5 Widget (neutral, passt egal wie das JS ausgibt) */
.whisky-top5 { padding: .25rem 0; }
.whisky-top5 .item, .whisky-top5 li {
display: flex; justify-content: space-between; align-items: baseline;
gap: .6rem; padding: .35rem 0; border-bottom: 1px dashed #eaeaea;
}
.whisky-top5 .item:last-child, .whisky-top5 li:last-child { border-bottom: 0; }
/* Bevorzugt dunkles Farbschema */
@media (prefers-color-scheme: dark) {
:root {
--bg: #121212; --card: #1c1c1c; --muted: #181818; --border: #313131;
--text: #e8e8e8; --text-sub: #b4b4b4; --link: #86c2ff; --link-hover: #c5e1ff;
--shadow: 0 1px 4px rgba(0,0,0,.6);
}
img { filter: brightness(.95) contrast(1.05); }
}
/* Respektiere reduzierte Animationen */
@media (prefers-reduced-motion: reduce) {
* { animation: none !important; transition: none !important; }
}
-------------------------------------------------
/* ===== Hard Fix: Force Light Mode on iOS/Safari ===== */
html { color-scheme: light !important; } /* sagt Safari: NICHT auto-dunkeln */
@media (prefers-color-scheme: dark) {
/* falls Safari trotzdem toggelt: alles hell halten */
html, body { background: #ffffff !important; color: #222 !important; }
.card, .card-muted,
.whisky-rating__item,
.whisky-top5,
.mw-popup-modal,
.whisky-summary__table th,
.whisky-summary__table td {
background: #ffffff !important;
color: #222 !important;
border-color: #e6e6e6 !important;
box-shadow: 0 1px 3px rgba(0,0,0,.04) !important;
}
.whisky-summary__table tr:nth-child(even) td { background: #fafafa !important; }
.list.compact .news-item { border-bottom-color: #eee !important; }
a { color: #2d6ca2 !important; }
a:hover { color: #1c4d7d !important; }
img { filter: none !important; }
}
/* ==== Mobile-Fix: Bild vollständig anzeigen ==== */
@media (max-width: 640px) {
/* Einspaltig hast du bereits – hier die Bilddarstellung */
.mw-wnews-thumb {
background: #000; /* schwarzer Rand falls Seitenverhältnis abweicht */
display: flex;
align-items: center;
justify-content: center;
}
/* Vorher war: height: 200/220px + object-fit: cover */
.mw-wnews-thumb img {
width: 100%;
height: auto !important; /* fixe Höhe überschreiben */
max-height: 60vh; /* nicht höher als 60% der Bildschirmhöhe */
object-fit: contain !important; /* ganzes Bild zeigen, ohne Beschnitt */
}
}