/* Arrow–Netbaron-portaali. Kaikki tyylit .arnb-juuren alla, jotta teema ei häiriinny. */
.arnb {
	--arnb-text: #1d2327;
	--arnb-muted: #646970;
	--arnb-line: #dcdcde;
	--arnb-bg: #ffffff;
	--arnb-soft: #f6f7f7;
	--arnb-accent: #2271b1;
	--arnb-good: #00703c;
	--arnb-good-bg: #e6f4ea;
	--arnb-bad: #b32d2e;
	--arnb-bad-bg: #fcebea;
	--arnb-warn: #8a5a00;
	--arnb-warn-bg: #fff4d6;
	--arnb-muted-bg: #f0f0f1;
	color: var(--arnb-text);
	font-size: 15px;
	line-height: 1.45;
	/* Leveät taulukot: irrotetaan teeman kapeasta sisältöpalstasta. */
	width: min(1280px, calc(100vw - 32px));
	max-width: none !important;
	position: relative;
	left: 50%;
	transform: translateX(-50%);
}
.arnb h2, .arnb h3, .arnb h4 { font-family: inherit; }
.arnb *, .arnb *::before, .arnb *::after { box-sizing: border-box; }
.arnb h2 { font-size: 1.4em; margin: 1.2em 0 .5em; }
.arnb h3 { font-size: 1.15em; margin: 0 0 .6em; }
.arnb h4 { font-size: .95em; margin: .8em 0 .35em; }
.arnb h3 small, .arnb h2 small { color: var(--arnb-muted); font-weight: normal; font-size: .8em; }
.arnb small { color: var(--arnb-muted); }
.arnb a { color: var(--arnb-accent); }
.arnb [hidden] { display: none !important; }

/* Navigaatio */
.arnb-nav { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; border-bottom: 1px solid var(--arnb-line); margin-bottom: 16px; }
.arnb-nav a { padding: 10px 14px; text-decoration: none; color: var(--arnb-text); border-bottom: 3px solid transparent; margin-bottom: -1px; }
.arnb-nav a:hover { background: var(--arnb-soft); }
.arnb-nav a.is-active { border-bottom-color: var(--arnb-accent); font-weight: 600; }
.arnb-env { margin-left: auto; font-size: .8em; font-weight: 600; padding: 3px 10px; border-radius: 999px; }
.arnb-env-demo { background: var(--arnb-warn-bg); color: var(--arnb-warn); }
.arnb-env-live { background: var(--arnb-good-bg); color: var(--arnb-good); }

/* Hakupalkki ja ilmoitukset */
.arnb-runbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 10px 14px; background: var(--arnb-soft); border-radius: 6px; margin-bottom: 16px; }
.arnb-progress { color: var(--arnb-accent); font-weight: 600; }
.arnb-progress::before { content: ""; display: inline-block; width: .8em; height: .8em; margin-right: .4em; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; vertical-align: -1px; animation: arnb-spin .8s linear infinite; }
@keyframes arnb-spin { to { transform: rotate(360deg); } }
.arnb-notice { padding: 10px 14px; border-radius: 6px; margin-bottom: 14px; font-weight: 600; }
.arnb-notice.arnb-good { background: var(--arnb-good-bg); color: var(--arnb-good); }
.arnb-notice.arnb-bad { background: var(--arnb-bad-bg); color: var(--arnb-bad); }
.arnb-note { margin-top: 6px; padding: 6px 10px; background: var(--arnb-warn-bg); color: var(--arnb-warn); border-radius: 4px; display: inline-block; }
.arnb-callout { padding: 12px 14px; margin: 0 0 16px; background: var(--arnb-warn-bg); border-left: 4px solid var(--arnb-warn); border-radius: 4px; }
.arnb-help { color: var(--arnb-muted); font-size: .9em; margin: .3em 0 .8em; }
.arnb-warn-text { color: var(--arnb-warn) !important; }

