/* Basic reset */
*,
*::before,
*::after {
    box-sizing: border-box;
}

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

body {
    min-height: 100vh;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background-color: #f5f5f7;
    color: #111827;
}

a {
    color: inherit;
}

.page-root {
    display: flex;
    align-items: stretch;
    justify-content: center;
    padding: 24px 16px;
}

.page-container {
    width: 100%;
    max-width: 760px;
}

.page-header {
    margin-bottom: 16px;
}

.page-title {
    margin: 0 0 4px 0;
    font-size: 20px;
    font-weight: 600;
}

.page-subtitle {
    margin: 0;
    font-size: 13px;
    color: #6b7280;
}

.card {
    background-color: #ffffff;
    border: 1px solid #d0d4dc;
    border-radius: 8px;
    padding: 16px 18px;
    margin-bottom: 16px;
}

.card--primary {
    border-color: #2563eb;
}

.card--secondary {
    border-style: dashed;
}

.card-title {
    margin: 0 0 8px 0;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.01em;
    text-transform: uppercase;
    color: #4b5563;
}

.ip-display {
    display: flex;
    align-items: baseline;
    gap: 8px;
    flex-wrap: wrap;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

.ip-display__label {
    font-size: 13px;
    color: #6b7280;
    min-width: 88px;
}

.ip-display__value {
    font-size: 16px;
    font-weight: 500;
    word-break: break-all;
    overflow-wrap: anywhere;
}

.ip-display__value--placeholder {
    color: #9ca3af;
}

.ip-display__value--unsupported {
    color: #6b7280;
    font-size: 13px;
    font-weight: 400;
}

.ip-display__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 6px;
    border-radius: 999px;
    background-color: #e5edff;
    color: #1d4ed8;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.dual-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
}

.dual-note {
    margin-top: 6px;
    font-size: 12px;
    color: #6b7280;
}

#dual-loading {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

#dual-loading::before {
    content: "";
    width: 14px;
    height: 14px;
    border-radius: 999px;
    border: 2px solid #cbd5f5;
    border-top-color: #2563eb;
    animation: dual-loading-spin 0.8s linear infinite;
}

@keyframes dual-loading-spin {
    to {
        transform: rotate(360deg);
    }
}

.data-list {
    margin: 0;
    padding: 0;
    list-style: none;
    font-size: 13px;
}

.data-list__item {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 3px 0;
}

.data-list__label {
    color: #6b7280;
    white-space: nowrap;
}

.data-list__value {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    word-break: break-all;
    text-align: right;
}

.data-list__item--note .data-list__value--note {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: #6b7280;
    text-align: left;
}

.header-list {
    margin: 0;
    padding-left: 18px;
    font-size: 13px;
}

.header-list__item {
    margin: 2px 0;
}

.header-list__name {
    font-weight: 600;
}

.header-list__value {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    word-break: break-all;
    overflow-wrap: anywhere;
}

.section-spacing {
    margin-top: 8px;
}

.note-text {
    font-size: 12px;
    color: #6b7280;
}

/* Force address-type note onto its own line inside .ip-display (avoids sitting beside short IPv4) */
.ip-display .note-text {
    flex-basis: 100%;
    width: 100%;
}

noscript .card {
    margin-top: 0;
}

.ip-copy-button {
    border: none;
    background: transparent;
    padding: 0;
    margin-left: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    line-height: 0;
    cursor: pointer;
    color: #6b7280;
}

.ip-copy-button:hover,
.ip-copy-button:focus-visible {
    color: #111827;
}

.ip-copy-button:focus-visible {
    outline: 2px solid #2563eb;
    outline-offset: 2px;
}

.ip-copy-button__icon {
    display: block;
    fill: currentColor;
}

.ip-copy-button--success {
    color: #16a34a;
    background-color: #dcfce7;
    border-radius: 999px;
}

.ip-copy-feedback {
    color: #16a34a;
    font-size: 12px;
    font-weight: 500;
    margin-left: 6px;
}

