:root {
    /* Brand */
    --brand: #880000;
    --brand-hover: #6b0000;

    /* Text */
    --text: #000;
    --text-muted: #666;

    /* Backgrounds */
    --bg-page: #eee;
    --bg-card: #f5f5f5;
    --bg-code: #222;
    --bg-inset: #e5e5e5;
    --bg-highlight: #f5f5f5;

    /* Borders */
    --border: #ddd;
    --border-input: #ccc;
    --border-hover: #999;

    /* Trading */
    --buy: #16a34a;
    --buy-hover: #15803d;
    --sell: #dc2626;
    --sell-hover: #b91c1c;

    /* Semantic */
    --success-fg: #155724;
    --success-bg: #d4edda;
    --success-border: #c3e6cb;
    --info-fg: #004085;
    --info-bg: #cce5ff;
    --warning-fg: #856404;
    --warning-bg: #fff3cd;
    --danger-fg: #721c24;
    --danger-bg: #f8d7da;
    --neutral-fg: #383d41;
    --neutral-bg: #6b7280;

    /* Buttons */
    --btn-secondary: #6c757d;
    --btn-secondary-hover: #5a6268;

    /* Misc */
    --error: #cc0000;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Go', system-ui, sans-serif;
    line-height: 1.5;
    max-width: 800px;
    margin: 0 auto;
    padding: 1rem;
    color: var(--text);
    background: var(--bg-page);
}

pre {
    background: var(--bg-code);
    color: var(--bg-card);
    padding: 1rem;
    border-radius: 4px;
    overflow-x: auto;
    font-size: 0.875rem;
}

header {
    margin-bottom: 0.1em;
    border-bottom: 1px solid var(--border);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2em;
}

nav .btn {
    transform: scale(0.85);
}

.logo {
    font-weight: bold;
    font-size: 1.5rem;
    text-decoration: none;
    color: inherit;
}

.logo-img {
    height: 1rem;
    width: auto;
    vertical-align: middle;
    margin-right: 0.75rem;
}

h1 {
    margin-bottom: 1rem;
}

h2 {
    margin-bottom: 0.5rem;
}

section + section {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
}

p {
    margin-bottom: 1rem;
}

ul, ol {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

a {
    color: var(--brand);
}

.btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: var(--brand);
    color: #fff;
    text-decoration: none;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    font-family: inherit;
    line-height: inherit;
}

.btn:hover {
    background: var(--brand-hover);
}


.error {
    color: var(--error);
}

.landing {
    text-align: center;
    padding: 2rem 0;
}

.landing h1 {
    font-size: 2rem;
}

.landing section {
    text-align: left;
}

.example-market {
    margin-top: 1.5rem;
}

.example-market h3 {
    margin-bottom: 0.5rem;
}


#auth {
    margin: 2rem 0;
}

/* Hide JS-only elements by default, show no-JS login */
.js-only {
    display: none;
}

.js-enabled .js-only {
    display: block;
}

.js-enabled .nojs-login {
    display: none;
}

.nojs-login {
    max-width: 500px;
    margin: 0 auto;
    text-align: left;
    padding: 1.5rem;
    background: var(--bg-card);
    border-radius: 8px;
}

.nojs-login h3 {
    margin-bottom: 1rem;
    text-align: center;
}

.nojs-login pre {
    margin-bottom: 1.5rem;
}

.nojs-login code {
    font-family: 'Go Mono', ui-monospace, monospace;
}

.nojs-login form {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.nojs-login label {
    font-weight: 500;
}

.nojs-login input {
    font-family: 'Go Mono', ui-monospace, monospace;
    font-size: 0.875rem;
}

.nojs-login .btn {
    margin-top: 0.5rem;
}

.login-tabs {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tab {
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-input);
    background: var(--bg-card);
    cursor: pointer;
    border-radius: 4px;
    font-size: 1rem;
}

.tab:hover {
    background: var(--bg-inset);
}

.tab.active {
    background: var(--brand);
    color: #fff;
    border-color: var(--brand);
}

#login-bunker {
    max-width: 400px;
    margin: 0 auto;
}

#bunker-input {
    width: 100%;
    margin-bottom: 0.5rem;
}

#bunker-status {
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

#bunker-status a {
    color: var(--brand);
}

#login-qr {
    max-width: 400px;
    margin: 0 auto;
}

#login-qr > p {
    margin-bottom: 1rem;
    color: var(--text-muted);
}

.invoice-display {
    text-align: center;
}

.qr-container {
    display: inline-block;
    padding: 1rem;
    background: white;
    border-radius: 8px;
    border: 1px solid var(--border);
    margin-bottom: 1rem;
}

