remove fullscreen feature and nicely cleanup all CSS

This commit is contained in:
2026-06-11 20:41:17 +02:00
parent 9a54e22bd0
commit 522be1f28b
30 changed files with 12626 additions and 9975 deletions
+618
View File
@@ -0,0 +1,618 @@
/* ============================================================
Calculator page styles
============================================================ */
body {
display: flex;
flex-direction: column;
height: 100vh;
overflow: hidden;
background: #f5f5f5;
}
.page {
flex: 1;
display: flex;
align-items: stretch;
justify-content: center;
padding: 16px;
overflow: hidden;
min-height: 0;
}
.main-card {
background: white;
border-radius: 16px;
box-shadow: 0 8px 32px rgba(0,0,0,0.12);
width: 100%;
max-width: 1400px;
display: flex;
flex-direction: row;
overflow: hidden;
}
/* ── LEFT PANEL ── */
.left-panel {
width: 240px;
flex-shrink: 0;
display: flex;
flex-direction: column;
border-right: 1px solid #e9ecef;
background: #f8f9fa;
}
.left-header {
height: 65px;
padding: 0 16px;
border-bottom: 1px solid #e9ecef;
flex-shrink: 0;
display: flex;
align-items: center;
}
.left-header h3 {
margin: 0;
font-size: 1.05rem;
font-weight: 700;
color: #2c3e50;
line-height: 1;
}
.left-body {
padding: 16px 20px;
display: flex;
flex-direction: column;
gap: 14px;
flex: 1;
}
.setup-field {
display: flex;
flex-direction: column;
gap: 6px;
}
.setup-field label {
font-size: 0.75rem;
font-weight: 700;
color: #6c757d;
text-transform: uppercase;
letter-spacing: 0.4px;
}
.setup-input {
padding: 11px 12px;
border: 2px solid #dee2e6;
border-radius: 8px;
font-size: 1.1rem;
font-weight: 600;
color: #2c3e50;
text-align: center;
background: white;
transition: border-color 0.2s;
outline: none;
width: 100%;
}
.setup-input:focus {
border-color: #28a745;
box-shadow: 0 0 0 3px rgba(40,167,69,0.12);
}
.setup-hint {
font-size: 0.72rem;
color: #adb5bd;
}
.gen-btn {
background: #28a745;
color: white;
border: none;
border-radius: 8px;
padding: 13px;
font-size: 0.95rem;
font-weight: 700;
cursor: pointer;
transition: background 0.2s, transform 0.1s;
width: 100%;
}
.gen-btn:hover:not(:disabled) { background: #1e7e34; }
.gen-btn:disabled { background: #ced4da; cursor: not-allowed; }
.left-utils {
padding: 0 20px 18px;
display: none;
flex-direction: column;
gap: 7px;
flex-shrink: 0;
}
.left-utils.visible { display: flex; }
.util-btn {
padding: 9px 12px;
border-radius: 8px;
font-size: 0.82rem;
font-weight: 600;
cursor: pointer;
transition: all 0.15s;
width: 100%;
text-align: center;
}
.btn-zeros { background: #6c757d; border: 2px solid #6c757d; color: white; }
.btn-zeros:hover { background: #545b62; border-color: #545b62; }
.btn-reset { background: #dc3545; border: 2px solid #dc3545; color: white; }
.btn-reset:hover { background: #b02a37; border-color: #b02a37; }
.btn-print {
background: #6f42c1;
border: 2px solid #6f42c1;
color: white;
padding: 9px 12px;
border-radius: 8px;
font-size: 0.82rem;
font-weight: 600;
cursor: pointer;
transition: all 0.15s;
width: 100%;
text-align: center;
}
.btn-print:hover { background: #59359a; border-color: #59359a; }
/* Display settings */
.display-section {
padding: 14px 20px 18px;
border-top: 1px solid #e9ecef;
display: flex;
flex-direction: column;
gap: 12px;
flex-shrink: 0;
}
.display-section-title {
font-size: 0.75rem;
font-weight: 700;
color: #6c757d;
text-transform: uppercase;
letter-spacing: 0.4px;
}
.display-toggle-row {
display: flex;
align-items: center;
justify-content: space-between;
}
.display-toggle-label {
font-size: 0.88rem;
font-weight: 600;
color: #2c3e50;
}
.toggle-switch { position: relative; width: 42px; height: 24px; flex-shrink: 0; }
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-track {
position: absolute;
inset: 0;
border-radius: 12px;
background: #ced4da;
cursor: pointer;
transition: background 0.2s;
}
.toggle-track::after {
content: '';
position: absolute;
width: 18px;
height: 18px;
border-radius: 50%;
background: white;
top: 3px;
left: 3px;
transition: transform 0.2s;
box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.toggle-switch input:checked + .toggle-track { background: #28a745; }
.toggle-switch input:checked + .toggle-track::after { transform: translateX(18px); }
.display-camera-row {
display: flex;
flex-direction: column;
gap: 6px;
}
.display-camera-row label {
font-size: 0.75rem;
font-weight: 700;
color: #6c757d;
text-transform: uppercase;
letter-spacing: 0.4px;
}
.camera-select {
padding: 9px 12px;
border: 2px solid #dee2e6;
border-radius: 8px;
font-size: 0.9rem;
font-weight: 600;
color: #2c3e50;
background: white;
outline: none;
cursor: pointer;
transition: border-color 0.2s;
width: 100%;
}
.camera-select:focus { border-color: #28a745; }
.camera-select:disabled { opacity: 0.45; cursor: not-allowed; }
/* ── MIDDLE PANEL ── */
.middle-panel {
flex: 1;
display: flex;
flex-direction: column;
min-width: 0;
overflow: hidden;
border-right: 1px solid #e9ecef;
}
.name-bar {
height: 65px;
display: flex;
align-items: center;
gap: 10px;
padding: 0 16px;
border-bottom: 1px solid #e9ecef;
background: #f8f9fa;
flex-shrink: 0;
}
.name-bar-label {
font-size: 0.75rem;
font-weight: 700;
color: #6c757d;
text-transform: uppercase;
letter-spacing: 0.4px;
white-space: nowrap;
}
.name-input {
flex: 1;
padding: 9px 12px;
border: 2px solid #dee2e6;
border-radius: 8px;
font-size: 0.95rem;
font-weight: 500;
color: #2c3e50;
background: white;
transition: border-color 0.2s;
outline: none;
min-width: 0;
}
.name-input::placeholder { color: #adb5bd; font-weight: 400; }
.name-input:focus { border-color: #28a745; box-shadow: 0 0 0 3px rgba(40,167,69,0.12); }
.middle-empty {
flex: 1;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
color: #adb5bd;
gap: 10px;
font-size: 1rem;
}
.middle-empty .empty-icon { font-size: 3rem; }
.targets-wrapper {
flex: 1;
overflow-y: auto;
overflow-x: hidden;
padding: 14px 16px;
min-height: 0;
display: none;
}
.targets-wrapper.visible { display: block; }
.targets-wrapper::-webkit-scrollbar { width: 6px; }
.targets-wrapper::-webkit-scrollbar-track { background: transparent; }
.targets-wrapper::-webkit-scrollbar-thumb { background: #ced4da; border-radius: 4px; }
.targets-grid { display: grid; gap: 8px; }
.target-group {
border: 2px solid #e9ecef;
border-radius: 8px;
background: #f8f9fa;
display: flex;
flex-direction: column;
overflow: hidden;
transition: border-color 0.15s, background 0.15s;
}
.target-group.completed { border-color: #28a745; background: #f0f8f5; }
.target-num {
background: #e9ecef;
border-bottom: 1px solid #dee2e6;
font-size: 0.72rem;
font-weight: 700;
color: #495057;
text-align: center;
padding: 4px;
flex-shrink: 0;
transition: background 0.15s, color 0.15s;
}
.target-group.completed .target-num {
background: linear-gradient(135deg, #e8f5e8, #c8e6c9);
border-bottom-color: #28a745;
color: #28a745;
}
.shots-col { display: flex; flex-direction: column; gap: 4px; padding: 5px; }
.shot-input {
width: 100%;
padding: 5px 2px;
border: 1.5px solid #dee2e6;
border-radius: 4px;
text-align: center;
font-size: 0.95rem;
font-weight: 700;
color: #333;
background: white;
min-height: 30px;
transition: border-color 0.15s, color 0.15s;
outline: none;
}
.shot-input:focus { border-color: #28a745; box-shadow: 0 0 0 2px rgba(40,167,69,0.2); }
.shot-input.valid { border-color: #28a745; }
.shot-input.ten { border-color: #ffc107; color: #e6a800; }
/* Add bar */
.add-bar {
display: none;
align-items: center;
gap: 12px;
padding: 12px 16px;
border-top: 2px solid #e9ecef;
background: #f8f9fa;
flex-shrink: 0;
}
.add-bar.visible { display: flex; }
.add-bar-score { display: flex; flex-direction: column; align-items: center; line-height: 1.1; flex-shrink: 0; }
.add-bar-pts { font-size: 1.8rem; font-weight: 800; color: #28a745; line-height: 1; }
.add-bar-tens { font-size: 0.7rem; font-weight: 700; color: #ffc107; }
.add-bar-meta { flex: 1; min-width: 0; }
.add-bar-meta-text { font-size: 0.8rem; color: #6c757d; }
.add-bar-progress { height: 4px; background: #e9ecef; border-radius: 2px; overflow: hidden; margin-top: 4px; }
.add-bar-progress-fill { height: 100%; background: #28a745; border-radius: 2px; transition: width 0.25s ease; }
.btn-add {
background: #007bff;
border: 2px solid #007bff;
color: white;
padding: 11px 20px;
border-radius: 8px;
font-size: 0.9rem;
font-weight: 700;
cursor: pointer;
transition: all 0.15s;
white-space: nowrap;
flex-shrink: 0;
}
.btn-add:hover:not(:disabled) { background: #0056b3; border-color: #0056b3; }
.btn-add:disabled { opacity: 0.4; cursor: not-allowed; }
/* ── RIGHT PANEL: scoreboard ── */
.score-panel {
width: 290px;
flex-shrink: 0;
display: flex;
flex-direction: column;
background: #f8f9fa;
overflow: hidden;
}
.score-header {
height: 65px;
padding: 0 16px;
border-bottom: 1px solid #e9ecef;
display: flex;
align-items: center;
justify-content: space-between;
flex-shrink: 0;
}
.score-header h3 { margin: 0; font-size: 1.05rem; font-weight: 700; color: #2c3e50; }
.score-count {
background: #28a745;
color: white;
font-size: 0.72rem;
font-weight: 700;
padding: 2px 8px;
border-radius: 12px;
}
.score-empty {
flex: 1;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
color: #adb5bd;
gap: 8px;
font-size: 0.88rem;
padding: 20px;
text-align: center;
}
.score-empty .empty-icon { font-size: 2.4rem; }
.score-list {
flex: 1;
overflow-y: auto;
padding: 10px;
display: flex;
flex-direction: column;
gap: 6px;
}
.score-list::-webkit-scrollbar { width: 5px; }
.score-list::-webkit-scrollbar-track { background: transparent; }
.score-list::-webkit-scrollbar-thumb { background: #ced4da; border-radius: 4px; }
.score-row {
display: flex;
align-items: center;
gap: 7px;
padding: 8px 10px;
background: white;
border: 2px solid #e9ecef;
border-radius: 10px;
animation: slideIn 0.2s ease;
}
@keyframes slideIn {
from { opacity: 0; transform: translateX(10px); }
to { opacity: 1; transform: translateX(0); }
}
.score-row.rank-1 { border-color: #ffc107; background: #fffdf0; }
.score-row.rank-2 { border-color: #adb5bd; background: #f9f9f9; }
.score-row.rank-3 { border-color: #cd7f32; background: #fdf7f2; }
.rank-badge {
width: 26px;
height: 26px;
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
font-size: 0.72rem;
font-weight: 800;
flex-shrink: 0;
background: #e9ecef;
color: #495057;
}
.score-row.rank-1 .rank-badge { background: #ffc107; color: #7a5800; }
.score-row.rank-2 .rank-badge { background: #adb5bd; color: #343a40; }
.score-row.rank-3 .rank-badge { background: #cd7f32; color: white; }
.score-name {
flex: 1;
min-width: 0;
font-size: 0.88rem;
font-weight: 600;
color: #2c3e50;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
cursor: pointer;
}
.score-name:hover { color: #f97316; }
.score-tens { font-size: 0.7rem; font-weight: 700; color: #ffc107; flex-shrink: 0; white-space: nowrap; }
.score-pts { font-size: 1.05rem; font-weight: 800; color: #28a745; flex-shrink: 0; }
.score-del {
background: none;
border: none;
cursor: pointer;
color: #ced4da;
font-size: 0.95rem;
padding: 2px 4px;
border-radius: 4px;
transition: color 0.15s, background 0.15s;
flex-shrink: 0;
line-height: 1;
}
.score-del:hover { color: #dc3545; background: #fff0f0; }
.score-footer { padding: 10px 10px 0; border-top: 1px solid #e9ecef; flex-shrink: 0; }
.score-print-footer { padding: 8px 10px 10px; flex-shrink: 0; }
.btn-clear-board {
width: 100%;
padding: 9px;
border-radius: 8px;
border: 2px solid #dc3545;
background: #dc3545;
color: white;
font-size: 0.82rem;
font-weight: 600;
cursor: pointer;
transition: all 0.15s;
}
.btn-clear-board:hover { background: #b02a37; border-color: #b02a37; }
/* ── PRINT ── */
@media print {
.navbar, .left-panel, .middle-panel, .score-panel,
.page, .main-card, body > *:not(#printLayout) { display: none !important; }
body {
background: white !important;
overflow: visible !important;
height: auto !important;
margin: 0;
padding: 0;
}
#printLayout {
display: block !important;
padding: 24px 32px;
color: #333;
}
.pl-header {
display: flex;
align-items: center;
gap: 18px;
padding-bottom: 14px;
border-bottom: 2px solid #dee2e6;
margin-bottom: 18px;
}
.pl-logo { height: 52px; width: auto; object-fit: contain; }
.pl-titles { display: flex; flex-direction: column; gap: 2px; }
.pl-title { font-size: 20pt; font-weight: 800; color: #2c3e50; line-height: 1.1; }
.pl-subtitle { font-size: 10pt; color: #6c757d; }
.pl-meta { margin-left: auto; text-align: right; font-size: 9pt; color: #6c757d; line-height: 1.6; }
.pl-table { width: 100%; border-collapse: collapse; font-size: 11pt; }
.pl-table thead tr { background: #f8f9fa; border-bottom: 2px solid #dee2e6; }
.pl-table th {
padding: 8px 12px;
text-align: left;
font-size: 8pt;
font-weight: 700;
text-transform: uppercase;
letter-spacing: 0.4px;
color: #495057;
}
.pl-table th.right { text-align: right; }
.pl-table td { padding: 9px 12px; border-bottom: 1px solid #f1f3f4; color: #333; }
.pl-table td.right { text-align: right; }
.pl-table tbody tr:nth-child(1) td { background: #fffdf0; }
.pl-table tbody tr:nth-child(2) td { background: #f9f9f9; }
.pl-table tbody tr:nth-child(3) td { background: #fdf7f2; }
.pl-rank { font-weight: 700; font-size: 12pt; }
.pl-rank.r1 { color: #b8860b; }
.pl-rank.r2 { color: #6c757d; }
.pl-rank.r3 { color: #8b4513; }
.pl-name { font-weight: 600; }
.pl-score { font-weight: 800; font-size: 13pt; color: #28a745; }
.pl-tens { font-weight: 700; color: #856404; }
}