/* ===========================
   GLOBAL
=========================== */

body {
    font-family: Arial;
    background:
        radial-gradient(circle at top left, rgba(37, 99, 235, 0.14), transparent 34%),
        #0f172a;
    color: white;
    padding: 0;
    margin: 0;
}

a {
    color: #93c5fd;
}


/* ===========================
   TYPOGRAPHY / COLORS
=========================== */

.success {
    color: #22c55e;
    font-weight: bold;
}

.error {
    color: #ef4444;
    font-weight: bold;
}

.warning {
    color: #f59e0b;
    font-weight: bold;
}

.muted {
    color: #9ca3af;
}

h1 {
    margin-top: 0;
    margin-bottom: 24px;
}

h2 {
    margin-bottom: 16px;
}


/* ===========================
   LAYOUT / LEGACY CARDS
=========================== */

.page {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
}

.app-page,
.app-container {
    width: 100%;
    max-width: none;
}

.form-card {
    background: #111827;
    border: 1px solid #1f2937;
    border-radius: 12px;
    padding: 24px;
    width: 520px;
}


/* ===========================
   MESSAGES
=========================== */

.message-success,
.message-error,
.message-warning {
    font-weight: bold;
    margin: 16px 0;
}

.message-success {
    color: #22c55e;
}

.message-error {
    color: #ef4444;
}

.message-warning {
    color: #f59e0b;
}


/* ===========================
   FORMS
=========================== */

form {
    margin-top: 16px;
}

.form-row {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

input,
textarea,
select {
    width: 100%;
    box-sizing: border-box;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #374151;
    background: #1f2937;
    color: white;
    font-size: 15px;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: #3b82f6;
}

input[type="checkbox"] {
    width: auto;
    margin-right: 10px;
}

label {
    display: flex;
    align-items: center;
    gap: 10px;
}


/* ===========================
   BUTTONS
=========================== */

button {
    background: #2563eb;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px 18px;
    cursor: pointer;
    font-size: 15px;
}

button:hover {
    background: #1d4ed8;
}

button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.form-row button {
    width: fit-content;
    min-width: 180px;
    align-self: center;
}


/* ===========================
   BASE TABLES
=========================== */

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

th,
td {
    padding: 12px;
    border-bottom: 1px solid #374151;
    text-align: left;
}

th {
    background: #111827;
}


/* ===========================
   LEGACY HEADER / SUMMARY
=========================== */

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

.top-links {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.top-links a {
    color: #93c5fd;
    text-decoration: none;
    font-weight: bold;
}

.top-links a:hover {
    text-decoration: underline;
}

.summary {
    display: flex;
    gap: 15px;
    margin: 20px 0 35px 0;
    flex-wrap: wrap;
}

.card {
    background: #111827;
    padding: 18px;
    border-radius: 10px;
    min-width: 180px;
    border: 1px solid #1f2937;
}

.card .label {
    color: #9ca3af;
    font-size: 14px;
}

.card .value {
    font-size: 24px;
    font-weight: bold;
    margin-top: 8px;
}


/* ===========================
   TOASTS
=========================== */

.toast {
    position: fixed;
    top: 24px;
    right: 24px;
    padding: 14px 18px;
    border-radius: 10px;
    font-weight: bold;
    z-index: 9999;
    box-shadow: 0 10px 30px rgba(0,0,0,0.35);
}

.toast-success {
    background: #14532d;
    color: #bbf7d0;
    border: 1px solid #22c55e;
}

.toast-error {
    background: #7f1d1d;
    color: #fecaca;
    border: 1px solid #ef4444;
}

.toast-warning {
    background: #78350f;
    color: #fde68a;
    border: 1px solid #f59e0b;
}


/* ===========================
   STATUS BADGES
=========================== */

.status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 82px;
    height: 25px;
    padding: 0 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.02em;
    border: 1px solid transparent;
}

.status-ok {
    color: #86efac;
    background: rgba(34, 197, 94, 0.12);
    border-color: rgba(34, 197, 94, 0.42);
}

.status-warning {
    color: #fbbf24;
    background: rgba(245, 158, 11, 0.12);
    border-color: rgba(245, 158, 11, 0.46);
}

.status-critical {
    color: #fca5a5;
    background: rgba(239, 68, 68, 0.13);
    border-color: rgba(239, 68, 68, 0.48);
}

.status-error,
.status-unknown {
    color: #cbd5e1;
    background: rgba(148, 163, 184, 0.10);
    border-color: rgba(148, 163, 184, 0.28);
}


/* ===========================
   SIDEBAR APP LAYOUT
=========================== */

.app-shell {
    min-height: 100vh;
    display: flex;
}

.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: 230px;
    min-height: 100vh;
    box-sizing: border-box;
    padding: 20px 14px;
    background: linear-gradient(180deg, #0b1220, #111827);
    border-right: 1px solid #243044;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    z-index: 20;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #f8fafc;
    text-decoration: none;
    margin-bottom: 26px;
}

.sidebar-brand:hover {
    text-decoration: none;
}

.sidebar-brand strong {
    display: block;
    font-size: 16px;
    line-height: 1.2;
}

.sidebar-brand small {
    display: block;
    margin-top: 3px;
    color: #94a3b8;
    font-size: 12px;
}

.brand-logo {
    width: 38px;
    height: 38px;
    object-fit: contain;
    flex-shrink: 0;
}

.brand-mark {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    font-size: 12px;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 40px;
    padding: 0 11px;
    border-radius: 10px;
    color: #cbd5e1;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    border: 1px solid transparent;
}

.sidebar-link:hover {
    background: rgba(30, 41, 59, 0.65);
    border-color: #243044;
    color: #f8fafc;
    text-decoration: none;
}

.sidebar-link.active {
    background: rgba(37, 99, 235, 0.16);
    border-color: rgba(59, 130, 246, 0.38);
    color: #bfdbfe;
}

.sidebar-icon {
    width: 22px;
    display: inline-flex;
    justify-content: center;
    color: #93c5fd;
}

.sidebar-account {
    border: 1px solid #243044;
    background: rgba(15, 23, 42, 0.72);
    border-radius: 12px;
    padding: 12px;
}

.account-label {
    color: #94a3b8;
    font-size: 11px;
    margin-bottom: 5px;
}

.account-email {
    color: #f8fafc;
    font-size: 13px;
    font-weight: 700;
    word-break: break-word;
    line-height: 1.35;
    margin-bottom: 8px;
}

.plan-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 10px;
    height: 24px;
    padding: 0 10px;
    border-radius: 999px;
    background: rgba(37, 99, 235, 0.14);
    border: 1px solid rgba(59, 130, 246, 0.34);
    color: #bfdbfe;
    font-size: 11px;
    font-weight: 800;
}