.qr-container svg {
    display: block;
}

.bolt11 {
    display: block;
    word-break: break-all;
    text-align: left;
}

.qr-link {
    display: block;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

#qr-status {
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

#qr-retry {
    margin-top: 0.5rem;
}

.logout-form {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pubkey {
    font-family: 'Go Mono', monospace;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.pubkey a {
    color: inherit;
    text-decoration: none;
}

.pubkey a:hover {
    text-decoration: underline;
}

.avatar-small {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 50%;
    object-fit: cover;
}

.avatar-large {
    width: 5rem;
    height: 5rem;
    border-radius: 50%;
    object-fit: cover;
}

.auth-icon {
    display: inline-block;
    width: 1em;
    height: 1em;
    vertical-align: middle;
    margin-left: 0.25em;
}

.auth-icon-nostr {
    width: 1.5em;
    height: 1.5em;
}

.auth-icon-google {
    line-height: 1em;
    text-align: center;
    font-weight: bold;
    color: #000;
}

/* Market brand in header */
.market-brand {
    font-weight: bold;
    font-size: 1.5rem;
    text-decoration: none;
    color: inherit;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.market-brand-img {
    width: 24px;
    height: 24px;
    border-radius: 4px;
    object-fit: cover;
}

/* User nav in header */
.user-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Tab bar */
.tab-bar {
    display: flex;
    justify-content: space-between;
    margin-top: 0.5rem;
    gap: 0.5rem;
}

.tabs-left,
.tabs-right {
    display: flex;
    gap: 0.25rem;
}

.tab-bar .tab {
    padding: 0.375rem 0.75rem;
    text-decoration: none;
    color: var(--text-muted);
    border-bottom: 2px solid transparent;
    font-size: 0.875rem;
    border-radius: 0;
    border-left: none;
    border-right: none;
    border-top: none;
    background: none;
}

.tab-bar .tab:hover {
    color: var(--text);
    background: none;
}

.tab-bar .tab.active {
    color: var(--brand);
    border-bottom-color: var(--brand);
    background: none;
}

.badge-count {
    display: inline-block;
    font-size: 0.75rem;
    padding: 0 0.375rem;
    background: var(--brand);
    color: #fff;
    border-radius: 999px;
    line-height: 1.4;
}


.plain-list {
    list-style: none;
    margin-left: 0;
}

.market-list {
    margin-bottom: 2rem;
}

.market-item {
    border: 1px solid var(--border);
    border-radius: 4px;
    margin-bottom: 1rem;
}

.market-item a {
    display: block;
    padding: 1rem;
    text-decoration: none;
    color: inherit;
}

.market-item a:hover {
    background: var(--bg-card);
}

.market-item h2 {
    font-size: 1.25rem;
    margin-bottom: 0.25rem;
}

.market-item p {
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.roles {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.badge {
    display: inline-block;
    font-size: 0.75rem;
    padding: 0.125rem 0.375rem;
    border-radius: 2px;
    text-transform: uppercase;
}

.role {
    white-space: nowrap;
}

.role.admin {
    background: var(--success-bg);
    color: var(--success-fg);
}

.role.oracle {
    background: var(--info-bg);
    color: var(--info-fg);
}

.role.custodian {
    background: var(--warning-bg);
    color: var(--warning-fg);
}

.role.member {
    background: var(--bg-inset);
    color: var(--neutral-fg);
}

.currency {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.empty {
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.form-group {
    margin-bottom: 1rem;
}

label {
    display: block;
    margin-bottom: 0.25rem;
    font-weight: 500;
}

input[type="text"],
textarea,
select {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid var(--border-input);
    border-radius: 4px;
    font-size: 1rem;
}

textarea {
    min-height: 100px;
    resize: vertical;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--brand);
}

[hidden] {
    display: none !important;
}

.market-view,
.events-list,
.propose-event,
.oracle-inbox,
.wallet,
div.custodian,
.deposit,
.withdraw,
.wallet-config,
.event-view,
.admin-section {
    padding: 1rem 0;
}

.market-image,
.event-image {
    width: 100%;
    height: 170px;
    object-fit: cover;
    border-radius: 4px;
}

.event-image-small {
    width: 3rem;
    height: 3rem;
    border-radius: 4px;
    object-fit: cover;
    display: inline-block;
    flex-shrink: 0;
}

.card {
    padding: 1rem;
    background: var(--bg-card);
    border-radius: 4px;
}

.info-block {
    margin: 1rem 0;
}

.info-block dt {
    font-weight: 500;
    color: var(--text-muted);
    font-size: 0.875rem;
}

.info-block dd {
    margin-bottom: 0.5rem;
}

.member-list li {
    padding: 0.25rem 0;
}

.invite-tree {
    margin-top: 0.75rem;
}

.invite-tree li {
    margin: 0.35rem 0;
}

.invite-tree ul {
    margin-top: 0.35rem;
    margin-left: 1.25rem;
}

.policy-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border);
}

.actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.invite-accept {
    padding: 2rem 0;
}

.invite-created {
    padding: 1rem 0;
}

.invite-url {
    display: flex;
    gap: 0.5rem;
    margin: 1rem 0;
}

.invite-url input {
    flex: 1;
    font-family: 'Go Mono', monospace;
}

.note {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.status {
    margin-bottom: 1rem;
}

.status-proposed {
    background: var(--warning-bg);
    color: var(--warning-fg);
}

.status-accepted, .status-accept {
    background: var(--success-bg);
    color: var(--success-fg);
}

.status-rejected, .status-reject {
    background: var(--danger-bg);
    color: var(--danger-fg);
}

.status-resolved {
    background: var(--info-bg);
    color: var(--info-fg);
}

.outcome-item {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem;
    border: 1px solid var(--border);
    margin-bottom: 0.5rem;
    border-radius: 4px;
}

.outcome-item.resolved {
    background: var(--success-bg);
    border-color: var(--success-border);
}

.outcome-label {
    font-weight: 500;
}

.outcome-quantity {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.outcomes .price-chart {
    margin-top: 1rem;
}

.positions {
    margin-top: 2rem;
}

.position-summary {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 0.75rem;
    font-family: 'Go Mono', monospace;
    font-size: 0.875rem;
}

.position-list li {
    display: flex;
    justify-content: space-between;
    padding: 0.25rem 0;
}

.position-amount {
    font-family: 'Go Mono', monospace;
}

.position-sell-now {
    font-size: 0.875rem;
    font-family: 'Go Mono', monospace;
}

.trade-buttons {
    display: flex;
    gap: 0.5rem;
}

.btn-secondary {
    background: var(--btn-secondary);
}

.btn-secondary:hover {
    background: var(--btn-secondary-hover);
}

.confirm-toggle {
    display: none;
}

.confirm-toggle ~ .confirm-panel {
    display: none;
}

.confirm-toggle:checked ~ label[for="confirm-start"] {
    display: none;
}

.confirm-toggle:checked ~ .confirm-panel {
    display: block;
}

.confirm-panel {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.oracle-form {
    margin-top: 1rem;
}

.resolution-note {
    margin: 1rem 0;
    background: var(--bg-inset);
}

.proposal-vote-list li {
    margin-bottom: 0.75rem;
}

.vote-note {
    margin: 0.25rem 0 0 1.5rem;
    font-style: italic;
    color: var(--text-muted);
}

.proposal-item {
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.proposal-item h2 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.event-item {
    border: 1px solid var(--border);
    border-radius: 4px;
    margin-bottom: 0.5rem;
}

.event-item a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    text-decoration: none;
    color: inherit;
}

.event-item a:hover {
    background: var(--bg-card);
}

.event-title {
    font-weight: 500;
    flex: 1;
}

.event-badges {
    display: flex;
    gap: 0.25rem;
    flex-shrink: 0;
}

.tradable {
    color: var(--success-fg);
    background: var(--success-bg);
}

.balance-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    background: var(--bg-card);
    border-radius: 4px;
    margin-bottom: 2rem;
}

.balance-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    text-transform: uppercase;
}

.balance-amount {
    font-size: 2rem;
    font-weight: bold;
}

.table-wrap {
    overflow-x: auto;
}

.ledger-table,
.balance-table {
    width: 100%;
    border-collapse: collapse;
}

.ledger-table th,
.ledger-table td,
.balance-table th,
.balance-table td {
    padding: 0.5rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.ledger-table th,
.balance-table th {
    font-weight: 500;
    color: var(--text-muted);
    font-size: 0.875rem;
}

.positive {
    color: var(--success-fg);
}

.negative {
    color: var(--danger-fg);
}

.success {
    color: var(--success-fg);
    background: var(--success-bg);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    margin-bottom: 1rem;
}

.price-chart {
    width: 100%;
    height: auto;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 4px;
}

.chart-axis {
    stroke: var(--border-input);
    stroke-width: 1;
}

.chart-label {
    font-size: 16px;
    fill: var(--text-muted);
    text-anchor: end;
}

.chart-tick {
    stroke: var(--border-input);
    stroke-width: 1;
}

.chart-xlabel {
    font-size: 16px;
    fill: var(--text-muted);
    text-anchor: middle;
}

.chart-legend {
    list-style: none;
    margin: 0.5rem 0 0 0;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.chart-legend li {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.875rem;
}

/* Trade form tabs */
.trade-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.trade-tab {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border);
    background: #fff;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.15s;
}

.trade-tab:hover {
    border-color: var(--border-hover);
}

.trade-tab:disabled {
    background: var(--bg-inset);
    color: var(--text-muted);
    border-color: var(--border-input);
    cursor: not-allowed;
    opacity: 0.7;
}

.trade-tab:disabled:hover {
    border-color: var(--border-input);
}

.trade-tab.active[data-action="buy"] {
    background: var(--buy);
    color: #fff;
    border-color: var(--buy);
}

.trade-tab.active[data-action="sell"] {
    background: var(--sell);
    color: #fff;
    border-color: var(--sell);
}

/* Outcome selector */
.outcome-selector {
    border: none;
    padding: 0;
    margin: 0 0 1rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.outcome-btn {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.15s;
    font-weight: normal;
    margin: 0;
}

.outcome-btn:hover {
    border-color: var(--brand);
    background: var(--bg-highlight);
}

.outcome-btn input {
    margin-right: 0.75rem;
    width: 18px;
    height: 18px;
}

.outcome-btn input:checked + .outcome-btn-label {
    font-weight: 600;
}

.outcome-btn:has(input:checked) {
    border-color: var(--brand);
    background: var(--bg-highlight);
}

.outcome-btn-label {
    flex: 1;
}

.outcome-btn-prob {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.outcome-btn.has-position .outcome-btn-prob::after {
    content: " \2022";
    color: var(--buy);
}

/* Current position display */
.current-position {
    margin-bottom: 1rem;
    padding: 0.5rem 0.75rem;
    background: var(--bg-highlight);
    border-radius: 4px;
    font-size: 0.875rem;
}

#position-value {
    font-weight: 600;
}

/* Quick amount buttons */
.quick-amounts {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.quick-btn {
    flex: 1;
    padding: 0.5rem;
    border: 1px solid var(--border);
    background: #fff;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.875rem;
    transition: all 0.15s;
    min-height: 44px;
}

.quick-btn:hover {
    border-color: var(--brand);
    background: var(--bg-highlight);
}

.quick-btn:active {
    background: var(--bg-highlight);
}

/* Trade preview panel */
.trade-preview {
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 4px;
}

.preview-row {
    display: flex;
    justify-content: space-between;
    padding: 0.25rem 0;
    font-size: 0.875rem;
}

.preview-row:first-child {
    font-weight: 500;
}

.preview-row .positive {
    color: var(--buy);
}

.preview-row .negative {
    color: var(--sell);
}

/* Trade submit button */
.trade-submit {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    font-weight: 500;
    min-height: 44px;
}

.trade-submit.buy-mode {
    background: var(--buy);
}

.trade-submit.buy-mode:hover {
    background: var(--buy-hover);
}

.trade-submit.sell-mode {
    background: var(--sell);
}

.trade-submit.sell-mode:hover {
    background: var(--sell-hover);
}

/* Balance info */
.balance-info {
    margin-top: 1rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Hide noscript submit button when JS is available */
.trade-submit + noscript .trade-buttons {
    display: none;
}

/* Status badge for closed trading */
.status-closed {
    background: var(--neutral-bg);
    color: #fff;
}

/* View toggle for 2D grid/chart modes */
.view-toggle {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.view-toggle-btn {
    padding: 0.375rem 0.75rem;
    border: 1px solid var(--border-input);
    border-radius: 4px;
    background: #fff;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.875rem;
}

.view-toggle-btn:hover {
    background: var(--bg-card);
    border-color: var(--border-hover);
}

.view-toggle-btn.active {
    background: var(--brand);
    color: #fff;
    border-color: var(--brand);
}

.probability-grid .given {
    color: var(--text-muted);
    font-style: italic;
    font-weight: normal;
}

/* Probability grid for 2D events */
.probability-grid {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
}

.probability-grid th,
.probability-grid td {
    padding: 0.5rem 0.75rem;
    text-align: center;
    border: 1px solid var(--border);
}

.probability-grid th {
    background: var(--bg-card);
    font-weight: 500;
}

.probability-grid th:first-child {
    text-align: right;
}

.probability-grid td {
    font-weight: 500;
}

.probability-grid td.resolved {
    background: var(--success-bg);
}

.probability-grid .marginal {
    font-weight: normal;
    color: var(--text-muted);
    font-size: 0.875rem;
}

.probability-grid .cell-shares {
    display: block;
    font-weight: normal;
    color: var(--text-muted);
    font-size: 0.75rem;
}

/* Bet type selector */
.bet-type-selector {
    border: none;
    padding: 0;
    margin: 0 0 1rem 0;
}

.bet-type-selector legend {
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.bet-type-btn {
    display: flex;
    flex-direction: column;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.15s;
    margin-bottom: 0.5rem;
}

.bet-type-btn:hover {
    border-color: var(--brand);
    background: var(--bg-highlight);
}

.bet-type-btn:has(input:checked) {
    border-color: var(--brand);
    background: var(--bg-highlight);
}

.bet-type-btn input {
    position: absolute;
    opacity: 0;
}

.bet-type-btn span {
    font-weight: 500;
}

.bet-type-btn small {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.bet-type-info {
    margin-bottom: 1rem;
    padding: 0.5rem 0.75rem;
    background: var(--bg-highlight);
    border-radius: 4px;
    font-size: 0.875rem;
}

.bet-type-info a {
    margin-left: 0.5rem;
}

/* Dimension selector */
.dimension-selector {
    border: none;
    padding: 0;
    margin: 0 0 1rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.dimension-selector legend {
    font-weight: 500;
    margin-bottom: 0.5rem;
}

/* Mobile responsiveness */
@media (max-width: 480px) {
    .trade-tab {
        padding: 0.875rem;
        min-height: 44px;
    }

    .outcome-btn {
        padding: 0.875rem;
        min-height: 44px;
    }

    .quick-amounts {
        flex-wrap: wrap;
    }

    .quick-btn {
        flex: 1 1 calc(50% - 0.25rem);
    }

    .probability-grid {
        font-size: 0.875rem;
    }

    .probability-grid th,
    .probability-grid td {
        padding: 0.375rem 0.5rem;
    }
}

/* Plans page */

.plans-page {
    text-align: center;
    max-width: 420px;
    margin: 0 auto;
    padding: 2rem 0;
}

.plans-subtitle {
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.plan-card {
    text-align: left;
    padding: 2rem;
    border: 2px solid var(--brand);
}

.plan-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.plan-header h2 {
    margin: 0;
}

.plan-badge {
    background: var(--brand);
    color: #fff;
    font-size: 0.75rem;
    font-weight: bold;
    text-transform: uppercase;
    padding: 0.125rem 0.5rem;
    border-radius: 2px;
}

.plan-price {
    margin-bottom: 1.5rem;
}

.plan-amount {
    font-size: 2.5rem;
    font-weight: bold;
}

.plan-period {
    color: var(--text-muted);
}

.plan-features {
    list-style: none;
    padding: 0;
    margin: 0 0 1.5rem;
}

.plan-features li::before {
    content: "\2713  ";
    color: var(--brand);
    font-weight: bold;
}

.plan-features li {
    padding: 0.25rem 0;
}

.plan-cta {
    display: block;
    text-align: center;
}

.plans-disclaimer {
    margin-top: 2rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Footer */

footer {
    margin-top: 3rem;
    padding: 1.5rem 0;
    text-align: center;
    font-size: 0.875rem;
    color: var(--text-muted);
    border-top: 1px solid var(--border);
}

footer a {
    color: var(--text-muted);
    margin: 0 0.75rem;
}

/* Legal pages */

.legal-page {
    max-width: 40rem;
    margin: 0 auto;
}

.legal-page h2 {
    margin-top: 1.5rem;
}

.legal-page h3 {
    margin-top: 1rem;
}

.legal-updated {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Comments */
.comment-list { margin: 0; padding: 0; }
.comment-item { padding: 0.75rem 0; border-bottom: 1px solid var(--border); }
.comment-item:last-child { border-bottom: none; }
.comment-oracle { background: var(--bg-card); border-radius: 4px; padding: 0.75rem; }
.comment-header { display: flex; gap: 0.5rem; align-items: center; }
.comment-time { font-size: 0.75rem; color: var(--text-muted); }
.comment-content { margin: 0.25rem 0 0; white-space: pre-wrap; }
.comment-actions { font-size: 0.75rem; margin-top: 0.25rem; display: flex; gap: 0.75rem; }
.btn-link { background: none; border: none; color: var(--brand); cursor: pointer; padding: 0; font-size: inherit; }
.btn-link:hover { text-decoration: underline; }
.delete-link { color: var(--text-muted); }
.delete-link:hover { color: var(--error); }
.inline-form { display: inline; }
.reply-form { margin-top: 0.5rem; }
.reply-form textarea { width: 100%; }
.comment-form { margin-top: 1rem; }
.comment-form textarea { width: 100%; }
