/* SMS Gateway — custom styles */

/* Status badges */
.badge {
    display: inline-block;
    padding: 0.15em 0.55em;
    border-radius: 4px;
    font-size: 0.85em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.status-queued {
    background-color: #fef3cd;
    color: #856404;
}

.status-sending {
    background-color: #cce5ff;
    color: #004085;
}

.status-sent {
    background-color: #d4edda;
    color: #155724;
}

.status-failed {
    background-color: #f8d7da;
    color: #721c24;
}

/* Notice/alert boxes */
.notice {
    padding: 0.75em 1em;
    border-radius: 4px;
    margin-bottom: 1em;
    font-size: 0.95em;
}

.notice.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.notice.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.notice.info {
    background-color: #cce5ff;
    color: #004085;
    border: 1px solid #b8daff;
}

/* Key display box */
.new-key-display {
    background-color: #fff3cd;
    border: 1px solid #ffc107;
    padding: 1em;
    border-radius: 4px;
    margin-bottom: 1em;
    word-break: break-all;
    font-family: monospace;
}

/* Navigation active state */
nav a[aria-current="page"] {
    font-weight: bold;
}

/* Modem status grid */
.status-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1em;
    margin-bottom: 1em;
}

.status-card {
    padding: 1em;
    border-radius: 8px;
    background: var(--pico-card-background-color);
    border: 1px solid var(--pico-muted-border-color);
}

.status-card .label {
    font-size: 0.8em;
    color: var(--pico-muted-color);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.3em;
}

.status-card .value {
    font-size: 1.3em;
    font-weight: 600;
}

/* Table tweaks */
table {
    font-size: 0.9em;
    display: block;
    overflow-x: auto;
    white-space: nowrap;
}

/* Send form layout */
.send-form {
    display: grid;
    gap: 1em;
}

.send-form textarea {
    min-height: 7rem;
    resize: vertical;
}

/* Revoked key styling */
.revoked {
    text-decoration: line-through;
    opacity: 0.6;
}

/* Section spacing */
section {
    margin-bottom: 2em;
}

/* Compact inline form for key creation */
.inline-form {
    display: flex;
    gap: 0.5em;
    align-items: end;
}

.inline-form input {
    margin-bottom: 0;
}

.inline-form button {
    margin-bottom: 0;
    white-space: nowrap;
}

/* HTMX loading indicator */
.htmx-indicator {
    opacity: 0;
    transition: opacity 200ms ease-in;
}

.htmx-request .htmx-indicator,
.htmx-request.htmx-indicator {
    opacity: 1;
}

code {
    word-break: break-all;
}