.sidebar-account .sidebar-plan-usage {
    margin-top: 6px;
    margin-bottom: 6px;
    font-size: 12px;
    line-height: 1.2;
    color: #94a3b8;
    font-weight: 600;
}

.usage-track {
    height: 8px;
    background: #1e293b;
    border-radius: 999px;
    overflow: hidden;
}

.usage-fill {
    height: 100%;
    width: var(--usage-percent);
    background: #2563eb;
    border-radius: 999px;
}

.sidebar-account .sidebar-track {
    height: 5px;
    margin-top: 4px;
}

.sidebar-upgrade {
    display: block;
    margin-top: 12px;
    text-align: center;
    font-size: 13px;
    font-weight: 700;
    color: #93c5fd;
    text-decoration: none;
}

.sidebar-upgrade:hover {
    color: #bfdbfe;
    text-decoration: underline;
}

.app-main {
    width: calc(100% - 230px);
    max-width: 1500px;
    margin-left: 230px;
    padding: 24px 30px 32px 30px;
    box-sizing: border-box;
}


/* ===========================
   DASHBOARD HEADER / NAV
=========================== */

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

.dashboard-header h1 {
    font-size: 27px;
    margin: 0 0 4px 0;
}

.dashboard-header .muted {
    margin: 0;
}

.user-line {
    margin-top: 8px;
    color: #e5e7eb;
}

.dashboard-nav {
    display: flex;
    align-items: center;
    gap: 14px;
}

.dashboard-nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 11px;
    border-radius: 9px;
    border: 1px solid #243044;
    background: rgba(15, 23, 42, 0.72);
    color: #e5e7eb;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.dashboard-nav a:hover {
    background: #1e293b;
    border-color: #3b82f6;
    color: #ffffff;
    text-decoration: none;
}

