* {
    box-sizing: border-box
}

body {
    font-family: system-ui, -apple-system, Segoe UI, Roboto;
    background: #0b1220;
    color: #e6e9ef;
    margin: 0;
    overflow-x: hidden
}

.auth-page {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(70, 201, 123, 0.16), transparent 34rem),
        linear-gradient(135deg, #07111f 0%, #0b1220 52%, #111a2f 100%);
}

.auth-shell {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.auth-card {
    width: min(420px, 100%);
    border: 1px solid #1f2a44;
    border-radius: 8px;
    background: rgba(17, 26, 47, 0.94);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
    padding: 26px;
}

.auth-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
}

.auth-brand__logo {
    width: 42px;
    height: 42px;
}

.auth-brand__eyebrow {
    margin: 0 0 3px;
    color: #8aa2c8;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.auth-brand h1 {
    margin: 0;
    color: #e6e9ef;
    font-size: 24px;
    line-height: 1.2;
}

.auth-form {
    display: grid;
    gap: 16px;
}

.auth-field {
    display: grid;
    gap: 7px;
    color: #c9d6f0;
    font-size: 13px;
    font-weight: 700;
}

.auth-field input {
    width: 100%;
    border: 1px solid #273451;
    border-radius: 8px;
    background: rgba(11, 18, 32, 0.72);
    color: #e6e9ef;
    padding: 12px 13px;
    font: inherit;
}

.auth-field input:focus {
    outline: none;
    border-color: rgba(70, 201, 123, 0.72);
    box-shadow: 0 0 0 3px rgba(70, 201, 123, 0.18);
}

.auth-submit {
    border: 1px solid rgba(70, 201, 123, 0.55);
    border-radius: 8px;
    background: #46c97b;
    color: #06100b;
    cursor: pointer;
    font: inherit;
    font-weight: 800;
    min-height: 44px;
    padding: 10px 14px;
}

.auth-submit:hover {
    background: #6ee7a3;
}

.auth-submit:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

.auth-alert {
    margin-bottom: 16px;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 13px;
    line-height: 1.35;
}

.auth-alert--error {
    border: 1px solid rgba(255, 111, 111, 0.38);
    background: rgba(255, 111, 111, 0.12);
    color: #ffb3b3;
}

body.demo-mode input:not(#demo-mode),
body.demo-mode textarea,
body.demo-mode select {
    cursor: default;
}

.demo-disabled,
.demo-disabled:hover {
    opacity: 0.45;
    cursor: not-allowed !important;
    transform: none !important;
}

.copied-flash {
    animation: copiedFlash 0.7s ease;
}

@keyframes copiedFlash {
    0% {
        box-shadow: 0 0 0 0 rgba(70, 201, 123, 0.6);
    }
    100% {
        box-shadow: 0 0 0 8px rgba(70, 201, 123, 0);
    }
}

.container {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 16px 0 24px;
}

.main-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    width: min(1200px, 100%);
    margin: 0 auto 24px;
    text-align: center;
}

.main-header h1 {
    margin: 0;
    font-size: 26px
}

.summary-cards {
    display: flex;
    gap: 16px;
    align-items: stretch;
    justify-content: center;
    flex-wrap: wrap;
    width: 100%;
}

.summary-card {
    background: #111a2f;
    border-radius: 16px;
    padding: 16px 18px;
    min-width: 200px;
    flex: 1 1 200px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.summary-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.summary-card-header--total {
    align-items: flex-start;
}

.summary-label-input {
    flex: 1;
    min-width: 0;
    background: transparent;
    border: 1px solid transparent;
    color: #dfe7f5;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 4px 6px;
    border-radius: 8px;
}

.summary-label-input:focus {
    outline: none;
    border-color: #2f3f62;
    background: rgba(9, 14, 26, 0.6);
    box-shadow: 0 0 0 2px rgba(70, 201, 123, 0.2);
}

.summary-remove-account,
.summary-add-account {
    width: 28px;
    height: 28px;
    border-radius: 999px;
    border: 1px solid #273451;
    background: rgba(11, 18, 32, 0.65);
    color: #e6e9ef;
    font-size: 18px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.1s ease;
}

.summary-remove-account:hover {
    background: rgba(255, 111, 111, 0.18);
    border-color: rgba(255, 111, 111, 0.5);
    color: #ff9a9a;
}

.summary-add-account:hover {
    background: rgba(70, 201, 123, 0.18);
    border-color: rgba(70, 201, 123, 0.45);
    color: #46c97b;
}

.summary-remove-account:disabled,
.summary-add-account:disabled,
.summary-remove-account.is-disabled {
    opacity: 0.45;
    cursor: not-allowed;
    transform: none;
}

.summary-card .summary-cash-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 6px 10px;
    background: rgba(11, 18, 32, 0.65);
    border: 1px solid #1f2a44;
    border-radius: 12px;
}

.summary-card .summary-cash-row label {
    font-size: 12px;
    color: #8aa2c8;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.summary-card .cash-input {
    width: 90px;
    background: transparent;
    border: none;
    color: #e6e9ef;
    padding: 4px 6px;
    font-variant-numeric: tabular-nums;
    text-align: right;
}

.summary-card .cash-input:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(70, 201, 123, 0.25);
    border-radius: 8px;
}

.summary-card .summary-cash {
    font-size: 13px;
    color: #8aa2c8;
}

.summary-card .summary-holdings-prev {
    color: #6f83a8;
    font-size: 12.5px;
}

.summary-performance {
    width: 100%;
    border: 1px solid #1f2a44;
    border-radius: 8px;
    background: rgba(11, 18, 32, 0.65);
    padding: 8px 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.summary-performance__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    color: #8aa2c8;
    font-size: 11px;
}

.summary-performance__title {
    color: #dfe7f5;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.summary-performance__pl {
    margin-left: auto;
    color: #dfe7f5;
    font-size: 13px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    text-transform: none;
    letter-spacing: 0;
}

.summary-performance__range {
    display: none;
}

.summary-performance__metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
}

.summary-performance__metric {
    border: 1px solid #1f2a44;
    border-radius: 8px;
    background: rgba(11, 18, 32, 0.72);
    color: #e6e9ef;
    padding: 5px 6px;
    cursor: pointer;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 5px;
    min-height: 30px;
}

.summary-performance__metric:hover,
.summary-performance__metric.is-active {
    border-color: rgba(110, 231, 183, 0.55);
}

.summary-performance__metric:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

.summary-performance__metric-label {
    color: #8aa2c8;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.summary-performance__metric-value {
    font-size: 13px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.summary-performance__metric-value.metric-positive {
    color: #9fe3c4;
}

.summary-performance__metric-value.metric-negative {
    color: #ffb3b3;
}

.summary-performance--card {
    margin-top: 4px;
    padding: 6px 8px;
}

.summary-performance--card .summary-performance__head {
    justify-content: space-between;
    align-items: baseline;
}

.summary-performance--card .summary-performance__title {
    font-size: 10px;
}

.summary-performance--card .summary-performance__metric {
    min-height: 32px;
    padding: 4px 6px;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
}

.summary-performance--card .summary-performance__metric-label {
    font-size: 9px;
}

.summary-performance--card .summary-performance__metric-value {
    font-size: 11px;
}

.summary-performance--card .summary-performance__metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
}

.summary-cash-input {
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: -8px;
}

.summary-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.quotes-progress {
    width: min(740px, 100%);
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: -6px;
    padding: 6px 10px;
    border-radius: 999px;
    border: 1px solid #1f2a44;
    background: rgba(11, 18, 32, 0.6);
}

.quotes-progress[hidden] {
    display: none;
}

.quotes-progress__track {
    flex: 1;
    height: 8px;
    border-radius: 999px;
    background: rgba(20, 30, 52, 0.9);
    overflow: hidden;
}

.quotes-progress__bar {
    height: 100%;
    width: 0%;
    border-radius: 999px;
    background: linear-gradient(90deg, #46c97b, #2a88ff);
    transition: width 0.2s ease;
}

.quotes-progress__label {
    font-size: 12px;
    color: #9bb0d6;
    min-width: 120px;
    text-align: right;
}

.import-hint {
    margin-top: 6px;
    padding: 8px 12px;
    border-radius: 12px;
    border: 1px dashed rgba(70, 201, 123, 0.4);
    background: rgba(17, 26, 47, 0.6);
    color: #9bc1ff;
    font-size: 12.5px;
    text-align: center;
}

.settings-panel {
    margin: 16px 0 8px;
    padding: 16px;
    background: rgba(17, 26, 47, 0.7);
    border: 1px solid #1f2a44;
    border-radius: 16px;
    --settings-label-width: 170px;
}

.settings-panel__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.settings-panel__header h3 {
    margin: 0;
    font-size: 16px;
    color: #e6e9ef;
}

.settings-panel__group {
    margin-top: 12px;
    padding: 12px;
    border-radius: 12px;
    border: 1px solid #1f2a44;
    background: rgba(11, 18, 32, 0.65);
}

.settings-panel__group-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.settings-panel__group-header h4 {
    margin: 0;
    font-size: 14px;
    color: #d8e2f5;
}

.settings-panel__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
    margin-top: 10px;
}

.settings-panel__grid--stack {
    grid-template-columns: 1fr;
    gap: 8px;
}

.settings-panel__columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
    margin-top: 10px;
    width: 100%;
}

