/* OUN asiakasportaali (DPIA T3, 11.11.2026). Tyyli vanhan lataussivun (legacy/) mukaan. */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --navy: #0F172A; --teal: #21B4A6; --teal-dark: #1a9088; --teal-light: #34d3c4;
  --cream: #F1ECE4; --white: #ffffff; --gray: #64748b; --gray-light: #f8fafc;
  --border: #e2e8f0; --text: #0F172A; --warn-bg: #fef9ec; --warn-border: #f6d860; --warn-text: #92400e;
}
body { font-family: 'Inter', sans-serif; background: var(--navy); color: var(--white); min-height: 100vh; }
.header { padding: 1.25rem 2rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; border-bottom: 1px solid rgba(255,255,255,0.08); }
.logo img { height: 36px; width: auto; display: block; }
.header-right { display: flex; align-items: center; gap: 1rem; font-size: 0.8rem; color: rgba(255,255,255,0.55); flex-wrap: wrap; justify-content: flex-end; }
.lang-switch a { color: rgba(255,255,255,0.45); text-decoration: none; margin-left: 0.5rem; font-weight: 600; }
.lang-switch a[aria-current="true"] { color: var(--teal-light); }
.link-btn { background: none; border: none; color: var(--teal-light); font: inherit; font-weight: 600; cursor: pointer; padding: 0; }
.link-btn:hover { text-decoration: underline; }

.hero { text-align: center; padding: 2.5rem 2rem 1.75rem; }
.hero h1 { font-family: 'Montserrat', sans-serif; font-size: clamp(1.6rem, 4vw, 2.2rem); font-weight: 800; margin-bottom: 0.75rem; line-height: 1.2; }
.hero p { color: rgba(255,255,255,0.65); font-size: 1rem; max-width: 520px; margin: 0 auto; line-height: 1.6; }

.main { max-width: 720px; margin: 0 auto; padding: 0 1.5rem 4rem; }
.card { background: var(--white); border-radius: 16px; padding: 2rem; color: var(--text); margin-bottom: 1.5rem; }
.card-title { font-family: 'Montserrat', sans-serif; font-size: 1.1rem; font-weight: 700; margin-bottom: 0.5rem; color: var(--navy); }
.card-sub { font-size: 0.8rem; color: var(--gray); margin-bottom: 1rem; }
.card-desc { font-size: 0.9rem; color: var(--gray); margin-bottom: 1.25rem; line-height: 1.6; }
.section { border-top: 1px solid var(--border); padding-top: 1.25rem; margin-top: 1.25rem; }
.section-title { font-family: 'Montserrat', sans-serif; font-size: 0.95rem; font-weight: 700; color: var(--navy); margin-bottom: 0.5rem; }
.pill { display: inline-block; font-size: 0.72rem; font-weight: 600; padding: 0.2rem 0.6rem; border-radius: 100px; background: rgba(33,180,166,0.12); color: var(--teal-dark); margin: 0 0.35rem 0.35rem 0; }
.status { font-size: 0.9rem; line-height: 1.6; color: var(--navy); background: var(--gray-light); border-radius: 10px; padding: 0.85rem 1rem; }
.notice { background: var(--warn-bg); border: 1px solid var(--warn-border); color: var(--warn-text); border-radius: 10px; padding: 0.85rem 1rem; font-size: 0.88rem; line-height: 1.6; }

.field-group { display: flex; flex-direction: column; gap: 0.4rem; margin-bottom: 1rem; }
.field-group label { font-size: 0.8rem; font-weight: 600; color: var(--navy); }
.field-group label .req { color: var(--teal); margin-left: 2px; }
.field-group input { padding: 0.7rem 0.9rem; border: 1.5px solid var(--border); border-radius: 8px; font-size: 1rem; font-family: 'Inter', sans-serif; color: var(--text); background: var(--gray-light); }
.field-group input:focus { outline: none; border-color: var(--teal); background: white; }
.field-group input.code { font-family: 'Courier New', monospace; font-size: 1.5rem; letter-spacing: 0.5rem; text-align: center; }
.property-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 520px) { .property-fields { grid-template-columns: 1fr; gap: 0; } }