.dashboard-nav .logout-link {
    color: #e5e7eb;
}

.dashboard-nav .logout-link:hover,
.logout-link:hover {
    background: rgba(239, 68, 68, 0.08);
    border-color: rgba(239, 68, 68, 0.45);
    color: #fca5a5 !important;
}


/* ===========================
   DASHBOARD STATS
=========================== */

.stats {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 12px;
    margin: 16px 0 20px 0;
}

.stats .card {
    min-width: 0;
    max-width: none;
    min-height: 74px;
    padding: 15px;
    background: linear-gradient(180deg, #111827, #0f172a);
    border-radius: 12px;
    border: 1px solid #1f2937;
    transition: 0.2s;
}

.stats .card:hover {
    border-color: #3b82f6;
    transform: translateY(-2px);
}

.stats .card .label {
    color: #9ca3af;
    font-size: 14px;
}

.stats .card .value {
    font-size: 25px;
    font-weight: bold;
    margin-top: 6px;
}


/* ===========================
   DASHBOARD MANAGEMENT PANEL
=========================== */

.dashboard-panel {
    background: linear-gradient(180deg, #111827, #0b1220);
    border: 1px solid #243044;
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 20px;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.18);
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 18px;
    margin-bottom: 12px;
}

.panel-header h2 {
    margin: 0 0 6px 0;
    font-size: 22px;
}

.panel-header p {
    margin: 0;
}

.dashboard-tools {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 12px;
}

.tool-card {
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid #243044;
    border-radius: 12px;
    padding: 13px;
}

.tool-card:hover {
    border-color: #334155;
}

.tool-card-wide {
    margin-top: 0;
}

.tool-card-header {
    margin-bottom: 10px;
}

.tool-card h3 {
    margin: 0 0 4px 0;
    font-size: 17px;
}

.tool-card p {
    margin: 0;
    font-size: 13px;
}

.tool-form {
    display: flex;
    gap: 10px;
    align-items: center;
    margin: 0;
}

.tool-form input {
    flex: 1;
    min-width: 0;
    font-size: 14px;
}

.clear-button,
.export-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 42px;
    padding: 0 14px;
    border-radius: 8px;
    border: 1px solid #374151;
    background: #0f172a;
    color: #93c5fd;
    font-size: 14px;
    font-weight: bold;
    text-decoration: none;
    white-space: nowrap;
}

.clear-button:hover,
.export-button:hover {
    background: #1f2937;
    text-decoration: none;
}

.bulk-form {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) 230px;
    gap: 14px;
    align-items: start;
    margin: 0;
}

.bulk-form textarea {
    width: 100%;
    min-height: 88px;
    resize: vertical;
    font-family: inherit;
    font-size: 14px;
}

.bulk-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.bulk-actions button {
    width: fit-content;
    white-space: nowrap;
}

.bulk-actions .muted {
    font-size: 13px;
    line-height: 1.5;
}


/* ===========================
   DASHBOARD ACTIONS
=========================== */

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

.action-link,
.action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 30px;
    padding: 0 10px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: bold;
    text-decoration: none;
    border: 1px solid #374151;
    background: #111827;
    cursor: pointer;
}

.action-link {
    color: #93c5fd;
}

.check-btn {
    color: #22c55e;
}

.delete-btn {
    color: #ef4444;
}

.action-link:hover,
.action-btn:hover {
    background: #1f2937;
    text-decoration: none;
}

.action-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.inline-form {
    margin: 0;
}

.actions-column {
    width: 230px;
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 20px;
    margin-bottom: 4px;
}


/* ===========================
   DOMAINS TABLE
=========================== */

.table-card {
    background: linear-gradient(180deg, #111827, #0b1220);
    border: 1px solid #243044;
    border-radius: 16px;
    margin-top: 20px;
    overflow: hidden;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.16);
}

.table-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    padding: 18px 20px 14px 20px;
    border-bottom: 1px solid #243044;
}

.table-card-header h2 {
    margin: 0 0 6px 0;
    font-size: 19px;
}

.table-card-header p {
    margin: 0;
}

.table-scroll {
    width: 100%;
    overflow-x: auto;
}

.domains-table {
    width: 100%;
    min-width: 1040px;
    border-collapse: separate;
    border-spacing: 0;
    margin-top: 0;
}