.settings-panel__column {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.settings-panel__field label {
    display: inline-flex;
    align-items: center;
    font-size: 13px;
    color: #8aa2c8;
    margin: 0;
    min-width: var(--settings-label-width);
}

.settings-panel__field--wide {
    grid-column: 1 / -1;
}

.settings-panel__field {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.settings-panel__input {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 0 0 auto;
    min-width: 0;
}

.settings-panel__value {
    font-size: 13px;
    color: #c9d6f0;
    font-weight: 600;
}

.settings-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #d8e2f5;
    font-size: 13px;
    min-width: 0;
}

.settings-toggle input {
    flex: 0 0 auto;
    width: 16px;
    height: 16px;
    accent-color: #46c97b;
}

.settings-panel__demo-note {
    margin-top: 12px;
    padding: 10px 12px;
    border: 1px solid rgba(255, 179, 71, 0.35);
    border-radius: 8px;
    background: rgba(255, 179, 71, 0.1);
    color: #ffcc7a;
    font-size: 13px;
}

.settings-panel__input input {
    flex: 1;
}

.settings-panel__suffix {
    font-size: 13px;
    color: #8aa2c8;
    min-width: 32px;
    text-align: right;
}

.settings-panel__help {
    margin-top: 0;
    font-size: 12px;
    color: #6f83a8;
    padding-left: calc(var(--settings-label-width) + 10px);
}

.settings-panel__hint {
    margin-top: 6px;
    font-size: 12px;
    color: #6f83a8;
    flex-basis: 100%;
    margin-left: calc(var(--settings-label-width) + 10px);
}

.settings-panel__footer {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 12px;
}

.settings-panel__footer-row {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    width: 100%;
}

.settings-panel__footer-group {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.settings-panel__footer .settings-panel__hint {
    margin-left: 0;
    flex-basis: auto;
}

.settings-input {
    width: 12ch;
}

.settings-input--short {
    width: 8ch;
}

.settings-input--key {
    width: 28ch;
    max-width: 100%;
}

.settings-select {
    background: #0b1220;
    color: #e6e9ef;
    border: 1px solid #1f2a44;
    border-radius: 8px;
    padding: 6px 8px;
    min-width: 20ch;
}

.history-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    border-radius: 999px;
    background: rgba(70, 201, 123, 0.15);
    color: #46c97b;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.history-button[type="button"] {
    border: none;
    cursor: pointer;
}

.history-button:hover {
    background: rgba(70, 201, 123, 0.3);
    transform: translateY(-1px);
}

.history-button--secondary {
    background: rgba(43, 92, 255, 0.2);
    color: #9bc1ff;
}

.history-button--secondary:hover {
    background: rgba(43, 92, 255, 0.35);
}

.history-button--danger {
    background: rgba(255, 94, 94, 0.2);
    color: #ff9b9b;
}

.history-button--danger:hover {
    background: rgba(255, 94, 94, 0.35);
}

.page-header-shell {
    width: 100%;
    max-width: 100%;
    margin: 0 0 16px;
    padding: 0 12px 0 0;
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.page-header-shell--main {
    margin-bottom: 24px;
}

.page-header-shell > .main-header,
.page-header-shell > .history-header {
    flex: 1 1 0;
    min-width: 0;
    width: auto;
    max-width: 1200px;
    margin: 0;
    padding: 0;
}

.app-menu-bar {
    flex: 0 0 56px;
    width: 56px;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: flex-start;
    align-self: flex-start;
}

.app-menu {
    position: relative;
    z-index: 12;
}

.app-menu__toggle {
    border: 1px solid #1f2a44;
    border-radius: 10px;
    background: rgba(11, 18, 32, 0.85);
    color: #e6e9ef;
    padding: 0;
    width: 56px;
    min-width: 56px;
    min-height: 56px;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
}

.app-menu__toggle:hover,
.app-menu.is-open .app-menu__toggle {
    box-shadow: 0 0 0 2px rgba(52, 94, 255, 0.3);
}

.app-menu__panel {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: auto;
    width: min(320px, calc(100vw - 24px));
    background: #111a2f;
    border: 1px solid #1f2a44;
    border-radius: 14px;
    box-shadow: 0 18px 36px rgba(0, 0, 0, 0.35);
    overflow: visible;
}

.app-menu__panel[hidden] {
    display: none;
}

.app-menu__section {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px;
}

.app-menu__section + .app-menu__section {
    border-top: 1px solid rgba(31, 42, 68, 0.9);
}

.app-menu__item {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    min-height: 40px;
    padding: 9px 12px;
    border-radius: 10px;
    color: #dfe7f5;
    text-decoration: none;
    background: rgba(11, 18, 32, 0.55);
    border: 1px solid transparent;
    font-size: 14px;
    font-weight: 600;
}

.app-menu__item:hover {
    background: rgba(43, 92, 255, 0.2);
    border-color: rgba(43, 92, 255, 0.35);
}

.app-menu__item--active {
    background: rgba(70, 201, 123, 0.15);
    border-color: rgba(70, 201, 123, 0.35);
    color: #9fe3c4;
}

.app-menu__action {
    width: 100%;
    justify-content: flex-start;
}

.app-menu__action.is-active {
    background: rgba(43, 92, 255, 0.35);
    color: #dfe7f5;
}

.app-menu__menu-block {
    position: relative;
    width: 100%;
}

.app-menu__panel .export-menu,
.app-menu__panel .notifications {
    width: 100%;
    display: block;
}

.app-menu__panel .export-menu__panel,
.app-menu__panel .notifications-panel {
    left: 0;
    right: 0;
    width: auto;
}

.app-menu__action--notification {
    justify-content: space-between;
}

.app-menu__action--notification .notifications-badge {
    position: static;
    transform: none;
    box-shadow: none;
    margin-left: 10px;
}

.export-menu {
    position: relative;
    display: inline-flex;
}

.export-menu__panel {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 160px;
    background: #111a2f;
    border: 1px solid #1f2a44;
    border-radius: 10px;
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.35);
    padding: 6px;
    display: none;
    z-index: 5;
}

.export-menu.is-open .export-menu__panel {
    display: block;
}

.export-menu__item {
    display: block;
    width: 100%;
    text-align: left;
    border: none;
    background: transparent;
    color: #e6e9ef;
    padding: 8px 10px;
    border-radius: 8px;
    font-size: 13px;
    cursor: pointer;
    text-decoration: none;
}

.export-menu__item:hover {
    background: rgba(43, 92, 255, 0.25);
}

.notifications {
    position: relative;
    display: inline-flex;
}

.icon-button--bell {
    position: relative;
    min-width: 36px;
    min-height: 36px;
    font-size: 16px;
}

.notifications-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #ff5e5e;
    color: #fff;
    border-radius: 999px;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: 700;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.notifications-panel {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    width: 280px;
    max-height: 320px;
    overflow: hidden;
    background: #111a2f;
    border: 1px solid #1f2a44;
    border-radius: 12px;
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.35);
    z-index: 6;
    display: flex;
    flex-direction: column;
}

.notifications-panel[hidden] {
    display: none;
}

.notifications-panel__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-bottom: 1px solid #1f2a44;
    font-weight: 600;
    color: #e6e9ef;
}

.notifications-panel__title {
    font-weight: 600;
}

