Files
lang-quiz/client/src/index.css

645 lines
9.9 KiB
CSS
Raw Normal View History

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;600;700&family=DM+Sans:wght@400;500;700&display=swap');
:root {
font-family: 'DM Sans', 'Space Grotesk', sans-serif;
line-height: 1.6;
font-weight: 400;
color: #0f172a;
background: radial-gradient(circle at 10% 20%, rgba(255, 192, 203, 0.25), transparent 35%),
radial-gradient(circle at 80% 0%, rgba(109, 195, 255, 0.2), transparent 32%),
#f6f7fb;
min-height: 100vh;
--accent: #ff5a3c;
--card: #ffffff;
--border: #e5e7eb;
--muted: #4b5563;
}
* {
box-sizing: border-box;
}
body {
margin: 0;
padding: 0;
color: inherit;
background: inherit;
}
a {
color: inherit;
text-decoration: none;
}
p {
margin: 0;
}
h1,
h2,
h3,
h4 {
margin: 0;
letter-spacing: -0.01em;
}
2026-01-08 01:40:19 +01:00
.container {
max-width: 1080px;
margin: 0 auto;
padding: 0 1rem;
width: 100%;
}
.main {
padding-top: 0.5rem;
}
.page-header {
display: flex;
align-items: flex-start;
justify-content: space-between;
gap: 1rem;
margin: 1rem 0 1.5rem;
}
.eyebrow {
text-transform: uppercase;
font-size: 0.75rem;
letter-spacing: 0.25em;
color: var(--muted);
margin-bottom: 0.35rem;
}
.muted {
color: var(--muted);
}
.grid {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
gap: 1rem;
}
.entry-card {
display: flex;
justify-content: space-between;
align-items: flex-start;
background: var(--card);
padding: 1rem 1rem 0.85rem;
border-radius: 16px;
border: 1px solid var(--border);
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
transition: transform 150ms ease, box-shadow 150ms ease;
gap: 0.5rem;
}
.entry-card:hover {
transform: translateY(-4px);
box-shadow: 0 18px 40px rgba(0, 0, 0, 0.08);
}
.entry-card__content {
flex: 1 1 auto;
min-width: 0;
padding-right: 1rem;
}
.entry-card__title {
font-weight: 700;
line-height: 1.3;
}
.entry-card__actions.inline {
display: flex;
flex-direction: column;
gap: 0.1rem;
align-items: flex-end;
flex: 0 0 auto;
min-width: 0;
}
.entry-link {
font-weight: 700;
color: var(--accent);
}
.pill {
display: inline-flex;
align-items: center;
gap: 0.25rem;
padding: 0.25rem 0.6rem;
border-radius: 999px;
background: rgba(0, 0, 0, 0.06);
font-size: 0.85rem;
font-weight: 600;
}
.pill--ghost {
background: rgba(0, 0, 0, 0.04);
color: var(--muted);
}
.pill--accent {
background: rgba(255, 90, 60, 0.1);
color: #d9482b;
}
.button {
border: 1px solid var(--border);
border-radius: 14px;
padding: 0.65rem 1rem;
background: #fff;
cursor: pointer;
font-weight: 700;
transition: all 120ms ease;
}
.button:hover {
transform: translateY(-1px);
}
.button--primary,
.button--solid {
background: var(--accent);
color: #fff;
border-color: var(--accent);
}
.button--ghost {
background: transparent;
color: inherit;
}
.actions {
display: flex;
gap: 0.75rem;
align-items: center;
}
.video-shell {
margin: 1rem 0;
background: #000;
border-radius: 16px;
overflow: hidden;
box-shadow: 0 14px 30px rgba(0, 0, 0, 0.2);
max-width: 960px;
position: relative;
}
.video-shell video {
width: 100%;
height: auto;
display: block;
aspect-ratio: 9 / 16;
max-height: 75vh;
object-fit: contain;
}
.video-shell.compact {
max-width: 460px;
margin-left: auto;
margin-right: auto;
box-shadow: 0 10px 18px rgba(0, 0, 0, 0.18);
}
.video-overlay {
position: absolute;
inset: 0;
display: flex;
align-items: center;
justify-content: center;
gap: 0.5rem;
background: linear-gradient(180deg, rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.65));
padding: 1rem;
}
.video-overlay .button {
box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}
.video-row {
display: flex;
flex-direction: column;
align-items: center;
gap: 0.5rem;
position: relative;
}
.video-actions {
display: flex;
justify-content: center;
}
.video-cta {
position: absolute;
right: 0;
bottom: 0.5rem;
}
.video-cta .button {
padding: 0.85rem 1.5rem;
font-size: 1.05rem;
}
@media (max-width: 820px) {
.video-row {
align-items: center;
}
.video-cta {
position: static;
}
}
.ig-block {
display: flex;
gap: 0.75rem;
align-items: flex-start;
background: #fff;
padding: 0.85rem 1rem;
border-radius: 14px;
border: 1px solid var(--border);
margin-bottom: 1rem;
}
.ig-avatar {
width: 56px;
height: 56px;
border-radius: 50%;
object-fit: cover;
border: 2px solid #fff;
box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}
.ig-avatar.placeholder {
background: #e5e7eb;
}
.ig-body {
flex: 1;
}
.ig-row {
display: flex;
flex-wrap: wrap;
gap: 0.35rem;
align-items: baseline;
font-weight: 700;
}
.ig-name {
color: inherit;
font-weight: 800;
}
.ig-desc {
margin: 0.35rem 0 0;
white-space: pre-wrap;
}
2026-01-07 23:29:49 +01:00
.ig-desc.expandable .clamped {
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
overflow: hidden;
}
.ig-desc.expandable .full {
white-space: pre-wrap;
}
.link-button {
border: none;
background: transparent;
color: var(--accent);
font-weight: 700;
cursor: pointer;
padding: 0.25rem 0;
}
.crumbs {
margin: 0.5rem 0;
}
.row-between {
display: flex;
justify-content: space-between;
align-items: center;
gap: 0.5rem;
}
.link {
background: transparent;
}
.panel {
margin: 1.5rem 0;
}
.panel-grid {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
gap: 0.75rem;
}
.panel-card {
background: var(--card);
border: 1px solid var(--border);
border-radius: 14px;
padding: 0.85rem;
position: relative;
}
.panel-card__title {
font-weight: 700;
margin-bottom: 0.25rem;
}
.panel-card__body {
color: var(--muted);
font-size: 0.95rem;
}
.tag {
position: absolute;
top: 0.65rem;
right: 0.65rem;
font-size: 0.7rem;
color: var(--muted);
}
.subline {
color: var(--muted);
font-size: 0.9rem;
}
.item-row {
margin-top: 0.35rem;
}
.chips {
display: flex;
flex-wrap: wrap;
gap: 0.35rem;
margin-top: 0.5rem;
}
.loading,
.error {
padding: 1rem;
background: var(--card);
border-radius: 12px;
border: 1px solid var(--border);
color: #111827;
}
.error {
border-color: #ef4444;
}
.input {
width: 100%;
padding: 0.65rem 0.75rem;
border-radius: 12px;
border: 1px solid var(--border);
background: #fff;
font-size: 1rem;
}
.selector {
background: var(--card);
padding: 1rem;
border-radius: 12px;
border: 1px solid var(--border);
margin: 1rem 0;
}
.selector-grid {
max-height: 260px;
overflow: auto;
display: grid;
grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
gap: 0.35rem;
}
.selector-row {
display: flex;
gap: 0.5rem;
align-items: center;
background: #f9fafb;
padding: 0.45rem 0.6rem;
border-radius: 10px;
}
.mode-switch {
display: flex;
gap: 0.65rem;
flex-wrap: wrap;
margin: 1rem 0;
}
.quiz-setup {
background: var(--card);
padding: 1.25rem;
border-radius: 14px;
border: 1px solid var(--border);
box-shadow: 0 12px 28px rgba(0, 0, 0, 0.05);
}
.quiz-runner {
background: var(--card);
padding: 1.25rem;
border-radius: 16px;
border: 1px solid var(--border);
box-shadow: 0 14px 35px rgba(0, 0, 0, 0.05);
}
.quiz-top {
display: flex;
align-items: center;
justify-content: space-between;
gap: 1rem;
}
.score-box {
text-align: right;
}
.score {
font-weight: 800;
}
.question-block {
margin: 1rem 0;
}
.option {
display: flex;
gap: 0.5rem;
align-items: center;
background: #f9fafb;
border-radius: 10px;
padding: 0.5rem 0.75rem;
margin-bottom: 0.35rem;
border: 1px solid transparent;
}
.option.correct {
background: #e6f7ed;
border-color: #b7e4c7;
}
.option.incorrect {
background: #fde8e8;
border-color: #f5b7b1;
}
.matches {
display: flex;
flex-direction: column;
gap: 0.5rem;
}
.match-row {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 0.5rem;
align-items: center;
}
.match-left {
font-weight: 700;
}
.match-row.correct .input {
background: #e6f7ed;
border-color: #b7e4c7;
}
.match-row.incorrect .input {
background: #fde8e8;
border-color: #f5b7b1;
}
.option-hints {
font-size: 0.9rem;
color: var(--muted);
}
.quiz-actions {
display: flex;
gap: 0.5rem;
margin: 0.5rem 0 1rem;
}
.callout {
padding: 0.85rem 1rem;
border-radius: 12px;
border: 1px solid var(--border);
background: #fff6f4;
color: #d9482b;
}
.callout.success {
background: #e5fbef;
color: #0f9d58;
}
.callout.neutral {
background: #f9fafb;
color: #111827;
}
.explanation {
margin-top: 1rem;
padding-top: 0.5rem;
border-top: 1px solid var(--border);
}
2026-01-08 02:22:55 +01:00
.explanation-header {
display: flex;
justify-content: space-between;
align-items: center;
gap: 0.5rem;
margin-bottom: 0.5rem;
}
.explanation-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
gap: 0.75rem;
margin-bottom: 0.75rem;
}
.quiz-finished {
background: var(--card);
padding: 1.5rem;
border-radius: 14px;
border: 1px solid var(--border);
text-align: center;
}
.quiz-finished .actions .button {
2026-01-08 02:55:03 +01:00
font-size: 0.9rem;
padding: 0.5rem 0.9rem;
}
.summary-list {
margin-top: 1rem;
display: flex;
flex-direction: column;
gap: 0.6rem;
text-align: left;
}
.summary-item {
border: 1px solid var(--border);
border-radius: 12px;
padding: 0.75rem;
background: #fff;
}
.summary-item.correct {
border-color: #b7e4c7;
background: #e6f7ed;
}
.summary-item.wrong {
border-color: #f5b7b1;
background: #fde8e8;
}
.summary-item.skipped {
border-color: var(--border);
background: #f9fafb;
}
.summary-top {
display: flex;
justify-content: space-between;
align-items: center;
gap: 0.5rem;
margin-bottom: 0.35rem;
}
.summary-question {
font-weight: 700;
}
.summary-answers {
display: flex;
flex-direction: column;
gap: 0.35rem;
}
@media (max-width: 720px) {
.page-header,
.quiz-top {
flex-direction: column;
align-items: flex-start;
}
.match-row {
grid-template-columns: 1fr;
}
}