.domains-table th,
.domains-table td {
    padding: 13px 16px;
    border-bottom: 1px solid #243044;
    vertical-align: middle;
}

.domains-table th {
    background: rgba(15, 23, 42, 0.88);
    color: #cbd5e1;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.01em;
}

.domains-table th a {
    color: #cbd5e1;
    text-decoration: none;
}

.domains-table th a:hover {
    color: #93c5fd;
}

.domains-table td {
    color: #e5e7eb;
    font-size: 15px;
}

.domains-table tr:hover td {
    background: rgba(30, 41, 59, 0.45);
}

.domains-table tr:last-child td {
    border-bottom: none;
}

.status-cell,
.days-cell {
    white-space: nowrap;
}

.days-cell {
    font-weight: 700;
    color: #f8fafc;
}

.domains-table .actions {
    justify-content: flex-start;
    gap: 8px;
}

.domains-table .action-link,
.domains-table .action-btn {
    height: 31px;
    padding: 0 11px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.85);
    border-color: #334155;
}

.domains-table .action-link:hover,
.domains-table .action-btn:hover {
    background: #1e293b;
    border-color: #475569;
}

.domains-table .check-btn {
    color: #86efac;
}

.domains-table .delete-btn {
    color: #fca5a5;
}


/* ===========================
   HISTORY PAGE
=========================== */

.history-domain {
    color: #93c5fd;
    font-weight: 800;
}

.table-card .domains-table td:last-child {
    max-width: 520px;
    word-break: break-word;
    color: #cbd5e1;
}

.history-stats {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    max-width: 900px;
}

.history-stats .card .value {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 32px;
}

.history-table {
    min-width: 900px;
}

.history-error {
    max-width: 520px;
    white-space: normal;
    word-break: break-word;
    color: #cbd5e1;
}

.issuer-value {
    font-size: 1.8rem;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}


/* ===========================
   SETTINGS PAGE
=========================== */

.settings-card {
    width: 100%;
    max-width: 1400px;
    background: linear-gradient(180deg, #111827, #0b1220);
    border: 1px solid #243044;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.16);
}

.settings-card-header {
    padding: 22px 24px 18px 24px;
    border-bottom: 1px solid #243044;
}

.settings-card-header h2 {
    margin: 0 0 6px 0;
    font-size: 22px;
}

.settings-card-header p {
    margin: 0;
}

.settings-form {
    margin: 0;
}

.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    padding: 18px 32px 18px 24px;
    border-bottom: 1px solid #243044;
    user-select: none;
    transition: background 0.2s ease;
}

.setting-item:hover {
    background: #16233d;
}

.setting-item:last-of-type {
    border-bottom: none;
}

.setting-item strong {
    display: block;
    color: #f8fafc;
    font-size: 15px;
    margin-bottom: 5px;
}

.setting-item p {
    margin: 0;
    color: #94a3b8;
    font-size: 13px;
    line-height: 1.45;
}

.switch {
    position: relative;
    display: inline-flex;
    width: 48px;
    height: 26px;
    flex-shrink: 0;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: #334155;
    border: 1px solid #475569;
    border-radius: 999px;
    transition: 0.18s ease;
}

.slider:before {
    content: "";
    position: absolute;
    width: 20px;
    height: 20px;
    left: 3px;
    top: 2px;
    background: #cbd5e1;
    border-radius: 50%;
    transition: 0.18s ease;
}

.switch input:checked + .slider {
    background: #2563eb;
    border-color: #3b82f6;
}

.switch input:checked + .slider:before {
    transform: translateX(21px);
    background: white;
}

.settings-actions {
    display: flex;
    justify-content: flex-end;
    padding: 20px 24px 24px 24px;
    border-top: 1px solid #243044;
}

.settings-actions button {
    min-width: 170px;
}


/* ===========================
   LANDING PAGE
=========================== */

.landing-page {
    min-height: 100vh;
    padding: 28px;
    background:
        radial-gradient(circle at top left, rgba(37, 99, 235, 0.18), transparent 34%),
        #0f172a;
}

.landing-nav {
    max-width: 1180px;
    margin: 0 auto 80px auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.landing-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #f8fafc;
    font-weight: 800;
    font-size: 18px;
    text-decoration: none;
}