.notifications-panel__actions {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.notifications-panel__action {
    border: 1px solid rgba(120, 142, 200, 0.4);
    border-radius: 8px;
    padding: 4px 8px;
    background: transparent;
    color: #9bb3d5;
    font-size: 11px;
    cursor: pointer;
}

.notifications-panel__action:hover {
    background: rgba(43, 92, 255, 0.2);
    color: #cfe0ff;
}

.notifications-panel__close {
    background: transparent;
    border: none;
    color: #8aa2c8;
    cursor: pointer;
    font-size: 16px;
}

.notifications-list {
    padding: 8px 10px 12px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.notification-item {
    padding: 8px 10px;
    border-radius: 10px;
    background: rgba(11, 18, 32, 0.7);
    border: 1px solid rgba(31, 42, 68, 0.6);
    position: relative;
}

.notification-item.is-read {
    opacity: 0.7;
}

.notification-title {
    font-size: 13px;
    font-weight: 600;
    color: #e6e9ef;
}

.notification-message {
    font-size: 12.5px;
    color: #c9d6f0;
    margin-top: 4px;
}

.notification-meta {
    font-size: 11px;
    color: #8aa2c8;
    margin-top: 4px;
}

.notification-dismiss {
    position: absolute;
    top: 6px;
    right: 6px;
    background: transparent;
    border: none;
    color: #8aa2c8;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
}

.notification-dismiss:hover {
    color: #e6e9ef;
}

.notifications-empty {
    color: #8aa2c8;
    font-size: 12px;
    padding: 8px 10px;
}

.main-search {
    min-width: 200px;
    padding: 6px 10px;
    border-radius: 999px;
    border: 1px solid rgba(155, 193, 255, 0.4);
    background: rgba(17, 26, 47, 0.8);
    color: #e6e9ef;
}

.main-search:focus {
    outline: none;
    border-color: rgba(70, 201, 123, 0.6);
    box-shadow: 0 0 0 2px rgba(70, 201, 123, 0.25);
}

.quotes-last-update {
    font-size: 12px;
    color: #8aa2c8;
    white-space: nowrap;
}

.history-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(70, 201, 123, 0.2);
    color: #46c97b;
    font-size: 18px;
    text-decoration: none;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.history-link:hover {
    background: rgba(70, 201, 123, 0.35);
    transform: scale(0.95);
}

.summary-cash-input label {
    font-size: 12px;
    color: #8aa2c8;
}

.summary-cash-input .cash-input {
    width: 110px;
}

section.by-type {
    width: 100%;
    padding: 0 1%;
}

.summary-label {
    font-size: 12px;
    color: #8aa2c8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.summary-amount {
    font-size: 18px;
    font-weight: 600;
}

.summary-pl {
    font-size: 14px;
}

.summary-pl.positive {
    color: #46c97b;
}

.summary-pl.negative {
    color: #ff5e5e;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 16px 0 8px;
    flex-wrap: wrap
}

.section-header h2 {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.section-header .section-label {
    font-weight: 700;
}

.section-header .section-count {
    font-size: 0.85em;
    color: #8aa2c8;
}

.section-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap
}

.section-actions__primary {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.section-actions--with-toolbar {
    flex: 1 1 560px;
    justify-content: space-between;
    margin-left: auto;
}

.section-actions > button,
.section-actions__primary button {
    border: 0;
    border-radius: 10px;
    padding: 8px 12px;
    background: #2b5cff;
    color: #fff;
    cursor: pointer;
    transition: transform 0.1s ease, background-color 0.2s ease, box-shadow 0.2s ease
}

.section-actions > button.save-button--dirty,
.section-actions__primary button.save-button--dirty {
    animation: savePulse 1.4s ease-in-out infinite;
}

.section-actions > button:hover,
.section-actions__primary button:hover {
    background: #345eff
}

.section-actions > button:active,
.section-actions > button.is-clicked,
.section-actions__primary button:active,
.section-actions__primary button.is-clicked {
    transform: scale(0.95);
    box-shadow: 0 0 0 2px rgba(52, 94, 255, 0.3);
}

@keyframes savePulse {
    0% {
        box-shadow: 0 0 0 0 rgba(70, 201, 123, 0);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(70, 201, 123, 0.35);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(70, 201, 123, 0);
    }
}

.section-button + .section-button {
    margin-left: 8px;
}

.save-status {
    margin-left: 8px;
    font-size: 14px;
    color: #8aa2c8;
}

.main-table-toolbar {
    margin-left: auto;
    display: grid;
    grid-template-columns: max-content minmax(180px, 240px);
    align-items: center;
    justify-content: end;
    gap: 10px;
    min-width: 0;
}

.main-table-toolbar__quotes {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    padding: 6px 10px;
    border-radius: 999px;
    border: 1px solid #1f2a44;
    background: rgba(11, 18, 32, 0.65);
    flex: 0 0 auto;
}

.main-table-toolbar__refresh {
    padding: 6px 12px;
}

.main-table-toolbar__search {
    width: 100%;
    min-width: 180px;
}

.icon-button {
    border: none;
    background: rgba(17, 26, 47, 0.85);
    color: #e6e9ef;
    border-radius: 999px;
    padding: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.icon-button img {
    width: 20px;
    height: 20px;
}

.icon-button:hover {
    box-shadow: 0 0 0 2px rgba(52, 94, 255, 0.35);
}

.icon-button.is-active {
    background: rgba(43, 92, 255, 0.85);
}

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 2px 4px
}

th {
    padding: 0px 0px;
    text-align: center;
    background: #0e172b;
    font-size: 13px;
}

td {
    padding: 0px 0px;
    text-align: left;
    background: #0e172b;
    font-size: 13px;
}

.col-center {
    text-align: center;
}

.etf-toggle {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border: 1px solid rgba(155, 193, 255, 0.6);
    border-radius: 4px;
    background: rgba(17, 26, 47, 0.6);
    display: inline-grid;
    place-items: center;
    cursor: pointer;
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

.etf-toggle::after {
    content: '';
    width: 8px;
    height: 4px;
    border-left: 2px solid transparent;
    border-bottom: 2px solid transparent;
    transform: rotate(-45deg);
    transition: border-color 0.2s ease;
}

.etf-toggle:checked {
    background: rgba(70, 201, 123, 0.25);
    border-color: rgba(70, 201, 123, 0.7);
}

.etf-toggle:checked::after {
    border-left-color: #46c97b;
    border-bottom-color: #46c97b;
}

.etf-toggle:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(70, 201, 123, 0.25);
}

thead th {
    background: transparent;
    color: #8aa2c8
}

th.sortable {
    cursor: pointer;
    user-select: none;
}

th.sortable::after {
    content: '';
    margin-left: 4px;
    font-size: 0.75em;
}

th.sortable[data-sort="asc"]::after {
    content: '▲';
}

th.sortable[data-sort="desc"]::after {
    content: '▼';
}

tbody td:first-child {
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px
}

tbody td:last-child {
    border-top-right-radius: 10px;
    border-bottom-right-radius: 10px
}

input {
    width: 100%;
    background: #0b1220;
    color: #e6e9ef;
    border: 1px solid #1f2a44;
    border-radius: 8px;
    padding: 6px 8px
}

textarea {
    width: 100%;
    background: #0b1220;
    color: #e6e9ef;
    border: 1px solid #1f2a44;
    border-radius: 8px;
    padding: 6px 8px;
    font-family: inherit;
    resize: vertical;
}

.action-cell {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.action-input-wrapper {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.action-input-wrapper input[data-key="action"] {
    flex: 1 1 14ch;
    min-width: 14ch;
}

.row-refresh {
    background: rgba(43, 92, 255, 0.15);
    color: #9bc1ff;
    border: 1px solid rgba(43, 92, 255, 0.5);
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
    font-size: 16px;
}

.row-refresh:hover {
    background: rgba(63, 112, 255, 0.25);
    transform: rotate(15deg);
}

.row-ai {
    background: rgba(255, 179, 71, 0.15);
    color: #ffcc7a;
    border: 1px solid rgba(255, 179, 71, 0.45);
    border-radius: 10px;
    height: 28px;
    padding: 0 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.row-ai:hover {
    background: rgba(255, 179, 71, 0.25);
    transform: translateY(-1px);
}

.row-search {
    background: rgba(155, 193, 255, 0.15);
    color: #9bc1ff;
    border: 1px solid rgba(155, 193, 255, 0.45);
    border-radius: 10px;
    height: 28px;
    padding: 0 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.row-search--pending {
    animation: savePulse 1.4s ease-in-out infinite;
}

.row-search:hover {
    background: rgba(155, 193, 255, 0.25);
    transform: translateY(-1px);
}

.row-sell {
    background: rgba(255, 94, 94, 0.15);
    color: #ff9b9b;
    border: 1px solid rgba(255, 94, 94, 0.45);
    border-radius: 10px;
    height: 28px;
    padding: 0 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.row-sell:hover {
    background: rgba(255, 94, 94, 0.25);
    transform: translateY(-1px);
}

.row-split {
    background: rgba(72, 200, 175, 0.15);
    color: #7fead4;
    border: 1px solid rgba(72, 200, 175, 0.45);
    border-radius: 10px;
    height: 28px;
    padding: 0 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.row-split:hover {
    background: rgba(72, 200, 175, 0.25);
    transform: translateY(-1px);
}

body:not(.show-settings) .row-split {
    display: none;
}

.numeric-input {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.nb-input {
    min-width: 7ch;
}

.number-cell {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.is-number {
    text-align: right;
}

.col-action {
    min-width: 18ch;
    max-width: 32ch;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.col-action input {
    background: transparent;
}

.metric-positive,
.metric-negative {
    background-color: rgba(11, 18, 32, 0.6);
    border-radius: 8px;
    border: 1px solid transparent;
}

.metric-positive {
    border-color: rgba(70, 201, 123, 0.45);
}

.metric-negative {
    border-color: rgba(255, 94, 94, 0.45);
}

.col-8ch {
    min-width: 8ch;
    max-width: 8ch;
}

.col-6ch {
    min-width: 6ch;
    max-width: 6ch;
}

.col-link {
    text-align: center;
}

.col-actions {
    text-align: center;
    width: 8ch;
}

.col-code {
    min-width: 10ch;
    max-width: 12ch;
    word-break: break-word;
}

.col-etf {
    min-width: 5ch;
    max-width: 6ch;
}

.col-date {
    min-width: 11ch;
    max-width: 12ch;
}

.col-symbol {
    min-width: 12ch;
    max-width: 14ch;
    word-break: break-word;
}

.col-currency {
    width: 6ch;
    text-align: center;
    font-weight: 600;
}

.currency-cell {
    text-align: center;
    font-weight: 600;
}

.prev-close {
    transition: background-color 0.2s ease;
}

.last-change {
    transition: background-color 0.2s ease;
}

.col-comment {
    min-width: 28ch;
    max-width: 40ch;
}

.col-comment textarea {
    background: rgba(17, 26, 47, 0.85);
    resize: none;
    min-height: 24px;
    max-height: 24px;
    line-height: 1.3;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.col-comment.comment-expanded {
    min-width: 40ch;
    max-width: 60ch;
}

.col-comment.comment-expanded textarea {
    min-height: 5.5em;
    max-height: none;
    white-space: normal;
    overflow: auto;
    resize: vertical;
}

.cell-status {
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.cell-status input {
    background: transparent;
}

.cell-status-missing {
    background-color: rgba(255, 94, 94, 0.2);
}

.cell-status-missing input {
    border-color: rgba(255, 94, 94, 0.7);
}

.cell-status-ok {
    background-color: rgba(70, 201, 123, 0.2);
}

.cell-status-ok input {
    border-color: rgba(70, 201, 123, 0.7);
}

.objectif-alert {
    animation: objectif-pulse 1.1s ease-in-out infinite;
    background-color: rgba(70, 201, 123, 0.35) !important;
}

.objectif-alert input {
    border-color: rgba(70, 201, 123, 0.85);
    background: rgba(13, 30, 20, 0.85);
}

@keyframes objectif-pulse {
    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(70, 201, 123, 0.4);
    }
    50% {
        box-shadow: 0 0 12px 2px rgba(70, 201, 123, 0.55);
    }
}

.last-cell.manual-last {
    background-color: rgba(165, 105, 255, 0.25);
}

.last-cell.manual-last input {
    border-color: rgba(165, 105, 255, 0.7);
}

.last-input.read-only {
    background: transparent;
    cursor: default;
}

.logo-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
}

.logo-icon {
    width: 20px;
    height: 20px;
}

a {
    color: #9bc1ff;
    text-decoration: none
}

a:hover {
    text-decoration: underline
}


.hovercard:hover {
    pointer-events: auto;
}
.history-container {
    /*max-width: 1200px;*/
    margin: 0 auto;
    padding: 16px 12px 24px;
}

.sales-container .history-header {
    align-items: center;
}

.sales-container .history-header .history-button {
    white-space: nowrap;
}

.history-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.history-header {
    flex-wrap: wrap;
}

.history-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.history-header h1 {
    margin: 0;
    font-size: 26px;
}

.history-demo-note {
    flex-basis: 100%;
    margin: -6px 0 0;
    color: #ffcc7a;
    font-size: 13px;
}

.app-menu__item--disabled {
    color: #8aa2c8;
    cursor: default;
    opacity: 0.72;
}

.help-section {
    background: rgba(17, 26, 47, 0.65);
    border: 1px solid #1f2a44;
    border-radius: 14px;
    padding: 14px 16px;
    margin-bottom: 12px;
}

.help-toc {
    background: rgba(14, 22, 40, 0.75);
    border: 1px solid #1f2a44;
    border-radius: 14px;
    padding: 12px 16px;
    margin-bottom: 16px;
}

.help-toc h2 {
    margin: 0 0 8px;
    font-size: 16px;
    color: #e6e9ef;
}

.help-toc a {
    color: #b9c7e6;
    text-decoration: none;
}

.help-toc a:hover {
    color: #e6e9ef;
    text-decoration: underline;
}

.help-toc-groups {
    margin: 0;
    padding: 0;
    list-style: none;
    columns: 2;
    column-gap: 26px;
}

.help-toc-groups > li {
    break-inside: avoid;
    margin-bottom: 10px;
}

.help-toc-group-title {
    font-size: 13.5px;
    font-weight: 600;
    color: #e6e9ef;
    margin-bottom: 4px;
}

.help-toc-groups ul {
    margin: 0;
    padding-left: 18px;
    list-style: disc;
    columns: 1;
}

.help-toc-groups li li {
    margin: 2px 0;
}

.help-toc-groups li li a {
    font-size: 12.5px;
}

.help-section h2 {
    margin: 0 0 8px;
    font-size: 16px;
    color: #e6e9ef;
}

.help-note {
    margin-top: 8px;
    padding: 8px 10px;
    border-radius: 10px;
    background: rgba(43, 92, 255, 0.12);
    border: 1px solid rgba(43, 92, 255, 0.35);
    color: #c9d6f0;
    font-size: 12.5px;
}

.help-section p,
.help-section li {
    font-size: 13.5px;
    color: #c9d6f0;
    line-height: 1.5;
}

.help-code {
    background: rgba(11, 18, 32, 0.8);
    border: 1px solid #1f2a44;
    border-radius: 10px;
    padding: 10px 12px;
    color: #e6e9ef;
    font-size: 12.5px;
    line-height: 1.4;
    white-space: pre-wrap;
    overflow-x: auto;
    margin: 8px 0 10px;
}

.help-section ul {
    margin: 0;
    padding-left: 18px;
}

@media (max-width: 900px) {
    .help-toc-groups {
        columns: 1;
    }

    .col-action input {
        font-size: 15px;
    }
}

@media (max-width: 1200px) {
    .action-input-wrapper input[data-key="action"] {
        flex-basis: 100%;
        font-size: 15px;
    }

    .action-cell {
        gap: 6px;
    }

    .row-refresh,
    .row-ai,
    .row-search,
    .row-sell,
    .row-split {
        height: 24px;
        padding: 0 6px;
        font-size: 11px;
    }
}

@media (max-width: 1024px) {
    .page-header-shell {
        padding: 0 12px 0 0;
    }

    .main-header,
    .history-header {
        align-items: flex-start;
        text-align: left;
        padding: 0 12px;
    }

    .history-header {
        flex-direction: column;
    }

    .history-header-actions,
    .summary-actions,
    .summary-cash-input {
        justify-content: flex-start;
        width: 100%;
    }

    .section-actions--with-toolbar,
    .main-table-toolbar {
        width: 100%;
    }

    .main-table-toolbar {
        display: flex;
        justify-content: flex-start;
        margin-left: 0;
        flex-wrap: wrap;
    }

    .history-table-wrapper,
    .ai-log-table-wrap,
    .dividends-modal__table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    section.by-type {
        overflow-x: auto;
    }

    .data-table,
    .history-table,
    .watchlist-table,
    #ai-log-table,
    .dividends-modal__table--wide {
        min-width: 720px;
    }

    .col-action {
        min-width: 14ch;
        max-width: 24ch;
    }

    .sales-summary {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .page-header-shell {
        gap: 10px;
        padding: 0 12px 0 0;
    }

    .app-menu__panel {
        width: min(320px, calc(100vw - 24px));
    }

    .summary-cards {
        flex-direction: column;
    }

    .summary-card {
        min-width: 100%;
    }

    .summary-performance__head {
        flex-direction: row;
        align-items: center;
    }

    .summary-performance__metric {
        flex-direction: column;
        align-items: flex-start;
        min-height: 42px;
    }

    .summary-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .summary-actions .history-button,
    .summary-actions .icon-button,
    .summary-actions .main-search {
        width: 100%;
        justify-content: center;
    }

    .history-header-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .history-header-actions .history-button,
    .history-header-actions .main-search,
    .history-header-actions .quotes-last-update {
        width: 100%;
    }

    .main-search {
        min-width: 0;
        width: 100%;
    }

    .main-table-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .main-table-toolbar__quotes {
        justify-content: space-between;
        width: 100%;
    }

    .main-table-toolbar__refresh,
    .main-table-toolbar__search {
        width: 100%;
    }

    .watchlist-filters {
        grid-template-columns: 1fr;
    }

    .watchlist-header-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .sale-modal__dialog {
        width: min(520px, 94vw);
        padding: 16px;
    }

    .section-actions {
        width: 100%;
    }

    .section-actions > button,
    .section-actions__primary button {
        flex: 1 1 auto;
    }

    .data-table,
    .history-table,
    .watchlist-table,
    #ai-log-table,
    .dividends-modal__table--wide {
        min-width: 620px;
    }

    .col-action {
        min-width: 12ch;
        max-width: 20ch;
    }

    .sales-summary__item {
        min-width: 100%;
    }
}

.history-hint {
    font-size: 12px;
    color: #8aa2c8;
}

.dividends-summary {
    font-size: 13px;
    color: #c9d6f0;
}

.dividends-summary-cell {
    text-align: right;
}

.dividends-summary-inline {
    display: inline-flex;
    gap: 12px;
    align-items: center;
    justify-content: flex-end;
    width: 100%;
}

.dividends-header {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dividends-title {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dividends-total {
    font-weight: 600;
}

.dividends-detail-button {
    background: rgba(155, 193, 255, 0.15);
    color: #9bc1ff;
    border: 1px solid rgba(155, 193, 255, 0.45);
    border-radius: 10px;
    height: 28px;
    padding: 0 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.dividends-detail-button:hover {
    background: rgba(155, 193, 255, 0.25);
    transform: translateY(-1px);
}

.dividends-modal__summary {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    align-items: center;
    margin: 8px 0 12px;
}

.dividends-modal__price {
    font-size: 14px;
    font-weight: 600;
    color: #c7d2e9;
    margin: 6px 0 6px;
}

.dividends-modal__filters {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 6px 0 12px;
    color: #8aa2c8;
    font-size: 12px;
}

.dividends-modal__filters label {
    white-space: nowrap;
}

.dividends-modal__filters select {
    background: rgba(11, 18, 32, 0.8);
    border: 1px solid #1f2a44;
    border-radius: 10px;
    color: #e6e9ef;
    padding: 6px 10px;
}

.dividends-modal__yield {
    font-size: 13px;
    font-weight: 600;
    color: #c7d2e9;
    margin: 4px 0 10px;
}

.dividends-modal__table--wide {
    min-width: 700px;
}

.dividends-modal__dialog {
    width: min(1400px, 98vw);
    max-width: 1400px;
}

.dividends-modal__table-wrapper {
    max-height: 360px;
    overflow: auto;
    border-radius: 16px;
    border: 1px solid rgba(120, 142, 200, 0.25);
    background: rgba(8, 12, 20, 0.35);
    padding: 6px;
}

.watchlists-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.watchlist-section {
    background: rgba(14, 22, 40, 0.65);
    border: 1px solid #1f2a44;
    border-radius: 16px;
    padding: 14px 16px;
}

.watchlist-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.watchlist-title h2 {
    margin: 0;
    font-size: 18px;
}

.watchlist-name-input {
    background: rgba(10, 18, 34, 0.7);
    border: 1px solid #263353;
    color: #e6e9ef;
    font-size: 16px;
    padding: 6px 10px;
    border-radius: 10px;
    min-width: 220px;
}

.watchlist-header-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.watchlist-filters {
    display: grid;
    grid-template-columns: minmax(200px, 320px) minmax(200px, 320px);
    gap: 10px;
    margin-bottom: 10px;
}

.watchlist-search {
    width: 100%;
    padding: 6px 8px;
    border-radius: 8px;
    border: 1px solid rgba(155, 193, 255, 0.35);
    background: rgba(17, 26, 47, 0.85);
    color: #e6e9ef;
    font-size: 12px;
}

.watchlist-search:focus {
    outline: none;
    border-color: rgba(70, 201, 123, 0.6);
    box-shadow: 0 0 0 2px rgba(70, 201, 123, 0.2);
}

.watchlist-link-editor {
    display: flex;
    align-items: center;
    gap: 6px;
}

.watchlist-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 8px;
    border: 1px solid rgba(90, 118, 170, 0.4);
    background: rgba(11, 18, 32, 0.6);
}

.watchlist-link-editor .watchlist-input {
    flex: 1;
    min-width: 70px;
}

.watchlist-input--code {
    min-width: 70px;
    max-width: 110px;
}

.watchlist-input--isin {
    min-width: 100px;
    max-width: 130px;
    font-variant-numeric: tabular-nums;
}

.watchlist-input--symbol {
    min-width: 80px;
    max-width: 110px;
}

.watchlist-table th,
.watchlist-table td {
    padding: 6px 8px;
}

.watchlist-input {
    width: 100%;
    min-width: 90px;
    background: rgba(10, 18, 34, 0.7);
    border: 1px solid #263353;
    color: #e6e9ef;
    border-radius: 8px;
    padding: 6px 8px;
    font-size: 12.5px;
}

.watchlist-input--short {
    min-width: 70px;
    max-width: 90px;
    text-align: right;
}

.watchlist-input:disabled {
    opacity: 0.7;
}

.watchlist-checkbox {
    width: 16px;
    height: 16px;
    accent-color: #46c97b;
}

.watchlist-action {
    background: rgba(43, 92, 255, 0.12);
    border: 1px solid rgba(43, 92, 255, 0.35);
    color: #c9d6f0;
    border-radius: 8px;
    padding: 4px 6px;
    font-size: 12px;
    cursor: pointer;
    margin-right: 4px;
}

.watchlist-actions-cell {
    white-space: nowrap;
}

.watchlist-action--ai {
    border-color: rgba(255, 179, 71, 0.5);
    color: #ffcc7a;
}

.watchlist-action--search {
    border-color: rgba(155, 193, 255, 0.5);
    color: #9bc1ff;
}

.watchlist-action--buy {
    border-color: rgba(70, 201, 123, 0.6);
    color: #7ee0a5;
    font-weight: 700;
}

.watchlist-action--danger {
    border-color: rgba(255, 90, 90, 0.6);
    color: #ffb2b2;
}

.watchlist-action:hover {
    background: rgba(43, 92, 255, 0.2);
}

.watchlist-action--ai:hover {
    background: rgba(255, 179, 71, 0.2);
}

.watchlist-action--search:hover {
    background: rgba(155, 193, 255, 0.2);
}

.watchlist-action--buy:hover {
    background: rgba(70, 201, 123, 0.2);
}

.watchlist-action--danger:hover {
    background: rgba(255, 90, 90, 0.2);
}

.history-nav {
    border: none;
    border-radius: 20px;
    padding: 8px 14px;
    background: rgba(43, 92, 255, 0.85);
    color: #fff;
    cursor: pointer;
    transition: transform 0.1s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.history-nav:hover {
    background: rgba(63, 112, 255, 0.95);
}

.history-chart-section {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-height: 480px;
    height: auto;
    --chart-height: clamp(240px, 40vh, 320px);
    background: #0e172b;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    margin-bottom: 28px;
}

.history-range-controls {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 8px;
    font-size: 13px;
    color: #9bb0d4;
}

.history-range-label {
    font-weight: 600;
    color: #c8d3e8;
}

.history-range-stats {
    color: #8aa2c8;
}

.history-range-slider {
    position: relative;
    height: 28px;
}

.history-range-slider input[type="range"] {
    position: absolute;
    left: 0;
    top: 8px;
    width: 100%;
    margin: 0;
    pointer-events: none;
    -webkit-appearance: none;
    appearance: none;
    height: 4px;
    background: rgba(155, 193, 255, 0.25);
    border-radius: 999px;
}

.history-range-slider input[type="range"]::-webkit-slider-thumb {
    pointer-events: auto;
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #9bc1ff;
    border: 2px solid #0e172b;
    box-shadow: 0 0 0 2px rgba(155, 193, 255, 0.3);
}

.history-range-slider input[type="range"]::-moz-range-thumb {
    pointer-events: auto;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #9bc1ff;
    border: 2px solid #0e172b;
    box-shadow: 0 0 0 2px rgba(155, 193, 255, 0.3);
}

.history-range-slider input[type="range"]::-moz-range-track {
    background: rgba(155, 193, 255, 0.25);
    height: 4px;
    border-radius: 999px;
}

.history-chart-section canvas {
    width: 100%;
    height: var(--chart-height) !important;
    flex: 0 0 auto;
}

.history-chart-section.is-empty {
    align-items: center;
    justify-content: center;
    height: auto;
    min-height: 200px;
}

.history-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sales-header-main {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.sales-summary {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid #1f2a44;
    background: rgba(14, 22, 40, 0.7);
}

.sales-summary__item {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 140px;
}

.sales-summary__label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #8aa2c8;
}

.sales-summary__value {
    font-size: 14px;
    font-weight: 600;
    color: #e6e9ef;
}

.sales-summary__value.is-positive {
    color: #46c97b;
}

.sales-summary__value.is-negative {
    color: #ff5e5e;
}

.sales-header {
    gap: 16px;
    flex-wrap: wrap;
}

.history-sales-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.sales-search {
    min-width: 220px;
    padding: 6px 10px;
    border-radius: 8px;
    border: 1px solid rgba(155, 193, 255, 0.4);
    background: rgba(17, 26, 47, 0.8);
    color: #e6e9ef;
}

.sales-search:focus {
    outline: none;
    border-color: rgba(70, 201, 123, 0.6);
    box-shadow: 0 0 0 2px rgba(70, 201, 123, 0.25);
}

.sales-status {
    font-size: 13px;
    color: #9bc1ff;
}

.sales-expert-toggle {
    padding: 6px 12px;
    font-size: 13px;
}

.sales-expert-toggle.is-active {
    background: rgba(70, 201, 123, 0.22);
    color: #e6f8ee;
}

.sales-expert-toggle.is-dirty {
    animation: savePulse 1.4s ease-in-out infinite;
}

.sales-expert-toggle:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

#sales-count {
    font-size: 13px;
    color: #cbd8f3;
}

.sales-status[data-variant='success'] {
    color: #46c97b;
}

.sales-status[data-variant='error'] {
    color: #ff5e5e;
}

.sales-total {
    font-size: 13px;
    font-weight: 600;
    color: #cbd8f3;
}

.sales-total.is-positive {
    color: #46c97b;
}

.sales-total.is-negative {
    color: #ff5e5e;
}

.sales-reset-filters {
    padding: 6px 12px;
    font-size: 13px;
}

.sales-add-row {
    padding: 6px 12px;
    font-size: 13px;
}

.sales-edit-cell {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.sales-edit-input {
    width: 8ch;
    padding: 4px 6px;
    border-radius: 6px;
    border: 1px solid rgba(155, 193, 255, 0.35);
    background: rgba(11, 18, 32, 0.9);
    color: #e6e9ef;
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.sales-edit-input--text {
    width: 100%;
    text-align: left;
}

.sales-edit-input:focus {
    outline: none;
    border-color: rgba(70, 201, 123, 0.6);
    box-shadow: 0 0 0 2px rgba(70, 201, 123, 0.2);
}

.sales-edit-currency {
    font-size: 12px;
    color: #8aa2c8;
}

.history-table td.is-editing {
    padding-right: 10px;
}

#sale-history-table td.is-editing[data-field='code_investing'],
#sale-history-table td.is-editing[data-field='code_hiboo'],
#sale-history-table td.is-editing[data-field='symbol'] {
    min-width: 16ch;
    text-align: left;
}

.ai-log-header {
    gap: 10px;
}

.ai-log-section {
    margin-top: 12px;
}

.log-tabs {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    border-bottom: 1px solid #1f2a44;
}

.log-tab {
    appearance: none;
    border: 1px solid transparent;
    border-bottom: 0;
    background: transparent;
    color: #8aa2c8;
    padding: 10px 14px;
    border-radius: 8px 8px 0 0;
    cursor: pointer;
    font: inherit;
}

.log-tab:hover {
    color: #d8e2f5;
    background: rgba(43, 92, 255, 0.12);
}

.log-tab.is-active {
    color: #ffffff;
    background: #0e172b;
    border-color: #1f2a44;
}

.ai-log-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.ai-log-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 12px;
    align-items: flex-end;
}

.ai-log-filter {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 12px;
    color: #8aa2c8;
}

.ai-log-filter input,
.ai-log-filter select {
    min-width: 180px;
}

.ai-log-filter-buttons {
    display: flex;
    gap: 8px;
    align-items: center;
}

.ai-log-table-wrap {
    overflow: auto;
    border-radius: 12px;
    border: 1px solid #1f2a44;
}

.log-workspace {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(340px, 40%);
    gap: 16px;
    align-items: start;
}

.log-panel[hidden] {
    display: none !important;
}

.log-date-cell span {
    display: block;
    line-height: 1.25;
    white-space: nowrap;
}

.log-date-cell span + span {
    color: #8aa2c8;
    font-size: 0.9em;
}

#ai-log-table th,
#ai-log-table td,
#call-log-table th,
#call-log-table td,
#login-log-table th,
#login-log-table td,
#admin-users-table th,
#admin-users-table td {
    padding: 10px 12px;
    text-align: left;
}

#ai-log-table tbody tr,
#call-log-table tbody tr,
#login-log-table tbody tr {
    cursor: pointer;
    transition: background-color 0.15s ease;
}

#ai-log-table tbody tr:hover,
#call-log-table tbody tr:hover,
#login-log-table tbody tr:hover {
    background: rgba(43, 92, 255, 0.12);
}

#ai-log-table tbody tr.is-selected,
#call-log-table tbody tr.is-selected,
#login-log-table tbody tr.is-selected {
    background: rgba(70, 201, 123, 0.18);
}

.ai-log-detail {
    background: rgba(17, 26, 47, 0.7);
    border: 1px solid #1f2a44;
    border-radius: 12px;
    padding: 12px;
}

.log-detail-sticky {
    position: sticky;
    top: 16px;
    max-height: calc(100vh - 32px);
    display: flex;
    flex-direction: column;
}

.ai-log-detail__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.ai-log-detail__header h2 {
    margin: 0;
    font-size: 16px;
}

#ai-log-json,
#call-log-json,
#login-log-json {
    margin: 0;
    font-size: 12px;
    white-space: pre-wrap;
    color: #d8e2f5;
    overflow: auto;
    max-height: calc(100vh - 112px);
}

@media (max-width: 1180px) {
    .log-workspace {
        grid-template-columns: 1fr;
    }

    .log-detail-sticky {
        position: static;
        max-height: none;
    }

    #ai-log-json,
    #call-log-json,
    #login-log-json {
        max-height: 420px;
    }
}

.admin-users-create {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: flex-end;
    margin-bottom: 16px;
}

.admin-user-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.admin-user-password-input {
    min-width: 190px;
}

.history-section-header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #cbd8f3;
}

.history-sales-section {
    background: #0e172b;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.history-table-wrapper {
    overflow-x: auto;
}

.history-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    background: rgba(10, 18, 33, 0.6);
    border-radius: 12px;
    overflow: hidden;
}

.history-table thead {
    background: rgba(31, 42, 68, 0.9);
}

.history-table th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
    color: #9bc1ff;
    font-size: 13px;
    white-space: nowrap;
    border-bottom: 1px solid rgba(26, 36, 58, 0.9);
}

.history-filter-row th {
    padding: 8px 12px;
    background: rgba(14, 23, 43, 0.9);
    border-bottom: 1px solid rgba(26, 36, 58, 0.9);
}

.history-filter-row th[colspan] {
    text-align: left;
}

.history-filter-row input,
.history-filter-row select {
    width: 100%;
    padding: 6px 8px;
    border-radius: 8px;
    border: 1px solid rgba(155, 193, 255, 0.35);
    background: rgba(17, 26, 47, 0.85);
    color: #e6e9ef;
    font-size: 12px;
}

.history-filter-row input:focus,
.history-filter-row select:focus {
    outline: none;
    border-color: rgba(70, 201, 123, 0.6);
    box-shadow: 0 0 0 2px rgba(70, 201, 123, 0.2);
}

.sales-date-range {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.sales-date-range input[type="date"] {
    width: auto;
    min-width: 9.5ch;
}

.sales-date-sep {
    font-size: 12px;
    color: #8aa2c8;
}

.history-table td {
    padding: 3px 12px;
    border-bottom: 1px solid rgba(26, 36, 58, 0.7);
    color: #d5def5;
}

.history-table tbody tr:hover {
    background: rgba(43, 92, 255, 0.08);
}

#sale-history-table th[data-key='action'],
#sale-history-table td[data-field='action'] {
    min-width: 24ch;
}

#sale-history-table th[data-key='deleted_at'],
#sale-history-table td[data-field='deleted_at'] {
    min-width: 15ch;
}

#sale-history-table th[data-key='transaction_fees'],
#sale-history-table td[data-field='transaction_fees'] {
    min-width: 10ch;
}

#sale-history-table th[data-key='transaction_amount'],
#sale-history-table td[data-field='transaction_amount'] {
    min-width: 12ch;
}

#sale-history-table th[data-key='pru'],
#sale-history-table td[data-field='pru'] {
    min-width: 11ch;
}

#sale-history-table th[data-key='code_investing'],
#sale-history-table th[data-key='code_hiboo'],
#sale-history-table th[data-key='symbol'] {
    width: 54px;
    min-width: 54px;
    text-align: center;
}

#sale-history-table td[data-field='deleted_at'],
#sale-history-table td[data-field='last'],
#sale-history-table td[data-field='transaction_fees'],
#sale-history-table td[data-field='transaction_amount'],
#sale-history-table td[data-field='pru'],
#sale-history-table td[data-field='nb'],
#sale-history-table td[data-field='pl'] {
    text-align: right;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

#sale-history-table td[data-field='deleted_at'] {
    text-align: left;
}