.doc-list { background: var(--gray-light); border-radius: 10px; padding: 1rem 1.25rem; margin-bottom: 1rem; }
.doc-list-title { font-size: 0.75rem; font-weight: 600; color: var(--gray); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 0.6rem; }
.doc-list ul { list-style: none; }
.doc-list li { padding: 0.35rem 0 0.35rem 1.4rem; font-size: 0.875rem; color: var(--navy); border-bottom: 1px solid var(--border); position: relative; }
.doc-list li:last-child { border-bottom: none; }
.doc-list li::before { content: "\2713"; position: absolute; left: 0; color: var(--teal); font-weight: 700; }

.dropzone { border: 2px dashed var(--border); border-radius: 12px; padding: 1.75rem; text-align: center; cursor: pointer; margin-bottom: 1rem; position: relative; }
.dropzone:hover, .dropzone.dragover { border-color: var(--teal); background: rgba(33,180,166,0.04); }
.dropzone input[type="file"] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.dropzone-title { font-family: 'Montserrat', sans-serif; font-size: 0.9rem; font-weight: 700; color: var(--navy); margin-bottom: 0.25rem; }
.dropzone-sub { font-size: 0.8rem; color: var(--gray); }

.file-list { display: flex; flex-direction: column; gap: 0.5rem; margin-bottom: 1rem; }
.file-item { display: flex; align-items: center; gap: 0.75rem; background: var(--gray-light); border-radius: 8px; padding: 0.6rem 0.75rem; font-size: 0.85rem; }
.file-item-name { flex: 1; color: var(--navy); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-item-size { color: var(--gray); font-size: 0.75rem; flex-shrink: 0; }
.file-status { font-size: 0.72rem; font-weight: 600; padding: 0.2rem 0.55rem; border-radius: 100px; flex-shrink: 0; }
.file-status.waiting { background: rgba(148,163,184,0.2); color: #64748b; }
.file-status.uploading { background: rgba(33,180,166,0.12); color: var(--teal-dark); }
.file-status.done { background: rgba(52,211,153,0.15); color: #059669; }
.file-status.error { background: rgba(239,68,68,0.12); color: #dc2626; }
.file-remove { background: none; border: none; cursor: pointer; color: var(--gray); font-size: 1.1rem; line-height: 1; padding: 0 0.2rem; }
.file-remove:hover { color: #ef4444; }

.progress-bar { height: 4px; background: var(--border); border-radius: 100px; margin-bottom: 1rem; overflow: hidden; }
.progress-fill { height: 100%; background: var(--teal); width: 0%; transition: width 0.3s; }
.error-msg { background: #fef2f2; border: 1px solid #fecaca; color: #dc2626; border-radius: 8px; padding: 0.75rem 1rem; font-size: 0.87rem; margin-bottom: 1rem; }
.info-msg { background: rgba(33,180,166,0.08); border: 1px solid rgba(33,180,166,0.3); color: var(--teal-dark); border-radius: 8px; padding: 0.75rem 1rem; font-size: 0.87rem; margin-bottom: 1rem; }

.btn { width: 100%; padding: 0.95rem; background: var(--teal); color: var(--white); border: none; border-radius: 10px; font-family: 'Montserrat', sans-serif; font-size: 1rem; font-weight: 700; cursor: pointer; }
.btn:hover:not(:disabled) { background: var(--teal-dark); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn.secondary { background: transparent; color: var(--teal-dark); border: 1.5px solid var(--teal); }
.btn-row { display: flex; gap: 0.75rem; margin-top: 0.75rem; flex-wrap: wrap; }
.btn-row .link-btn { color: var(--teal-dark); font-size: 0.85rem; }

.safety { font-size: 0.82rem; color: var(--gray); margin-top: 1rem; line-height: 1.6; font-weight: 600; }
.note { text-align: center; font-size: 0.78rem; color: rgba(255,255,255,0.45); margin-top: 1.5rem; line-height: 1.6; }
.note a { color: rgba(255,255,255,0.7); }
.empty { text-align: center; color: rgba(255,255,255,0.65); padding: 2rem 1rem; line-height: 1.7; }
.loading { text-align: center; color: rgba(255,255,255,0.55); padding: 3rem 1rem; }
footer { text-align: center; padding: 2rem; font-size: 0.78rem; color: rgba(255,255,255,0.3); border-top: 1px solid rgba(255,255,255,0.06); }
footer a { color: rgba(255,255,255,0.4); text-decoration: none; }
[hidden] { display: none !important; }
@media (max-width: 480px) {
  .card { padding: 1.4rem; } .hero { padding: 1.75rem 1.25rem 1.25rem; }
  .main { padding: 0 1rem 3rem; } .header { padding: 1rem; }
}