/* Tiilet */
.arnb-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-bottom: 18px; }
.arnb-tile { display: flex; flex-direction: column; gap: 4px; padding: 12px 14px; border-radius: 8px; border: 1px solid var(--arnb-line); text-decoration: none; color: var(--arnb-text) !important; background: var(--arnb-bg); border-top-width: 4px; }
.arnb-tile:hover { background: var(--arnb-soft); }
.arnb-tile span { font-size: .85em; color: var(--arnb-muted); }
.arnb-tile strong { font-size: 1.5em; line-height: 1.1; }
.arnb-tile.arnb-bad { border-top-color: var(--arnb-bad); }
.arnb-tile.arnb-warn { border-top-color: #dba617; }
.arnb-tile.arnb-good { border-top-color: var(--arnb-good); }

/* Suodattimet */
.arnb-filters { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 12px; }
.arnb-tab { padding: 5px 12px; border-radius: 999px; background: var(--arnb-soft); text-decoration: none; color: var(--arnb-text) !important; font-size: .9em; }
.arnb-tab.is-active { background: var(--arnb-accent); color: #fff !important; }
.arnb-filters input[type="search"] { margin-left: auto; min-width: 240px; }

/* Taulukot */
.arnb-table { width: 100%; border-collapse: collapse; margin: 0 0 18px; background: var(--arnb-bg); font-size: .93em; }
.arnb-table th, .arnb-table td { padding: 8px 10px; border-bottom: 1px solid var(--arnb-line); text-align: left; vertical-align: top; }
.arnb-table th { background: var(--arnb-soft); font-weight: 600; white-space: nowrap; }
.arnb-table tbody tr:hover > td { background: #fafafa; }
.arnb-table .num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.arnb-empty { text-align: center !important; color: var(--arnb-muted); padding: 24px !important; }
.arnb-row-muted td { color: var(--arnb-muted); }
.arnb-results .arnb-row-bad > td:first-child { box-shadow: inset 4px 0 0 var(--arnb-bad); }
.arnb-results .arnb-row-warn > td:first-child { box-shadow: inset 4px 0 0 #dba617; }
.arnb-results .arnb-row-muted > td { color: var(--arnb-muted); }
.arnb-actions { text-align: right; white-space: nowrap; }
.arnb-detail > td { background: var(--arnb-soft) !important; }
.arnb-detail ul { margin: 0 0 .5em 1.2em; padding: 0; }

/* Tilasirut */
.arnb-chip { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: .8em; font-weight: 600; white-space: nowrap; }
.arnb-chip.arnb-good { background: var(--arnb-good-bg); color: var(--arnb-good); }
.arnb-chip.arnb-bad { background: var(--arnb-bad-bg); color: var(--arnb-bad); }
.arnb-chip.arnb-warn { background: var(--arnb-warn-bg); color: var(--arnb-warn); }
.arnb-chip.arnb-muted { background: var(--arnb-muted-bg); color: var(--arnb-muted); }

/* Yrityssivu */
.arnb-company-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; align-items: flex-start; margin-bottom: 16px; }
.arnb-company-head h2 { margin: 0 0 4px; }
.arnb-meta { color: var(--arnb-muted); }
.arnb-head-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.arnb-detail-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 20px; }
.arnb-forms form, .arnb-forms details { margin-bottom: 14px; }
.arnb-forms > form, .arnb-detail-grid > form { padding: 10px 12px; background: var(--arnb-bg); border: 1px solid var(--arnb-line); border-radius: 6px; }
.arnb-form-primary { border-color: var(--arnb-accent) !important; box-shadow: 0 0 0 1px var(--arnb-accent); }
.arnb-other { margin: 0 0 16px; border: 1px solid var(--arnb-line); border-radius: 6px; padding: 8px 12px; background: var(--arnb-bg); }
.arnb-other > summary, .arnb details > summary { cursor: pointer; font-weight: 600; }
.arnb-other[open] > summary { margin-bottom: 10px; }
.arnb-log { margin: 0; padding-left: 1.2em; font-size: .9em; }

/* Lomakkeet */
.arnb label { display: block; margin: 0 0 8px; font-size: .9em; font-weight: 600; }
.arnb label input, .arnb label select { display: block; width: 100%; margin-top: 3px; font-weight: normal; }
.arnb input:not([type="hidden"]):not([type="checkbox"]), .arnb select { padding: 6px 8px; border: 1px solid #8c8f94; border-radius: 4px; font-size: 14px; background: #fff; color: var(--arnb-text); max-width: 100%; }
.arnb input:focus, .arnb select:focus { outline: 2px solid var(--arnb-accent); outline-offset: 0; border-color: var(--arnb-accent); }
.arnb-inline { display: inline; margin: 0; }
.arnb-inline input { display: inline-block; width: auto; }
.arnb-forms form > input:not([type="hidden"]), .arnb-forms form > select { width: 100%; margin-bottom: 8px; }
.arnb-grid-form { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 4px 14px; align-items: end; }
.arnb-grid-form .arnb-wide { grid-column: 1 / -1; }
.arnb-grid-form > button { justify-self: start; margin-bottom: 8px; }
.arnb-card { border: 1px solid var(--arnb-line); border-radius: 8px; padding: 14px 16px; margin: 0 0 18px; background: var(--arnb-bg); }

/* Painikkeet */
.arnb-btn { display: inline-block; padding: 7px 14px; border-radius: 4px; border: 1px solid var(--arnb-accent); background: var(--arnb-accent); color: #fff !important; font-size: 14px; font-weight: 600; line-height: 1.2; cursor: pointer; text-decoration: none; }
.arnb-btn:hover { filter: brightness(1.08); }
.arnb-btn-ghost { background: #fff; color: var(--arnb-accent) !important; }
.arnb-link { background: none; border: 0; padding: 0; color: var(--arnb-accent); cursor: pointer; text-decoration: underline; font-size: inherit; }
.arnb-btn.is-busy, .arnb-link.is-busy { opacity: .55; cursor: progress; }

/* 0.2: Netbaron-rivit taulukossa, kuvakepainikkeet ja vahvistusikkuna */
.arnb-btn-small { padding: 4px 10px; font-size: 13px; }
.arnb-code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .85em; }
.arnb-icon { display: inline-flex; align-items: center; justify-content: center; min-width: 28px; height: 28px; padding: 0 6px; border: 1px solid var(--arnb-line); border-radius: 4px; background: #fff; color: var(--arnb-accent); cursor: pointer; font-size: 14px; line-height: 1; vertical-align: middle; }
.arnb-icon:hover:not([disabled]) { border-color: var(--arnb-accent); background: var(--arnb-soft); }
.arnb-icon[disabled] { opacity: .4; cursor: not-allowed; }
.arnb-icon.is-busy { opacity: .55; cursor: progress; }
.arnb-icon-sync { font-weight: 700; font-size: 16px; }
.arnb-icon-save { color: var(--arnb-good); }
.arnb-icon-del { color: var(--arnb-bad); }
.arnb-icon-del:hover:not([disabled]) { border-color: var(--arnb-bad); background: var(--arnb-bad-bg); }
.arnb-sync-col { text-align: center !important; width: 44px; }
.arnb-ok-mark { color: var(--arnb-good); font-weight: 700; }
.arnb-nb-cell { white-space: nowrap; }
.arnb-nbrow { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; margin-bottom: 4px; }
.arnb-nbrow:last-child { margin-bottom: 0; }
.arnb input.arnb-qty { width: 76px !important; display: inline-block; text-align: right; padding: 4px 6px; }
.arnb-renew-on { color: var(--arnb-good); }
.arnb-lics { list-style: none; margin: 0 0 10px !important; padding: 0 !important; }
.arnb-lics li { padding: 6px 0; border-bottom: 1px dashed var(--arnb-line); }
.arnb-lics li:last-child { border-bottom: 0; }
.arnb-mini-form { padding: 10px 12px; background: var(--arnb-bg); border: 1px solid var(--arnb-line); border-radius: 6px; margin-bottom: 10px; }
.arnb-row-fields { display: flex; flex-wrap: wrap; gap: 0 10px; }
.arnb-row-fields > label { flex: 0 1 120px; min-width: 90px; }
.arnb-row-fields > label.arnb-grow { flex: 1 1 200px; }
.arnb-map-item { margin-bottom: 4px; white-space: normal; }
.arnb-csv input[type="file"] { border: 0; padding: 4px 0; }

.arnb-modal { border: 0; border-radius: 10px; padding: 0; max-width: min(560px, calc(100vw - 32px)); width: 100%; box-shadow: 0 10px 40px rgba(0,0,0,.25); color: var(--arnb-text); }
.arnb-modal { position: fixed !important; inset: 0 !important; margin: auto !important; height: fit-content; max-height: calc(100vh - 32px); overflow: auto; transform: none !important; }
.arnb-modal-note { display: block; margin: 0 0 12px; }
.arnb-modal-note span { display: block; font-weight: 600; margin-bottom: 4px; }
.arnb-modal-note textarea { width: 100%; box-sizing: border-box; }
.arnb-row-actions { display: inline-flex; gap: 4px; justify-content: flex-end; }
.arnb-icon svg { width: 16px; height: 16px; display: block; }
.arnb-icon-ack { color: var(--arnb-good); }
.arnb-modal::backdrop { background: rgba(0,0,0,.45); }
.arnb-modal form { padding: 18px 20px; margin: 0; }
.arnb-modal h3 { margin: 0 0 10px; font-size: 1.15em; }
.arnb-modal ul { margin: 0 0 12px 1.1em; padding: 0; }
.arnb-modal li { margin: 3px 0; }
.arnb-modal-target { display: inline-block; margin: 0 0 8px; padding: 3px 10px; border-radius: 999px; font-size: .8em; font-weight: 700; }
.arnb-modal-target.arnb-env-live { background: var(--arnb-bad-bg); color: var(--arnb-bad); }
.arnb-modal-target.arnb-env-demo { background: var(--arnb-warn-bg); color: var(--arnb-warn); }
.arnb-modal-warn { padding: 8px 10px; background: var(--arnb-bad-bg); color: var(--arnb-bad); border-radius: 4px; font-weight: 600; }
.arnb-modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 8px; }

.arnb-billing { margin: 0 0 16px; padding: 10px 14px; background: var(--arnb-soft); border-radius: 6px; }
.arnb-billing-item { margin-top: 4px; }
.arnb-billing-item select { width: auto; display: inline-block; }
.arnb-billing-form { margin-top: 10px; max-width: 640px; }
.arnb-billing-manage { margin: 0 0 12px; padding-bottom: 8px; border-bottom: 1px solid var(--arnb-line, #e5e7eb); }
.arnb-billing-manage .arnb-billing-item { margin-right: 12px; }

@media (max-width: 782px) {
	.arnb-detail-grid { grid-template-columns: 1fr; }
	.arnb-filters input[type="search"] { margin-left: 0; min-width: 0; width: 100%; }
	.arnb-table { display: block; overflow-x: auto; }
	.arnb-env { margin-left: 0; }
}
.arnb-billing-link { margin: 0 0 12px; }
.arnb-billing-link form { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 6px; }
.arnb-billing-link form label { display: inline-flex; align-items: center; gap: 6px; margin: 0; font-weight: 600; }
.arnb-billing-link input[name="keyword"] { width: 220px; max-width: 100%; }

/* 0.3.1 Kuitatut tuotteet */
.arnb-ack-note { color: #555; font-style: italic; }
#arnb-acked > .arnb-table { margin-top: 8px; }