#sale-history-table td[data-field='pl'] {
    font-weight: 600;
}

#sale-history-table td[data-field='pl'].is-positive {
    color: #46c97b;
}

#sale-history-table td[data-field='pl'].is-negative {
    color: #ff5e5e;
}

.history-table--sortable th {
    cursor: pointer;
    position: relative;
    user-select: none;
}

.history-table--sortable th::after {
    content: '';
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.3;
    font-size: 0.8em;
}

.history-table--sortable th.is-sorted-asc::after {
    content: '▲';
    opacity: 0.8;
}

.history-table--sortable th.is-sorted-desc::after {
    content: '▼';
    opacity: 0.8;
}

.history-empty {
    padding: 18px 22px;
    background: rgba(21, 33, 54, 0.7);
    border: 1px dashed rgba(78, 110, 166, 0.5);
    border-radius: 12px;
    color: #8aa2c8;
    font-size: 14px;
    text-align: center;
}

.history-empty--inline {
    width: 100%;
    border-style: solid;
}

.history-event {
    font-weight: 600;
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 0.04em;
}

.history-event.is-buy {
    color: #46c97b;
}

.history-event.is-sell {
    color: #ff9b9b;
}

.sales-actions-column {
    text-align: center;
    width: 90px;
}

.sales-actions-cell {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.sales-action-button {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: rgba(70, 201, 123, 0.18);
    color: #e6e9ef;
    font-size: 16px;
    cursor: pointer;
    transition: transform 0.1s ease, background-color 0.2s ease;
}

.sales-action-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.sales-action-button:hover:not(:disabled) {
    transform: translateY(-1px);
}

.sales-action-restore {
    background: rgba(70, 201, 123, 0.25);
}

.sales-action-restore:hover:not(:disabled) {
    background: rgba(70, 201, 123, 0.4);
}

.sales-action-delete {
    background: rgba(255, 94, 94, 0.25);
}

.sales-action-delete:hover:not(:disabled) {
    background: rgba(255, 94, 94, 0.4);
}

.sales-link-cell {
    text-align: center;
    white-space: nowrap;
}

.sales-site-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(11, 18, 32, 0.85);
    border: 1px solid #1f2a44;
    color: #9bc1ff;
    text-decoration: none;
}

