Files
wtc.waiswuaschd.de/app/static/style.css
T

1086 lines
20 KiB
CSS
Executable File

/* ==========================================================================
What To Cook? - Mobile-First Modern Theme
========================================================================== */
:root {
--bg-main: #0f141c;
--bg-card: #18202c;
--bg-card-hover: #202b3b;
--bg-input: #121822;
--border-color: #2b3648;
--border-focus: #ff7849;
--primary: #ff6b35;
--primary-hover: #fa5719;
--primary-light: rgba(255, 107, 53, 0.15);
--accent: #2ec4b6;
--accent-light: rgba(46, 196, 182, 0.15);
--text-main: #f8fafc;
--text-muted: #94a3b8;
--text-dim: #64748b;
--effort-gering: #10b981;
--effort-gering-bg: rgba(16, 185, 129, 0.15);
--effort-mittel: #f59e0b;
--effort-mittel-bg: rgba(245, 158, 11, 0.15);
--effort-hoch: #ef4444;
--effort-hoch-bg: rgba(239, 68, 68, 0.15);
--danger: #ef4444;
--danger-hover: #dc2626;
--radius-sm: 8px;
--radius-md: 14px;
--radius-lg: 20px;
--radius-pill: 9999px;
--shadow-sm: 0 2px 4px rgba(0,0,0,0.25);
--shadow-md: 0 8px 24px rgba(0,0,0,0.35);
--shadow-glow: 0 0 20px rgba(255, 107, 53, 0.3);
--font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
--safe-bottom: env(safe-area-inset-bottom, 16px);
}
/* Reset & Base */
*, *::before, *::after {
box-sizing: border-box;
margin: 0;
padding: 0;
}
body {
font-family: var(--font-family);
background-color: var(--bg-main);
color: var(--text-main);
line-height: 1.5;
-webkit-font-smoothing: antialiased;
min-height: 100vh;
padding-bottom: calc(85px + var(--safe-bottom));
}
.app-container {
max-width: 680px;
margin: 0 auto;
min-height: 100vh;
display: flex;
flex-direction: column;
}
/* Header */
.app-header {
position: sticky;
top: 0;
z-index: 100;
background: rgba(15, 20, 28, 0.92);
backdrop-filter: blur(12px);
-webkit-backdrop-filter: blur(12px);
border-bottom: 1px solid var(--border-color);
padding: 12px 16px;
display: flex;
flex-direction: column;
gap: 12px;
}
.brand {
display: flex;
align-items: center;
gap: 10px;
}
.brand-icon {
font-size: 2rem;
line-height: 1;
filter: drop-shadow(0 2px 8px rgba(255, 107, 53, 0.4));
}
.brand-title {
font-size: 1.35rem;
font-weight: 800;
letter-spacing: -0.02em;
color: #fff;
background: linear-gradient(135deg, #fff 40%, #ff9e7d);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
}
.brand-subtitle {
font-size: 0.8rem;
color: var(--text-muted);
}
/* Tabs */
.nav-tabs {
display: flex;
background: var(--bg-input);
padding: 4px;
border-radius: var(--radius-pill);
border: 1px solid var(--border-color);
}
.nav-tab {
flex: 1;
background: transparent;
border: none;
color: var(--text-muted);
font-size: 0.9rem;
font-weight: 600;
padding: 8px 12px;
border-radius: var(--radius-pill);
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
gap: 6px;
transition: all 0.2s ease;
}
.nav-tab.active {
background: var(--primary);
color: #fff;
box-shadow: 0 2px 10px rgba(255, 107, 53, 0.35);
}
/* Main Layout */
.app-main {
padding: 16px;
flex: 1;
}
.tab-panel {
display: none;
animation: fadeIn 0.25s ease;
}
.tab-panel.active {
display: block;
}
@keyframes fadeIn {
from { opacity: 0; transform: translateY(6px); }
to { opacity: 1; transform: translateY(0); }
}
/* Info Card */
.info-card {
background: var(--bg-card);
border: 1px solid var(--border-color);
border-radius: var(--radius-md);
padding: 12px 14px;
margin-bottom: 16px;
display: flex;
align-items: center;
justify-content: space-between;
gap: 12px;
font-size: 0.85rem;
}
.info-content {
display: flex;
align-items: center;
gap: 10px;
color: var(--text-muted);
}
.info-icon {
font-size: 1.4rem;
}
.active-counter-badge {
background: var(--accent-light);
color: var(--accent);
font-weight: 700;
font-size: 0.75rem;
padding: 4px 10px;
border-radius: var(--radius-pill);
white-space: nowrap;
border: 1px solid rgba(46, 196, 182, 0.3);
}
/* Slots List */
.slots-container {
display: flex;
flex-direction: column;
gap: 14px;
margin-bottom: 24px;
}
/* Dish Slot Card */
.slot-card {
background: var(--bg-card);
border: 1px solid var(--border-color);
border-radius: var(--radius-md);
padding: 16px;
transition: border-color 0.2s, box-shadow 0.2s, opacity 0.2s;
}
.slot-card.active {
border-color: rgba(255, 107, 53, 0.4);
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}
.slot-card.inactive {
opacity: 0.65;
background: rgba(24, 32, 44, 0.5);
border-style: dashed;
}
.slot-card-header {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 12px;
padding-bottom: 10px;
border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.slot-title-group {
display: flex;
align-items: center;
gap: 8px;
}
.slot-number-badge {
background: var(--primary);
color: #fff;
font-size: 0.75rem;
font-weight: 800;
width: 24px;
height: 24px;
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
}
.slot-card.inactive .slot-number-badge {
background: var(--text-dim);
}
.slot-name {
font-size: 1rem;
font-weight: 700;
}
/* Toggle Switch */
.slot-toggle-label {
display: flex;
align-items: center;
gap: 8px;
cursor: pointer;
user-select: none;
font-size: 0.8rem;
color: var(--text-muted);
}
.switch {
position: relative;
display: inline-block;
width: 44px;
height: 24px;
}
.switch input {
opacity: 0;
width: 0;
height: 0;
}
.slider {
position: absolute;
cursor: pointer;
top: 0; left: 0; right: 0; bottom: 0;
background-color: var(--bg-input);
border: 1px solid var(--border-color);
transition: 0.25s;
border-radius: 24px;
}
.slider:before {
position: absolute;
content: "";
height: 18px;
width: 18px;
left: 2px;
bottom: 2px;
background-color: var(--text-muted);
transition: 0.25s;
border-radius: 50%;
}
input:checked + .slider {
background-color: var(--primary);
border-color: var(--primary);
}
input:checked + .slider:before {
transform: translateX(20px);
background-color: #fff;
}
/* Card Body Inputs */
.slot-body {
display: flex;
flex-direction: column;
gap: 12px;
}
.slot-card.inactive .slot-body {
pointer-events: none;
opacity: 0.4;
}
.form-group {
display: flex;
flex-direction: column;
gap: 6px;
}
.form-label {
font-size: 0.78rem;
font-weight: 600;
color: var(--text-muted);
text-transform: uppercase;
letter-spacing: 0.04em;
}
/* Select Box */
.custom-select, .text-input {
width: 100%;
background: var(--bg-input);
border: 1px solid var(--border-color);
color: var(--text-main);
padding: 10px 14px;
border-radius: var(--radius-sm);
font-size: 0.95rem;
font-family: inherit;
outline: none;
transition: border-color 0.2s, box-shadow 0.2s;
appearance: none;
-webkit-appearance: none;
}
.custom-select {
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2394a3b8'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
background-repeat: no-repeat;
background-position: right 12px center;
background-size: 18px;
padding-right: 36px;
}
.custom-select:focus, .text-input:focus {
border-color: var(--border-focus);
box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.2);
}
/* Effort Multi-Select Chips */
.effort-chips-group {
display: flex;
gap: 8px;
}
.effort-chip {
flex: 1;
background: var(--bg-input);
border: 1px solid var(--border-color);
color: var(--text-muted);
padding: 8px 6px;
border-radius: var(--radius-sm);
font-size: 0.8rem;
font-weight: 600;
cursor: pointer;
text-align: center;
user-select: none;
transition: all 0.2s ease;
display: flex;
align-items: center;
justify-content: center;
gap: 4px;
}
.effort-chip.selected[data-effort="gering"] {
background: var(--effort-gering-bg);
border-color: var(--effort-gering);
color: var(--effort-gering);
font-weight: 700;
}
.effort-chip.selected[data-effort="mittel"] {
background: var(--effort-mittel-bg);
border-color: var(--effort-mittel);
color: var(--effort-mittel);
font-weight: 700;
}
.effort-chip.selected[data-effort="hoch"] {
background: var(--effort-hoch-bg);
border-color: var(--effort-hoch);
color: var(--effort-hoch);
font-weight: 700;
}
/* Action Bar Floating/Sticky at bottom */
.action-bar-wrapper {
position: fixed;
bottom: 0;
left: 0;
right: 0;
background: linear-gradient(to top, rgba(15, 20, 28, 0.98) 60%, rgba(15, 20, 28, 0));
padding: 12px 16px calc(14px + var(--safe-bottom)) 16px;
z-index: 90;
display: flex;
justify-content: center;
}
.action-bar-wrapper .btn-hero {
max-width: 648px;
width: 100%;
}
/* Buttons */
.btn {
display: inline-flex;
align-items: center;
justify-content: center;
gap: 8px;
font-family: inherit;
font-size: 0.95rem;
font-weight: 700;
padding: 12px 18px;
border-radius: var(--radius-md);
border: none;
cursor: pointer;
transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
text-decoration: none;
user-select: none;
}
.btn:active {
transform: scale(0.97);
}
.btn-primary {
background: var(--primary);
color: #fff;
box-shadow: 0 4px 14px rgba(255, 107, 53, 0.4);
}
.btn-primary:hover {
background: var(--primary-hover);
box-shadow: 0 6px 20px rgba(255, 107, 53, 0.5);
}
.btn-hero {
padding: 15px 24px;
font-size: 1.1rem;
border-radius: var(--radius-pill);
}
.btn-secondary {
background: var(--bg-card-hover);
color: var(--text-main);
border: 1px solid var(--border-color);
}
.btn-secondary:hover {
background: var(--border-color);
}
.btn-outline {
background: transparent;
color: var(--text-main);
border: 1px solid var(--border-color);
}
.btn-outline:hover {
background: rgba(255, 255, 255, 0.06);
border-color: var(--text-muted);
}
.btn-danger {
background: var(--danger);
color: #fff;
}
.btn-danger:hover {
background: var(--danger-hover);
}
.btn-sm {
padding: 6px 12px;
font-size: 0.8rem;
border-radius: var(--radius-sm);
}
/* Results Section */
.results-section {
margin-top: 10px;
margin-bottom: 30px;
scroll-margin-top: 120px;
}
.results-section.hidden {
display: none;
}
.results-header {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 16px;
}
.results-title-group {
display: flex;
align-items: center;
gap: 10px;
}
.results-title {
font-size: 1.25rem;
font-weight: 800;
}
.results-badge {
background: var(--primary-light);
color: var(--primary);
font-size: 0.75rem;
font-weight: 700;
padding: 3px 8px;
border-radius: var(--radius-pill);
}
.results-grid {
display: flex;
flex-direction: column;
gap: 14px;
margin-bottom: 20px;
}
/* Result Card */
.result-card {
background: var(--bg-card);
border: 1px solid var(--border-color);
border-radius: var(--radius-md);
padding: 16px;
display: flex;
flex-direction: column;
gap: 12px;
position: relative;
overflow: hidden;
box-shadow: var(--shadow-sm);
transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}
.result-card:hover {
border-color: rgba(255, 107, 53, 0.5);
box-shadow: var(--shadow-md);
}
.result-card.rerolling {
animation: pulseCard 0.4s ease;
}
@keyframes pulseCard {
0% { transform: scale(1); }
50% { transform: scale(0.97); opacity: 0.7; }
100% { transform: scale(1); opacity: 1; }
}
.result-card-top {
display: flex;
align-items: center;
justify-content: space-between;
}
.result-slot-label {
font-size: 0.75rem;
font-weight: 700;
text-transform: uppercase;
letter-spacing: 0.05em;
color: var(--text-dim);
}
.result-dish-name {
font-size: 1.2rem;
font-weight: 800;
color: #fff;
line-height: 1.3;
}
.result-tags {
display: flex;
flex-wrap: wrap;
gap: 8px;
align-items: center;
}
.badge-tag {
font-size: 0.75rem;
font-weight: 700;
padding: 4px 10px;
border-radius: var(--radius-pill);
display: inline-flex;
align-items: center;
gap: 5px;
}
.badge-category {
background: rgba(255, 255, 255, 0.08);
color: #e2e8f0;
border: 1px solid rgba(255, 255, 255, 0.12);
}
.badge-effort-gering {
background: var(--effort-gering-bg);
color: var(--effort-gering);
border: 1px solid rgba(16, 185, 129, 0.3);
}
.badge-effort-mittel {
background: var(--effort-mittel-bg);
color: var(--effort-mittel);
border: 1px solid rgba(245, 158, 11, 0.3);
}
.badge-effort-hoch {
background: var(--effort-hoch-bg);
color: var(--effort-hoch);
border: 1px solid rgba(239, 68, 68, 0.3);
}
.result-card-actions {
display: flex;
justify-content: flex-end;
padding-top: 8px;
border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.btn-reroll-single {
background: var(--bg-input);
border: 1px solid var(--border-color);
color: var(--text-main);
padding: 8px 14px;
font-size: 0.85rem;
border-radius: var(--radius-pill);
display: inline-flex;
align-items: center;
gap: 6px;
cursor: pointer;
transition: all 0.2s;
}
.btn-reroll-single:hover {
background: var(--primary-light);
border-color: var(--primary);
color: #fff;
}
.btn-reroll-single .dice-icon {
display: inline-block;
transition: transform 0.4s ease;
}
.btn-reroll-single.spinning .dice-icon {
animation: spinDice 0.5s ease;
}
@keyframes spinDice {
from { transform: rotate(0deg); }
to { transform: rotate(360deg); }
}
.results-footer {
display: flex;
justify-content: center;
padding: 10px 0;
}
/* ==========================================================================
Admin Section Styles
========================================================================== */
.admin-topbar {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 16px;
gap: 12px;
}
.section-title {
font-size: 1.25rem;
font-weight: 800;
}
.section-desc {
font-size: 0.8rem;
color: var(--text-muted);
}
.admin-filters-card {
background: var(--bg-card);
border: 1px solid var(--border-color);
border-radius: var(--radius-md);
padding: 14px;
margin-bottom: 16px;
display: flex;
flex-direction: column;
gap: 10px;
}
.search-input-wrap {
position: relative;
display: flex;
align-items: center;
}
.search-icon {
position: absolute;
left: 12px;
font-size: 0.95rem;
pointer-events: none;
color: var(--text-dim);
}
.search-input-wrap input {
width: 100%;
background: var(--bg-input);
border: 1px solid var(--border-color);
color: var(--text-main);
padding: 10px 36px 10px 36px;
border-radius: var(--radius-sm);
font-size: 0.9rem;
outline: none;
}
.search-input-wrap input:focus {
border-color: var(--border-focus);
}
.btn-clear {
position: absolute;
right: 10px;
background: transparent;
border: none;
color: var(--text-muted);
cursor: pointer;
padding: 4px;
font-size: 0.9rem;
}
.btn-clear.hidden {
display: none;
}
.filter-row {
display: flex;
gap: 10px;
}
.flex-1 {
flex: 1;
}
.dishes-list-wrap {
display: flex;
flex-direction: column;
gap: 8px;
}
.dishes-list-header {
display: flex;
justify-content: space-between;
font-size: 0.8rem;
font-weight: 700;
color: var(--text-dim);
text-transform: uppercase;
letter-spacing: 0.05em;
padding: 0 4px;
}
.admin-dishes-list {
display: flex;
flex-direction: column;
gap: 8px;
}
.admin-dish-row {
background: var(--bg-card);
border: 1px solid var(--border-color);
border-radius: var(--radius-sm);
padding: 12px 14px;
display: flex;
align-items: center;
justify-content: space-between;
gap: 12px;
transition: border-color 0.2s;
}
.admin-dish-row:hover {
border-color: rgba(255, 255, 255, 0.2);
}
.admin-dish-info {
display: flex;
flex-direction: column;
gap: 4px;
}
.admin-dish-name {
font-weight: 700;
font-size: 0.95rem;
}
.admin-dish-badges {
display: flex;
gap: 6px;
flex-wrap: wrap;
}
.admin-dish-actions {
display: flex;
align-items: center;
gap: 6px;
}
.btn-action-icon {
background: var(--bg-input);
border: 1px solid var(--border-color);
color: var(--text-muted);
width: 34px;
height: 34px;
border-radius: var(--radius-sm);
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
font-size: 0.9rem;
transition: all 0.15s;
}
.btn-action-icon:hover {
background: var(--bg-card-hover);
color: #fff;
border-color: var(--text-muted);
}
.btn-action-icon.btn-delete:hover {
background: var(--danger);
border-color: var(--danger);
color: #fff;
}
/* Modals */
.modal {
border: none;
background: transparent;
padding: 16px;
margin: auto;
max-width: 480px;
width: 100%;
}
.modal::backdrop {
background: rgba(0, 0, 0, 0.75);
backdrop-filter: blur(4px);
}
.modal-box {
background: var(--bg-card);
border: 1px solid var(--border-color);
border-radius: var(--radius-lg);
padding: 22px;
box-shadow: var(--shadow-md);
color: var(--text-main);
display: flex;
flex-direction: column;
gap: 16px;
}
.modal-box-sm {
max-width: 380px;
margin: auto;
}
.modal-header {
display: flex;
align-items: center;
justify-content: space-between;
}
.modal-title {
font-size: 1.15rem;
font-weight: 800;
}
.btn-icon-close {
background: transparent;
border: none;
color: var(--text-muted);
font-size: 1.2rem;
cursor: pointer;
padding: 4px;
}
.form-label-hint {
font-size: 0.75rem;
font-weight: normal;
text-transform: none;
color: var(--text-dim);
}
.category-checkbox-group {
display: flex;
flex-wrap: wrap;
gap: 8px;
margin-top: 4px;
}
.category-checkbox-label {
display: inline-flex;
cursor: pointer;
user-select: none;
}
.category-checkbox-label input {
position: absolute;
opacity: 0;
width: 0;
height: 0;
pointer-events: none;
}
.category-checkbox-label .cat-pill {
display: inline-flex;
align-items: center;
gap: 6px;
padding: 8px 12px;
background: var(--bg-input);
border: 1px solid var(--border-color);
border-radius: var(--radius-pill);
font-size: 0.85rem;
font-weight: 500;
color: var(--text-muted);
transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.category-checkbox-label .cat-pill:hover {
border-color: var(--text-muted);
color: var(--text-main);
}
.category-checkbox-label input:checked + .cat-pill {
background: var(--primary-light);
border-color: var(--primary);
color: var(--primary);
font-weight: 700;
box-shadow: 0 0 0 1px var(--primary);
}
.effort-radio-group {
display: flex;
flex-direction: column;
gap: 8px;
}
.effort-radio-label {
display: flex;
align-items: center;
cursor: pointer;
}
.effort-radio-label input {
display: none;
}
.effort-radio-label .effort-pill {
flex: 1;
padding: 10px 14px;
border-radius: var(--radius-sm);
background: var(--bg-input);
border: 1px solid var(--border-color);
font-size: 0.85rem;
font-weight: 600;
color: var(--text-muted);
transition: all 0.2s;
}
.effort-radio-label input:checked + .effort-pill.effort-gering {
background: var(--effort-gering-bg);
border-color: var(--effort-gering);
color: var(--effort-gering);
font-weight: 700;
}
.effort-radio-label input:checked + .effort-pill.effort-mittel {
background: var(--effort-mittel-bg);
border-color: var(--effort-mittel);
color: var(--effort-mittel);
font-weight: 700;
}
.effort-radio-label input:checked + .effort-pill.effort-hoch {
background: var(--effort-hoch-bg);
border-color: var(--effort-hoch);
color: var(--effort-hoch);
font-weight: 700;
}
.modal-actions {
display: flex;
justify-content: flex-end;
gap: 10px;
margin-top: 8px;
}
/* Toast Notifications */
.toast-container {
position: fixed;
top: 16px;
left: 50%;
transform: translateX(-50%);
z-index: 1000;
display: flex;
flex-direction: column;
gap: 8px;
width: 90%;
max-width: 400px;
pointer-events: none;
}
.toast {
background: var(--bg-card);
border: 1px solid var(--border-color);
color: var(--text-main);
padding: 12px 16px;
border-radius: var(--radius-md);
box-shadow: var(--shadow-md);
font-size: 0.9rem;
display: flex;
align-items: center;
gap: 10px;
animation: slideDown 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28);
}
.toast.toast-success {
border-color: var(--effort-gering);
}
.toast.toast-error {
border-color: var(--effort-hoch);
}
@keyframes slideDown {
from { opacity: 0; transform: translateY(-16px); }
to { opacity: 1; transform: translateY(0); }
}
.loading-spinner {
text-align: center;
padding: 24px;
color: var(--text-muted);
font-size: 0.9rem;
}