.landing-brand:hover {
    text-decoration: none;
}

.landing-links {
    display: flex;
    align-items: center;
    gap: 14px;
}

.landing-links a {
    text-decoration: none;
    font-weight: 700;
}

.landing-button-small {
    padding: 10px 14px;
    border-radius: 10px;
    background: #2563eb;
    color: white;
}

.landing-hero {
    max-width: 1180px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 56px;
    align-items: center;
}

.landing-badge {
    display: inline-flex;
    padding: 8px 12px;
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 999px;
    background: rgba(37, 99, 235, 0.12);
    color: #bfdbfe;
    font-size: 13px;
    font-weight: 800;
}

.landing-hero h1 {
    margin: 22px 0 20px 0;
    max-width: 700px;
    font-size: 58px;
    line-height: 1.02;
    letter-spacing: -0.04em;
}

.landing-subtitle {
    max-width: 620px;
    color: #cbd5e1;
    font-size: 19px;
    line-height: 1.6;
}

.landing-actions {
    display: flex;
    gap: 14px;
    margin-top: 30px;
}

.landing-primary,
.landing-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 18px;
    border-radius: 11px;
    font-weight: 800;
    text-decoration: none;
}

.landing-primary {
    background: #2563eb;
    color: white;
}

.landing-primary:hover {
    background: #1d4ed8;
    text-decoration: none;
}

.landing-secondary {
    border: 1px solid #334155;
    background: rgba(15, 23, 42, 0.72);
    color: #e5e7eb;
}

.landing-secondary:hover {
    background: #16233d;
    text-decoration: none;
}

.landing-preview {
    display: flex;
    justify-content: center;
}