.sales-site-link:hover {
    background: rgba(43, 92, 255, 0.2);
    border-color: rgba(43, 92, 255, 0.4);
    text-decoration: none;
}

.sales-site-link__icon {
    width: 18px;
    height: 18px;
    display: block;
}

.sales-site-link__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    font-size: 10px;
    font-weight: 700;
    line-height: 1;
}

.sales-site-link__badge--yahoo {
    background: rgba(43, 92, 255, 0.22);
    color: #b8cdff;
}

.variation-cell {
    cursor: pointer;
}

.variation-cell:hover {
    text-decoration: underline;
}

.variation-popup {
    position: fixed;
    width: min(640px, 96vw);
    max-height: min(640px, 85vh);
    overflow: hidden;
    padding: 14px;
    border-radius: 14px;
    background: #111a2f;
    border: 1px solid #1f2a44;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
    opacity: 0;
    pointer-events: none;
    transform: translateY(6px);
    transition: opacity 0.15s ease, transform 0.15s ease;
    z-index: 30;
}

.variation-popup.is-open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.variation-popup__header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.variation-popup__title {
    font-size: 14px;
    font-weight: 600;
}

.variation-popup__symbol {
    font-size: 12px;
    color: #8aa2c8;
}

.variation-popup__status {
    min-height: 18px;
    font-size: 12px;
    color: #9bb3d5;
    margin-bottom: 6px;
}

