HifiPlanet-Builder/style.css
Maaxxs 0446dbf7d0 Add optional AI-powered lookup for cars not in the local database
When a search has no local match, a "Mit KI suchen" button now calls a
PHP backend (api/lookup.php) that asks the Claude API for plausible
cargo-bay dimensions. The API key stays server-side (config.php, gitignored,
see config.example.php) and is never exposed to the browser. The existing
category-based estimate picker remains as a free fallback if the AI call
fails or isn't configured.
2026-08-31 09:50:53 +02:00

531 lines
8.6 KiB
CSS

:root {
--bg: #12151a;
--bg-panel: #1a1e25;
--bg-panel-2: #20252e;
--border: #2b323d;
--text: #e8eaed;
--text-dim: #9aa4b2;
--accent: #ff8a3d;
--accent-2: #4fc3f7;
font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body {
margin: 0;
padding: 0;
background: var(--bg);
color: var(--text);
}
header.top {
padding: 32px 20px 12px;
text-align: center;
}
header.top h1 {
margin: 0 0 6px;
font-size: 1.7rem;
letter-spacing: -0.01em;
}
.subtitle {
margin: 0;
color: var(--text-dim);
font-size: 0.95rem;
}
main {
max-width: 1100px;
margin: 0 auto;
padding: 20px;
}
.search-panel {
position: relative;
max-width: 640px;
margin: 0 auto 24px;
}
.search-box {
display: flex;
gap: 8px;
}
#searchInput {
flex: 1;
padding: 14px 16px;
font-size: 1rem;
background: var(--bg-panel);
border: 1px solid var(--border);
border-radius: 10px;
color: var(--text);
outline: none;
transition: border-color 0.15s;
}
#searchInput:focus {
border-color: var(--accent-2);
}
#randomBtn {
padding: 0 18px;
background: var(--bg-panel-2);
border: 1px solid var(--border);
border-radius: 10px;
color: var(--text);
cursor: pointer;
font-size: 0.9rem;
}
#randomBtn:hover {
border-color: var(--accent);
}
.suggestions {
position: absolute;
top: calc(100% + 6px);
left: 0;
right: 0;
background: var(--bg-panel);
border: 1px solid var(--border);
border-radius: 10px;
overflow: hidden;
z-index: 20;
box-shadow: 0 12px 28px rgba(0,0,0,0.4);
}
.suggestion-item {
padding: 10px 16px;
cursor: pointer;
display: flex;
justify-content: space-between;
gap: 12px;
font-size: 0.92rem;
}
.suggestion-item:hover, .suggestion-item.active {
background: var(--bg-panel-2);
}
.suggestion-item .s-name { color: var(--text); }
.suggestion-item .s-meta { color: var(--text-dim); font-size: 0.82rem; }
.hint-box {
margin-top: 10px;
padding: 10px 14px;
background: rgba(79,195,247,0.08);
border: 1px solid rgba(79,195,247,0.35);
border-radius: 8px;
font-size: 0.88rem;
color: var(--accent-2);
}
.chips {
margin-top: 14px;
display: flex;
flex-wrap: wrap;
gap: 8px;
justify-content: center;
}
.estimate-box {
background: rgba(255,138,61,0.08);
border-color: rgba(255,138,61,0.35);
color: var(--text-dim);
}
.estimate-box p {
margin: 0 0 4px;
font-size: 0.85rem;
}
.estimate-chips {
margin-top: 8px;
}
.estimate-ai-row {
margin: 10px 0;
}
.ai-btn {
width: 100%;
padding: 10px 14px;
border-radius: 8px;
border: 1px solid rgba(255,138,61,0.4);
background: rgba(255,138,61,0.12);
color: var(--text);
font-size: 0.88rem;
font-weight: 600;
cursor: pointer;
}
.ai-btn:hover:not(:disabled) {
background: rgba(255,138,61,0.2);
}
.ai-btn:disabled {
cursor: default;
opacity: 0.7;
}
.estimate-ai-status {
margin: -4px 0 10px;
font-size: 0.82rem;
}
.estimate-or {
margin: 0 0 4px;
font-size: 0.78rem;
opacity: 0.85;
}
.chip {
padding: 6px 12px;
background: var(--bg-panel);
border: 1px solid var(--border);
border-radius: 999px;
font-size: 0.82rem;
color: var(--text-dim);
cursor: pointer;
}
.chip:hover {
color: var(--text);
border-color: var(--accent-2);
}
.content {
display: grid;
grid-template-columns: 280px 1fr;
gap: 20px;
}
@media (max-width: 760px) {
.content { grid-template-columns: 1fr; }
}
.side-col {
display: flex;
flex-direction: column;
gap: 16px;
}
.info-panel, .sub-panel {
background: var(--bg-panel);
border: 1px solid var(--border);
border-radius: 14px;
padding: 20px;
}
.sub-panel h3 {
margin: 0 0 12px;
font-size: 1rem;
}
.sub-presets {
display: flex;
flex-wrap: wrap;
gap: 6px;
margin-bottom: 14px;
}
.sub-presets .chip.active {
color: var(--text);
border-color: var(--accent);
}
.sub-custom {
display: flex;
gap: 10px;
margin-bottom: 14px;
}
.sub-custom label {
flex: 1;
display: flex;
flex-direction: column;
gap: 4px;
font-size: 0.72rem;
color: var(--text-dim);
}
.sub-custom input {
width: 100%;
padding: 8px;
background: var(--bg-panel-2);
border: 1px solid var(--border);
border-radius: 8px;
color: var(--text);
font-size: 0.85rem;
}
.sub-custom span {
display: none;
}
.sub-actions {
display: flex;
gap: 8px;
margin-bottom: 12px;
}
.sub-actions button {
flex: 1;
padding: 10px;
border-radius: 8px;
border: 1px solid var(--border);
background: var(--accent);
color: #1a1206;
font-weight: 600;
cursor: pointer;
font-size: 0.85rem;
}
.sub-actions button.ghost {
background: transparent;
color: var(--text-dim);
}
.sub-actions button.ghost:hover {
color: var(--text);
border-color: var(--accent-2);
}
.sub-status {
padding: 10px 12px;
border-radius: 8px;
font-size: 0.82rem;
margin-bottom: 10px;
line-height: 1.4;
}
.sub-status.ok {
background: rgba(91,214,138,0.1);
border: 1px solid rgba(91,214,138,0.4);
color: #5bd68a;
}
.sub-status.bad {
background: rgba(255,90,90,0.1);
border: 1px solid rgba(255,90,90,0.4);
color: #ff7a7a;
}
.sub-hint {
margin: 0;
font-size: 0.75rem;
color: var(--text-dim);
}
.info-panel h2 {
margin: 0 0 2px;
font-size: 1.25rem;
}
.info-panel .body-type {
color: var(--text-dim);
font-size: 0.85rem;
margin-bottom: 16px;
}
.spec-row {
display: flex;
justify-content: space-between;
padding: 8px 0;
border-top: 1px solid var(--border);
font-size: 0.88rem;
}
.spec-row .label { color: var(--text-dim); }
.spec-row .value { font-weight: 600; }
.legend {
margin-top: 14px;
padding-top: 12px;
border-top: 1px solid var(--border);
display: flex;
flex-direction: column;
gap: 6px;
font-size: 0.78rem;
color: var(--text-dim);
}
.legend .dot {
display: inline-block;
width: 9px;
height: 9px;
border-radius: 3px;
margin-right: 6px;
}
.dot-arch { background: #ff8a3d; }
.dot-case { background: #5bd68a; }
.legend-note {
margin: 14px 0 0;
padding-top: 12px;
border-top: 1px solid var(--border);
font-size: 0.78rem;
color: var(--text-dim);
line-height: 1.5;
}
.estimate-note {
margin: 0 0 14px;
padding: 10px 12px;
border-top: none;
background: rgba(255,138,61,0.08);
border: 1px solid rgba(255,138,61,0.3);
border-radius: 8px;
color: var(--text-dim);
}
.spec-highlight {
background: var(--bg-panel-2);
border-radius: 10px;
padding: 14px;
text-align: center;
margin-bottom: 6px;
}
.spec-highlight .num {
font-size: 2rem;
font-weight: 700;
color: var(--accent);
}
.spec-highlight .unit {
font-size: 0.85rem;
color: var(--text-dim);
}
.viewer-wrap {
position: relative;
background: radial-gradient(circle at 50% 30%, #232935, #12151a 75%);
border: 1px solid var(--border);
border-radius: 14px;
overflow: hidden;
min-height: 420px;
}
.viewer {
width: 100%;
height: 100%;
min-height: 420px;
}
.viewer-hint {
position: absolute;
bottom: 10px;
right: 14px;
font-size: 0.75rem;
color: var(--text-dim);
background: rgba(0,0,0,0.35);
padding: 4px 10px;
border-radius: 999px;
pointer-events: none;
}
.viewer-toolbar {
position: absolute;
top: 12px;
left: 14px;
display: flex;
flex-direction: column;
align-items: flex-start;
gap: 8px;
}
.viewer-toggle {
display: flex;
align-items: center;
gap: 7px;
font-size: 0.78rem;
color: var(--text-dim);
background: rgba(0,0,0,0.35);
padding: 6px 12px;
border-radius: 999px;
cursor: pointer;
user-select: none;
}
.viewer-toggle:hover {
color: var(--text);
}
.viewer-toggle input {
accent-color: var(--accent);
}
.switch-toggle {
display: flex;
align-items: center;
gap: 9px;
font-size: 0.78rem;
color: var(--text);
background: rgba(0,0,0,0.4);
padding: 6px 12px 6px 8px;
border-radius: 999px;
cursor: pointer;
user-select: none;
}
.switch-toggle input {
position: absolute;
opacity: 0;
width: 0;
height: 0;
}
.switch-track {
position: relative;
width: 34px;
height: 19px;
border-radius: 999px;
background: #4a4f58;
transition: background 0.2s;
flex-shrink: 0;
}
.switch-knob {
position: absolute;
top: 2px;
left: 2px;
width: 15px;
height: 15px;
border-radius: 50%;
background: #fff;
transition: transform 0.2s;
}
.switch-toggle input:checked ~ .switch-track {
background: var(--accent);
}
.switch-toggle input:checked ~ .switch-track .switch-knob {
transform: translateX(15px);
}
.switch-label strong {
color: var(--accent);
font-weight: 600;
}
.empty-state {
text-align: center;
color: var(--text-dim);
padding: 60px 20px;
font-size: 0.95rem;
}
footer {
max-width: 1100px;
margin: 20px auto 60px;
padding: 0 20px;
color: var(--text-dim);
font-size: 0.78rem;
line-height: 1.5;
}