.preview-card {
    width: 100%;
    max-width: 430px;
    background: linear-gradient(180deg, #111827, #0b1220);
    border: 1px solid #243044;
    border-radius: 20px;
    padding: 22px;
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

.preview-header,
.preview-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.preview-header {
    margin-bottom: 22px;
    font-weight: 800;
}

.preview-row {
    padding: 14px 0;
    border-top: 1px solid #243044;
    color: #94a3b8;
}

.preview-row strong {
    color: #f8fafc;
}

.landing-section {
    max-width: 1180px;
    margin: 90px auto 0 auto;
}

.landing-section h2,
.landing-cta h2 {
    margin-bottom: 22px;
    font-size: 34px;
    letter-spacing: -0.03em;
}

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

.landing-card {
    background: linear-gradient(180deg, #111827, #0b1220);
    border: 1px solid #243044;
    border-radius: 16px;
    padding: 22px;
}

.landing-card h3 {
    margin: 0 0 10px 0;
}

.landing-card p {
    margin: 0;
    color: #94a3b8;
    line-height: 1.5;
}

.landing-cta {
    max-width: 1180px;
    margin: 90px auto 40px auto;
    padding: 36px;
    border: 1px solid #243044;
    border-radius: 22px;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.18), rgba(15, 23, 42, 0.9));
    text-align: center;
}

.landing-cta p {
    color: #cbd5e1;
    margin-bottom: 24px;
}


/* ===========================
   PRICING
=========================== */

.pricing-coming {
    max-width: 860px;
    margin: 72px auto 0 auto;
    text-align: center;
}

.pricing-coming .landing-badge {
    margin-bottom: 24px;
}

.pricing-coming h1 {
    margin: 0 0 18px 0;
    font-size: 38px;
    letter-spacing: -0.03em;
}

.pricing-coming .landing-subtitle {
    max-width: 720px;
    margin: 0 auto 42px auto;
}

.pricing-card {
    max-width: 760px;
    margin: 0 auto;
    padding: 38px;
    background: linear-gradient(180deg, #111827, #0b1220);
    border: 1px solid #243044;
    border-radius: 18px;
    box-shadow: 0 20px 50px rgba(0,0,0,.25);
}

.pricing-card h2 {
    margin-top: 0;
}

.pricing-card .pricing-list,
.plan-card .pricing-list {
    list-style: none;
    padding: 0;
    margin: 30px auto;
    margin-bottom: 28px;
    max-width: 340px;
}

.pricing-card .pricing-list li,
.plan-card .pricing-list li {
    text-align: left;
    padding: 10px 0;
    color: #cbd5e1;
}

.pricing-note {
    margin: 24px auto 0 auto;
    max-width: 560px;
    color: #94a3b8;
    font-size: 14px;
    line-height: 1.6;
}
.plan-card .plan-button {
    min-height: 42px;
}

.current-plan-badge {
    align-self: center;
    margin-top: auto;
    min-width: 180px;
    min-height: 42px;
    padding: 0 18px;
    border-radius: 11px;
    display: inline-flex;
    align-items: center;
    justify-content: center;

    color: #86efac;
    background: rgba(34, 197, 94, 0.10);
    border: 1px solid rgba(34, 197, 94, 0.35);

    font-weight: 800;
    font-size: 14px;
}

/* ===========================
   UPGRADE PAGE
=========================== */

.upgrade-page {
    max-width: 980px;
    margin: 70px auto 0 auto;
    text-align: center;
}

.upgrade-page h1 {
    margin: 22px 0 16px 0;
    font-size: 40px;
    letter-spacing: -0.03em;
}

.upgrade-page .landing-subtitle {
    max-width: 720px;
    margin: 0 auto;
}

.plans-grid {
    margin-top: 42px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
    text-align: left;
}

.plan-card {
    position: relative;
    display: flex;
    flex-direction: column;

    padding: 30px;

    background: linear-gradient(180deg, #111827, #0b1220);
    border: 1px solid #243044;
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0,0,0,.22);
}

.plan-card-pro {
    border-color: rgba(59, 130, 246, 0.55);
    box-shadow: 0 22px 60px rgba(37, 99, 235, 0.12);
}

.plan-ribbon {
    position: absolute;
    top: 18px;
    right: 18px;
    padding: 7px 11px;
    border-radius: 999px;
    background: rgba(37, 99, 235, 0.14);
    border: 1px solid rgba(59, 130, 246, 0.34);
    color: #bfdbfe;
    font-size: 12px;
    font-weight: 800;
}

.plan-header h2 {
    margin: 0 0 8px 0;
    font-size: 26px;
}

.plan-header p {
    margin: 0;
    color: #94a3b8;
    line-height: 1.5;
}

.plan-price {
    margin-top: 28px;
    font-size: 34px;
    font-weight: 900;
    color: #f8fafc;
}

.plan-period {
    margin-top: 4px;
    color: #94a3b8;
    font-size: 14px;
}

.plan-button {
    width: fit-content;
    min-width: 180px;
    margin-top: auto;
    align-self: center;
}

.upgrade-note {
    margin-top: 28px;
}


/* ===========================
   AUTH PAGES
=========================== */

.auth-page {
    min-height: 100vh;
    padding: 28px;
    display: flex;
    flex-direction: column;
    align-items: center;
    background:
        radial-gradient(circle at top left, rgba(37, 99, 235, 0.18), transparent 34%),
        #0f172a;
}

.auth-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 24px 0 70px 0;
    color: #f8fafc;
    font-weight: 800;
    font-size: 18px;
    text-decoration: none;
}

.auth-brand:hover {
    text-decoration: none;
}

.auth-card {
    width: 100%;
    max-width: 460px;
    padding: 34px;
    background: linear-gradient(180deg, #111827, #0b1220);
    border: 1px solid #243044;
    border-radius: 18px;
    box-shadow: 0 20px 50px rgba(0,0,0,.25);
}

.auth-card h1 {
    margin: 0 0 8px 0;
    font-size: 32px;
}

.auth-card .muted {
    margin-bottom: 24px;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-top: 18px;
}

.auth-form button {
    width: 100%;
    margin-top: 4px;
}

.auth-links {
    margin-top: 22px;
    text-align: center;
    color: #94a3b8;
}

.auth-links p {
    margin: 8px 0;
}

.auth-links a {
    font-weight: 700;
    text-decoration: none;
}

.auth-links a:hover {
    text-decoration: underline;
}


/* ===========================
   RESPONSIVE
=========================== */

@media (max-width: 1150px) {
    .stats {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .dashboard-tools,
    .bulk-form {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 900px) {
    body {
        padding: 18px;
    }

    .stats .card {
        min-width: 140px;
    }

    .dashboard-tools,
    .landing-grid {
        grid-template-columns: 1fr;
    }

    .bulk-form {
        grid-template-columns: 1fr;
    }

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

    .export-button {
        width: fit-content;
    }

    .table-card-header {
        padding: 18px;
    }

    .landing-hero {
        grid-template-columns: 1fr;
    }

    .landing-hero h1 {
        font-size: 42px;
    }

    .landing-nav {
        margin-bottom: 48px;
    }

    .pricing-coming h1 {
        font-size: 32px;
    }

    .plans-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 820px) {
    .app-shell {
        display: block;
    }

    .sidebar {
        position: static;
        width: 100%;
        min-height: auto;
        padding: 16px;
        border-right: none;
        border-bottom: 1px solid #243044;
    }

    .sidebar-top {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 18px;
    }

    .sidebar-brand {
        margin-bottom: 0;
    }

    .sidebar-nav {
        flex-direction: row;
        gap: 8px;
    }

    .sidebar-account {
        display: none;
    }

    .app-main {
        width: 100%;
        margin-left: 0;
        padding: 18px;
    }

    .dashboard-header {
        flex-direction: column;
        align-items: flex-start;
    }

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

    .history-stats {
        grid-template-columns: 1fr;
        max-width: none;
    }
}

@media (max-width: 700px) {
    .setting-item {
        align-items: flex-start;
    }

    .settings-card {
        max-width: none;
    }
}

@media (max-width: 560px) {
    body {
        padding: 18px;
    }

    .tool-form {
        flex-direction: column;
        align-items: stretch;
    }

    .clear-button,
    .tool-form button {
        width: 100%;
    }

    .sidebar-top {
        flex-direction: column;
        align-items: stretch;
    }

    .sidebar-nav {
        width: 100%;
    }

    .sidebar-link {
        flex: 1;
        justify-content: center;
    }

    .stats {
        grid-template-columns: 1fr;
    }
}


/* ===========================
   FOOTER
=========================== */

.landing-footer {
    max-width: 1180px;
    margin: 70px auto 0 auto;
    padding: 26px 0 8px 0;
    border-top: 1px solid #243044;

    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;

    color: #94a3b8;
}

.landing-footer strong {
    color: #f8fafc;
}

.landing-footer p {
    margin: 8px 0 0 0;
    max-width: 420px;
    font-size: 14px;
    line-height: 1.5;
}

.footer-links {
    display: flex;
    gap: 16px;
}

.footer-links a {
    color: #93c5fd;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
}

.footer-links a:hover {
    text-decoration: underline;
}

.footer-copy {
    font-size: 14px;
    white-space: nowrap;
}

@media (max-width: 800px) {
    .landing-footer {
        flex-direction: column;
    }

    .footer-links {
        flex-wrap: wrap;
    }
}

/* ===========================
   LEGAL PAGES
=========================== */

.legal-page {
    max-width: 1180px;
    margin: 70px auto 0 auto;
    text-align: center;
}

.legal-page h1 {
    margin: 22px 0 16px;
    font-size: 42px;
    letter-spacing: -0.03em;
}

.legal-card {
    max-width: 760px;
    margin: 42px auto 0 auto;
    padding: 40px;

    background: linear-gradient(180deg, #111827, #0b1220);
    border: 1px solid #243044;
    border-radius: 20px;

    text-align: left;
    box-shadow: 0 20px 50px rgba(0,0,0,.22);
}

.legal-card h2 {
    margin: 32px 0 12px;
    color: #f8fafc;
    font-size: 24px;
}

.legal-card h2:first-child {
    margin-top: 0;
}

.legal-card p {
    margin: 0;
    color: #cbd5e1;
    line-height: 1.8;
    font-size: 16px;
}

@media (max-width: 900px) {

    .legal-page {
        margin-top: 40px;
        padding: 0 20px;
    }

    .legal-page h1 {
        font-size: 34px;
    }

    .legal-card {
        padding: 28px;
    }
}

.legal-page .landing-subtitle {
    margin-left: auto;
    margin-right: auto;
}

.error-card {
    text-align: center;
}

.error-card p {
    max-width: 520px;
    margin: 0 auto;
}

.error-actions {
    margin-top: 32px;
}

.verification-email {
    margin: 18px 0;
    font-size: 18px;
    color: #f8fafc;
    word-break: break-word;
}