.variation-popup__status.is-error {
    color: #ff7b7b;
}

.variation-popup__chart {
    margin-bottom: 10px;
}

.variation-popup__chart-head {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 12px;
    color: #8aa2c8;
    margin-bottom: 6px;
}

.variation-popup__chart-head-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.variation-popup__chart-title {
    display: inline-flex;
    align-items: baseline;
    gap: 8px;
    color: #8aa2c8;
}

.variation-popup__chart-window {
    padding: 2px 6px;
    border-radius: 8px;
    background: rgba(43, 92, 255, 0.15);
    color: #9bc1ff;
    font-size: 11px;
}

.variation-popup__chart-perf {
    padding: 2px 6px;
    border-radius: 8px;
    border: 1px solid rgba(31, 42, 68, 0.7);
    background: rgba(11, 18, 32, 0.7);
    color: #e6e9ef;
    font-size: 11px;
}

.variation-popup__chart-perf.metric-positive {
    border-color: rgba(70, 201, 123, 0.55);
    background: rgba(11, 18, 32, 0.7);
    color: #9fe3c4;
}

.variation-popup__chart-perf.metric-negative {
    border-color: rgba(255, 94, 94, 0.55);
    background: rgba(11, 18, 32, 0.7);
    color: #ffb3b3;
}

.variation-popup__chart-controls {
    display: inline-flex;
    gap: 6px;
}

.variation-popup__chart-range {
    color: #9bc1ff;
}

.variation-popup__chart-slider {
    margin: 6px 0 2px;
}

.variation-popup__range {
    width: 100%;
    cursor: pointer;
    accent-color: #6ee7b7;
}

.variation-popup__range:focus {
    outline: none;
}

.variation-popup__range::-webkit-slider-runnable-track {
    height: 6px;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(70, 201, 123, 0.35), rgba(43, 92, 255, 0.4));
}

.variation-popup__range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    margin-top: -5px;
    border-radius: 50%;
    background: #e6e9ef;
    border: 1px solid rgba(31, 42, 68, 0.8);
    box-shadow: 0 0 0 3px rgba(110, 231, 183, 0.25);
}

.variation-popup__range::-moz-range-track {
    height: 6px;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(70, 201, 123, 0.35), rgba(43, 92, 255, 0.4));
}

.variation-popup__range::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #e6e9ef;
    border: 1px solid rgba(31, 42, 68, 0.8);
    box-shadow: 0 0 0 3px rgba(110, 231, 183, 0.25);
}

.variation-popup__zoom {
    width: 32px;
    height: 26px;
    border-radius: 8px;
    border: 1px solid rgba(31, 42, 68, 0.8);
    background: rgba(11, 18, 32, 0.8);
    color: #e6e9ef;
    cursor: pointer;
    font-size: 12px;
    line-height: 1;
}

.variation-popup__chart-legend {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 11px;
    color: #8aa2c8;
}

.variation-popup__chart-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    opacity: 0.9;
}

.variation-popup__chart-legend-item::before {
    content: '';
    width: 14px;
    height: 2px;
    border-radius: 999px;
    background: #9bc1ff;
}

.variation-popup__chart-legend-item--ma20::before {
    background: #6ee7b7;
}

.variation-popup__chart-legend-item--ma50::before {
    background: #f6c177;
}

.variation-popup__chart-legend-item.is-disabled {
    opacity: 0.35;
}

.variation-popup__chart-canvas {
    position: relative;
}

.variation-popup__chart-svg {
    width: 100%;
    height: 180px;
    display: block;
    background: rgba(11, 18, 32, 0.75);
    border-radius: 12px;
    border: 1px solid rgba(31, 42, 68, 0.7);
}

.variation-popup__chart-line {
    fill: none;
    stroke: #9bc1ff;
    stroke-width: 2;
}

.variation-popup__chart-ma {
    fill: none;
    stroke-width: 1.6;
    opacity: 0.9;
}

.variation-popup__chart-ma--20 {
    stroke: #6ee7b7;
}

.variation-popup__chart-ma--50 {
    stroke: #f6c177;
}

.variation-popup__chart-baseline {
    stroke: rgba(255, 255, 255, 0.35);
    stroke-width: 1;
    stroke-dasharray: 4 4;
}

.variation-popup__chart-grid {
    stroke: rgba(255, 255, 255, 0.08);
    stroke-width: 1;
}

.variation-popup__chart-label {
    fill: #8aa2c8;
    font-size: 12px;
}

.variation-popup__chart-marker-line {
    stroke: rgba(255, 255, 255, 0.35);
    stroke-width: 1;
}

.variation-popup__chart-marker-dot {
    fill: #9bc1ff;
    stroke: #111a2f;
    stroke-width: 1;
}

.variation-popup__chart-extrema-dot {
    fill: #e6e9ef;
    stroke: #111a2f;
    stroke-width: 1;
}

.variation-popup__chart-extrema-label {
    fill: #e6e9ef;
    font-size: 11px;
    paint-order: stroke;
    stroke: rgba(17, 26, 47, 0.75);
    stroke-width: 3;
}

.variation-popup__tooltip {
    position: absolute;
    pointer-events: none;
    padding: 6px 8px;
    background: rgba(8, 12, 20, 0.92);
    border: 1px solid rgba(31, 42, 68, 0.9);
    border-radius: 8px;
    font-size: 11px;
    color: #e6e9ef;
    white-space: nowrap;
    transform: translate(-50%, -120%);
}

.variation-popup__chart-area {
    fill: rgba(43, 92, 255, 0.18);
}

.variation-popup__chart-dates {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: #8aa2c8;
    margin-top: 4px;
}

.variation-popup__table-wrapper {
    max-height: 220px;
    overflow: auto;
    border-radius: 10px;
    border: 1px solid rgba(31, 42, 68, 0.8);
}

.variation-popup__table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
    font-variant-numeric: tabular-nums;
}

.variation-popup__table thead {
    position: sticky;
    top: 0;
    background: #10192c;
    z-index: 1;
}

.variation-popup__table th,
.variation-popup__table td {
    padding: 6px 8px;
    border-bottom: 1px solid rgba(31, 42, 68, 0.7);
    text-align: right;
    white-space: nowrap;
}

.variation-popup__table th:first-child,
.variation-popup__table td:first-child {
    text-align: left;
}

.variation-popup__table tbody tr:last-child td {
    border-bottom: none;
}

.variation-popup.is-expanded {
    width: calc(100vw - 24px);
    height: calc(100vh - 24px);
    max-height: none;
    left: 12px;
    top: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.variation-popup.is-expanded .variation-popup__chart {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.variation-popup.is-expanded .variation-popup__chart-canvas {
    flex: 1;
}

.variation-popup.is-expanded .variation-popup__chart-svg {
    height: 100%;
}

.performance-chart__area {
    fill: rgba(70, 201, 123, 0.16);
}

.performance-chart__line {
    fill: none;
    stroke: #6ee7b7;
    stroke-width: 2.2;
}

.performance-chart__baseline {
    stroke: rgba(255, 255, 255, 0.36);
    stroke-width: 1;
    stroke-dasharray: 4 4;
}

.performance-chart__grid {
    stroke: rgba(255, 255, 255, 0.08);
    stroke-width: 1;
}

.performance-chart__label {
    fill: #8aa2c8;
    font-size: 12px;
}

.performance-chart__marker-line {
    stroke: rgba(255, 255, 255, 0.35);
    stroke-width: 1;
}

.performance-chart__marker-dot {
    fill: #6ee7b7;
    stroke: #111a2f;
    stroke-width: 1;
}

.performance-modal__dialog {
    width: min(1120px, 94vw);
    border-radius: 8px;
}

.performance-modal__controls {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}

.performance-modal__period {
    border: 1px solid #1f2a44;
    border-radius: 8px;
    background: rgba(11, 18, 32, 0.75);
    color: #e6e9ef;
    padding: 7px 12px;
    cursor: pointer;
}

.performance-modal__period.is-active {
    border-color: rgba(110, 231, 183, 0.6);
    color: #9fe3c4;
}

.performance-modal__period:disabled {
    cursor: not-allowed;
    opacity: 0.45;
}

.performance-modal__status {
    min-height: 18px;
    color: #8aa2c8;
    font-size: 13px;
    margin-bottom: 8px;
}

.performance-modal__chart-canvas {
    position: relative;
    border-radius: 8px;
    border: 1px solid rgba(31, 42, 68, 0.75);
    background: rgba(11, 18, 32, 0.75);
    overflow: hidden;
}

.performance-modal__chart-svg {
    width: 100%;
    height: min(58vh, 460px);
    min-height: 280px;
    display: block;
}

.performance-modal__tooltip {
    position: absolute;
    pointer-events: none;
    padding: 6px 8px;
    background: rgba(8, 12, 20, 0.92);
    border: 1px solid rgba(31, 42, 68, 0.9);
    border-radius: 8px;
    color: #e6e9ef;
    font-size: 11px;
    white-space: nowrap;
    transform: translate(-50%, -120%);
}

.performance-modal__dates {
    display: flex;
    justify-content: space-between;
    color: #8aa2c8;
    font-size: 12px;
    margin-top: 6px;
}

.sale-modal {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(7, 12, 22, 0.7);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 20;
}

.sale-modal.is-open {
    opacity: 1;
    pointer-events: auto;
}

.sale-modal__dialog {
    width: min(780px, 92vw);
    border-radius: 16px;
    padding: 20px;
    background: #111a2f;
    border: 1px solid #1f2a44;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.sale-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.sale-modal__title {
    margin: 0;
    font-size: 18px;
}

.sale-modal__close {
    border: none;
    background: transparent;
    color: #8aa2c8;
    font-size: 20px;
    cursor: pointer;
}

.sale-modal__action {
    font-size: 14px;
    color: #9bb3d5;
    margin-bottom: 14px;
}

.sale-modal__field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 12px;
}

.sale-modal__input-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sale-modal__input {
    flex: 1;
    background: rgba(11, 18, 32, 0.8);
    border: 1px solid #1f2a44;
    border-radius: 10px;
    color: #e6e9ef;
    padding: 8px 10px;
    font-variant-numeric: tabular-nums;
}

.sale-modal__suffix {
    padding: 6px 10px;
    border-radius: 8px;
    background: rgba(43, 92, 255, 0.18);
    color: #9bc1ff;
    font-size: 12px;
    white-space: nowrap;
}

.sale-modal__hint {
    font-size: 12px;
    color: #8aa2c8;
}

.sale-modal__error {
    min-height: 18px;
    margin-bottom: 8px;
    color: #ff7b7b;
    font-size: 12px;
}

.sale-modal__actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.sale-modal__button {
    border: 1px solid #223358;
    border-radius: 10px;
    padding: 8px 14px;
    background: transparent;
    color: #e6e9ef;
    cursor: pointer;
    transition: transform 0.1s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.sale-modal__button:hover:not(:disabled) {
    transform: translateY(-1px);
}

.sale-modal__button--primary {
    background: #2b5cff;
    border-color: #2b5cff;
}

.search-results {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 260px;
    overflow-y: auto;
    margin-top: 6px;
}

.search-results-empty {
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px dashed rgba(78, 110, 166, 0.5);
    color: #8aa2c8;
    font-size: 13px;
    text-align: center;
}

.search-result {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid #1f2a44;
    background: rgba(11, 18, 32, 0.65);
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.search-result:hover {
    background: rgba(43, 92, 255, 0.12);
    border-color: rgba(43, 92, 255, 0.35);
}

.search-result-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.search-result-title {
    font-weight: 600;
    color: #e6e9ef;
}

.search-result-meta {
    font-size: 12px;
    color: #8aa2c8;
}

.search-result-action {
    background: rgba(70, 201, 123, 0.18);
    border: 1px solid rgba(70, 201, 123, 0.5);
    color: #9af2c1;
    border-radius: 10px;
    padding: 6px 10px;
    font-size: 12px;
    cursor: pointer;
}

.sale-modal__button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.split-modal__dialog {
    max-width: 420px;
}

.split-modal__ratio {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 8px;
    align-items: center;
}

.split-modal__ratio-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.split-modal__ratio label {
    font-size: 12px;
    color: #8aa2c8;
}

.split-modal__ratio-sep {
    text-align: center;
    color: #8aa2c8;
}

.split-modal__preview {
    display: grid;
    gap: 6px;
    font-size: 13px;
    color: #c9d6f0;
    padding: 8px 10px;
    border: 1px solid rgba(31, 42, 68, 0.6);
    border-radius: 10px;
    background: rgba(11, 18, 32, 0.6);
}

.import-modal__dialog {
    max-width: 560px;
}

.import-modal__field {
    display: flex;
    align-items: center;
    gap: 10px;
}

.import-modal__preview {
    margin-top: 10px;
    padding: 10px 12px;
    border: 1px solid rgba(31, 42, 68, 0.6);
    border-radius: 12px;
    background: rgba(11, 18, 32, 0.6);
    font-size: 13px;
    color: #c9d6f0;
    line-height: 1.4;
}

.import-preview__sample {
    font-size: 12px;
    color: #8aa2c8;
    margin: 4px 0 8px;
}

.ai-modal__dialog {
    max-width: 620px;
    max-height: 90vh;
    overflow-y: auto;
}

.ai-suggestions {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 6px;
    max-height: 156px;
    overflow-y: auto;
    padding-right: 4px;
}

.ai-suggestion {
    background: rgba(255, 179, 71, 0.1);
    border: 1px solid rgba(255, 179, 71, 0.35);
    color: #ffcc7a;
    border-radius: 10px;
    padding: 6px 10px;
    text-align: left;
    cursor: pointer;
    font-size: 13px;
    transition: background-color 0.2s ease, transform 0.15s ease;
}

.ai-suggestion:hover {
    background: rgba(255, 179, 71, 0.2);
    transform: translateY(-1px);
}

.ai-modal__input {
    min-height: 90px;
}

.ai-thread {
    margin-top: 10px;
    border: 1px solid #1f2a44;
    border-radius: 12px;
    padding: 10px;
    background: rgba(11, 18, 32, 0.7);
    max-height: 38vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ai-thread-empty {
    font-size: 13px;
    color: #6f83a8;
}

.ai-message {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 8px 10px;
    border-radius: 10px;
    border: 1px solid transparent;
}

.ai-message--user {
    background: rgba(43, 92, 255, 0.12);
    border-color: rgba(43, 92, 255, 0.3);
}

.ai-message--assistant {
    background: rgba(70, 201, 123, 0.12);
    border-color: rgba(70, 201, 123, 0.3);
}

.ai-message__label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #8aa2c8;
}

.ai-message__content {
    font-size: 13px;
    color: #e6e9ef;
    white-space: pre-wrap;
}

body.modal-open {
    overflow: hidden;
}




.password-section {
    max-width: 560px;
    margin: 0 auto;
}

.password-form {
    display: grid;
    gap: 16px;
}

.password-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

@media (max-width: 480px) {
    .password-section {
        max-width: none;
        margin: 0;
    }

    .password-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .password-actions .history-button {
        width: 100%;
    }
}

/* Tablet and iPad Pro optimization */
@media (min-width: 481px) and (max-width: 1180px) {
    .container,
    .history-container {
        padding-left: 16px;
        padding-right: 16px;
    }

    .page-header-shell {
        gap: 12px;
        padding-right: 0;
    }

    .page-header-shell--main {
        margin-bottom: 12px;
    }

    .main-header {
        gap: 14px;
        margin-bottom: 12px;
    }

    .summary-cards {
        justify-content: flex-start;
        gap: 12px;
    }

    .summary-card {
        min-width: min(280px, 48%);
        flex: 1 1 280px;
        border-radius: 10px;
    }

    .section-header {
        margin-top: 10px;
    }

    section.by-type {
        padding-left: 0;
        padding-right: 0;
    }

    .settings-panel__columns {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .watchlists-container,
    .history-sales-section,
    .help-section,
    .help-toc {
        border-radius: 10px;
    }

    .sale-modal__dialog,
    .performance-modal__dialog,
    .dividends-modal__dialog {
        width: min(900px, 94vw);
        max-height: 88vh;
        overflow-y: auto;
    }

    .log-workspace {
        grid-template-columns: 1fr;
    }

    #admin-users-table {
        min-width: 960px;
    }

    #admin-users-table th:last-child,
    #admin-users-table td:last-child {
        min-width: 320px;
    }

    .admin-user-actions {
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        gap: 8px;
    }

    .admin-user-actions .history-button {
        width: auto;
        flex: 0 0 auto;
        padding-left: 12px;
        padding-right: 12px;
        white-space: nowrap;
    }
}

/* Mobile iPhone optimization */
@media (max-width: 480px) {
    body { overflow-x: hidden; }

    input,
    select,
    textarea,
    button { font-size: 16px; }

    .auth-shell {
        align-items: flex-start;
        padding: max(18px, env(safe-area-inset-top)) 14px max(18px, env(safe-area-inset-bottom));
    }

    .auth-card {
        padding: 20px;
        margin-top: 8vh;
    }

    .container,
    .history-container {
        padding: 10px max(10px, env(safe-area-inset-left)) max(20px, env(safe-area-inset-bottom)) max(10px, env(safe-area-inset-right));
    }

    .page-header-shell {
        flex-direction: column;
        gap: 8px;
        padding: 0;
        margin-bottom: 8px;
    }

    .page-header-shell--main {
        margin-bottom: 6px;
    }

    .main-header {
        gap: 10px;
        margin-bottom: 0;
    }

    .page-header-shell > .main-header,
    .page-header-shell > .history-header {
        width: 100%;
        max-width: none;
        padding: 0;
    }

    .app-menu-bar {
        flex: 0 0 auto;
        width: 100%;
        position: sticky;
        top: 0;
        z-index: 18;
        padding: 0;
        background: rgba(11, 18, 32, 0.86);
        backdrop-filter: blur(12px);
    }

    .app-menu { width: 100%; }

    .app-menu__toggle {
        width: 48px;
        min-width: 48px;
        min-height: 48px;
        border-radius: 8px;
    }

    .app-menu__panel {
        position: fixed;
        top: calc(58px + env(safe-area-inset-top));
        left: max(10px, env(safe-area-inset-left));
        right: max(10px, env(safe-area-inset-right));
        width: auto;
        max-height: calc(100dvh - 76px - env(safe-area-inset-bottom));
        overflow-y: auto;
        border-radius: 8px;
    }

    .app-menu__section {
        gap: 6px;
        padding: 8px;
    }

    .app-menu__item,
    .app-menu__action,
    .history-button,
    .sale-modal__button {
        min-height: 44px;
        border-radius: 8px;
    }

    .history-header,
    .sales-container .history-header {
        align-items: stretch;
        gap: 10px;
    }

    .history-header h1,
    .main-header h1 {
        font-size: 22px;
        line-height: 1.2;
    }

    .summary-cards {
        gap: 8px;
        margin-bottom: 0;
    }

    .summary-card {
        border-radius: 8px;
        padding: 10px 12px;
        min-width: 0;
    }

    .summary-card-header,
    .summary-cash-row { gap: 8px; }

    .summary-amount { font-size: 17px; }

    .summary-performance { padding: 8px; }

    .summary-performance--card .summary-performance__metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .summary-performance__metric-value {
        font-size: 12px;
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .quotes-progress {
        width: 100%;
        align-items: stretch;
        border-radius: 8px;
        flex-direction: column;
        gap: 6px;
    }

    .quotes-progress__label {
        min-width: 0;
        text-align: left;
    }

    .settings-panel {
        margin: 12px 0;
        padding: 12px;
        border-radius: 8px;
        --settings-label-width: 0px;
    }

    .settings-panel__columns,
    .settings-panel__grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .settings-panel__field {
        align-items: stretch;
        gap: 6px;
    }

    .settings-panel__field label,
    .settings-panel__input,
    .settings-panel__input input,
    .settings-select,
    .settings-input,
    .settings-input--short,
    .settings-input--key {
        width: 100%;
        min-width: 0;
    }

    .settings-panel__help,
    .settings-panel__hint {
        margin-left: 0;
        padding-left: 0;
    }

    .settings-panel__footer,
    .settings-panel__footer-row,
    .settings-panel__footer-group {
        align-items: stretch;
        flex-direction: column;
        gap: 8px;
    }

    .settings-panel__footer .history-button,
    .settings-panel__footer button,
    .settings-panel__footer a { width: 100%; }

    .section-header,
    .section-actions--with-toolbar {
        align-items: stretch;
        flex-direction: column;
        gap: 8px;
    }

    .section-actions--with-toolbar {
        flex: 0 0 auto;
        justify-content: flex-start;
        margin-left: 0;
    }

    .section-header {
        margin: 8px 0 6px;
    }

    section.by-type {
        padding-left: 0;
        padding-right: 0;
    }

    section.by-type:first-of-type .section-header {
        margin-top: 4px;
    }

    .section-header h2 { font-size: 18px; }

    .section-actions,
    .section-actions__primary,
    .main-table-toolbar,
    .main-table-toolbar__quotes {
        align-items: stretch;
        flex-direction: column;
        width: 100%;
    }

    .section-actions > button,
    .section-actions__primary button,
    .main-table-toolbar__refresh,
    .main-table-toolbar__search,
    .history-header-actions .history-button { width: 100%; }

    .main-table-toolbar__quotes {
        gap: 6px;
        padding: 6px 8px;
    }

    .quotes-last-update {
        white-space: normal;
        line-height: 1.25;
    }

    section.by-type,
    .history-table-wrapper,
    .ai-log-table-wrap,
    .dividends-modal__table-wrapper,
    .variation-popup__table-wrapper {
        margin-left: -10px;
        margin-right: -10px;
        padding-left: 10px;
        padding-right: 10px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior-x: contain;
    }

    .data-table,
    .history-table,
    .watchlist-table,
    #ai-log-table,
    #call-log-table,
    #login-log-table,
    #admin-users-table,
    .dividends-modal__table--wide { min-width: 680px; }

    th,
    td { font-size: 12px; }

    td input,
    td textarea {
        font-size: 15px;
        min-height: 36px;
    }

    .col-comment,
    .col-comment.comment-expanded {
        min-width: 22ch;
        max-width: 28ch;
    }

    .watchlist-section,
    .help-section,
    .help-toc,
    .ai-log-section,
    .admin-users-section {
        border-radius: 8px;
        padding: 12px;
    }

    .watchlist-header {
        align-items: stretch;
        flex-direction: column;
    }

    .watchlist-title,
    .watchlist-name-input,
    .watchlist-header-actions,
    .watchlist-header-actions .history-button {
        width: 100%;
        min-width: 0;
    }

    .watchlist-filters,
    .ai-log-filters,
    .admin-users-create,
    .performance-modal__controls,
    .dividends-modal__filters {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .ai-log-filter input,
    .ai-log-filter select,
    .admin-user-password-input {
        width: 100%;
        min-width: 0;
    }

    .log-tabs {
        overflow-x: auto;
        padding-bottom: 0;
        -webkit-overflow-scrolling: touch;
    }

    .log-tab {
        flex: 0 0 auto;
        white-space: nowrap;
    }

    .log-workspace { gap: 12px; }
    .ai-log-detail { border-radius: 8px; }

    #admin-users-table {
        min-width: 960px;
    }

    #admin-users-table th:last-child,
    #admin-users-table td:last-child {
        min-width: 320px;
    }

    .admin-user-actions {
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        gap: 8px;
    }

    .admin-user-actions .history-button {
        width: auto;
        flex: 0 0 auto;
        padding-left: 12px;
        padding-right: 12px;
        white-space: nowrap;
    }

    .sale-modal {
        align-items: flex-end;
        justify-content: stretch;
        padding: 0;
    }

    .sale-modal__dialog,
    .ai-modal__dialog,
    .search-modal__dialog,
    .split-modal__dialog,
    .import-modal__dialog,
    .performance-modal__dialog,
    .dividends-modal__dialog {
        width: 100%;
        max-width: none;
        max-height: calc(100dvh - env(safe-area-inset-top));
        border-radius: 12px 12px 0 0;
        padding: 16px;
        overflow-y: auto;
    }

    .sale-modal__actions {
        flex-direction: column-reverse;
        gap: 8px;
    }

    .sale-modal__button { width: 100%; }

    .search-result {
        align-items: stretch;
        flex-direction: column;
        gap: 8px;
    }

    .search-result-action {
        width: 100%;
        min-height: 40px;
    }

    .import-modal__field {
        align-items: stretch;
        flex-direction: column;
    }

    .split-modal__ratio { grid-template-columns: 1fr; }
    .split-modal__ratio-sep { display: none; }
    .ai-thread { max-height: 34dvh; }

    .performance-modal__chart-canvas,
    .variation-popup__chart-canvas { min-height: 220px; }

    .performance-modal__dates,
    .variation-popup__chart-dates {
        gap: 8px;
        overflow-x: auto;
        white-space: nowrap;
    }

    .variation-popup {
        left: max(8px, env(safe-area-inset-left));
        right: max(8px, env(safe-area-inset-right));
        bottom: max(8px, env(safe-area-inset-bottom));
        width: auto;
        max-height: calc(100dvh - 16px - env(safe-area-inset-top));
        overflow-y: auto;
        border-radius: 8px;
    }

    .variation-popup.is-expanded {
        inset: max(8px, env(safe-area-inset-top)) max(8px, env(safe-area-inset-right)) max(8px, env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-left));
        width: auto;
    }

    .variation-popup__chart-head,
    .variation-popup__chart-head-row,
    .variation-popup__chart-title,
    .variation-popup__chart-controls {
        align-items: stretch;
        flex-direction: column;
    }

    .variation-popup__zoom {
        width: 100%;
        min-height: 40px;
    }

    .notifications-panel {
        position: fixed;
        left: max(10px, env(safe-area-inset-left));
        right: max(10px, env(safe-area-inset-right));
        top: 68px;
        width: auto;
        max-height: calc(100dvh - 86px - env(safe-area-inset-bottom));
        border-radius: 8px;
    }
}

@media print {
    @page {
        size: A4;
        margin: 12mm;
    }

    html,
    body {
        height: auto;
        margin: 0;
        padding: 0;
    }

    body {
        background: #fff;
        color: #000;
    }

    .container {
        padding: 0;
    }

    .summary-actions,
    .section-actions,
    .summary-cash-input,
    .app-menu-bar,
    .history-link,
    .icon-button,
    .sale-modal,
    .row-refresh,
    .summary-remove-account,
    .summary-add-account {
        display: none !important;
    }

    .summary-card,
    .summary-card .summary-cash-row,
    .summary-card .cash-input {
        background: #fff;
        color: #000;
        border: 1px solid #ddd;
    }

    .summary-label,
    .summary-label-input,
    .summary-card .summary-cash,
    .summary-card .summary-holdings-prev {
        color: #444;
    }

    .summary-label-input {
        border: 1px solid #ddd;
        background: #fff;
    }

    th,
    td {
        background: #fff;
        color: #000;
    }

    section.by-type {
        break-inside: avoid;
    }

    input,
    textarea {
        border: none;
        background: transparent;
        color: #000;
        padding: 0;
        box-shadow: none;
    }

    th.col-link,
    td.col-link,
    th.col-actions,
    td.col-actions {
        display: none !important;
    }
}
