:root {
    --hc-utility-bg:
        radial-gradient(70rem 40rem at 0% 0%, color-mix(in srgb, var(--hc-primary) 14%, white) 0%, transparent 60%),
        radial-gradient(60rem 35rem at 100% 0%, color-mix(in srgb, var(--hc-accent) 16%, white) 0%, transparent 60%),
        linear-gradient(180deg, #f8fcff 0%, #f4fbf9 100%);
}

.hc-utility-page,
.hc-auth-page {
    min-height: 100vh;
    margin: 0;
    background: var(--hc-utility-bg);
    color: var(--hc-text);
}

.hc-utility-shell,
.hc-auth-shell {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
    padding: 24px 0 40px;
}

.hc-utility-main {
    display: grid;
    gap: 20px;
}

.hc-utility-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 20px;
}

.hc-utility-card {
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 24px;
    box-shadow: 0 24px 60px -36px rgba(15, 23, 42, 0.32);
    padding: 24px;
    backdrop-filter: blur(12px);
}

.hc-utility-card h2,
.hc-auth-card h1 {
    margin: 0 0 12px;
    font-size: 1.35rem;
    line-height: 1.35;
}

.hc-utility-subtext,
.hc-auth-subtext {
    margin: 0 0 16px;
    color: var(--hc-text-muted);
    font-size: 0.95rem;
    line-height: 1.7;
}

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

.hc-utility-table {
    width: 100%;
    border-collapse: collapse;
}

.hc-utility-table th,
.hc-utility-table td {
    border-bottom: 1px solid rgba(148, 163, 184, 0.18);
    padding: 10px 12px;
    text-align: left;
    font-size: 0.93rem;
}

.hc-utility-table th {
    color: var(--hc-text-muted);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.hc-utility-textarea,
.hc-utility-select,
.hc-auth-input {
    box-sizing: border-box;
    width: 100%;
    border: 1px solid rgba(148, 163, 184, 0.35);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.96);
    color: var(--hc-text);
    padding: 14px 16px;
    font: inherit;
    transition: border-color .18s ease, box-shadow .18s ease, background-color .18s ease;
}

.hc-utility-textarea {
    min-height: 260px;
    resize: vertical;
    font-family: "Roboto Mono", ui-monospace, monospace;
    line-height: 1.6;
}

.hc-utility-select {
    min-height: 320px;
}

.hc-utility-textarea:focus,
.hc-utility-select:focus,
.hc-auth-input:focus {
    outline: none;
    border-color: color-mix(in srgb, var(--hc-primary) 55%, white);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--hc-primary) 16%, transparent);
}

.hc-utility-actions,
.hc-auth-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 16px;
}

.hc-utility-alert,
.hc-auth-alert {
    border-radius: 18px;
    padding: 14px 16px;
    border: 1px solid transparent;
    line-height: 1.7;
}

.hc-utility-alert ul {
    margin: 10px 0 0 20px;
}

.hc-utility-alert--error,
.hc-auth-alert--error {
    background: #fff1f2;
    border-color: #fecdd3;
    color: #be123c;
}

.hc-utility-alert--success {
    background: #ecfdf5;
    border-color: #a7f3d0;
    color: #047857;
}

.hc-auth-page {
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    background:
        radial-gradient(60rem 40rem at 10% 10%, rgba(14, 165, 233, 0.10) 0%, transparent 65%),
        radial-gradient(55rem 38rem at 90% 90%, rgba(16, 185, 129, 0.08) 0%, transparent 65%),
        linear-gradient(160deg, #f0f9ff 0%, #f8fafc 50%, #f0fdf4 100%);
}

.hc-auth-shell {
    width: min(380px, calc(100% - 2rem));
    margin: 0 auto;
    padding: 2rem 0;
    display: grid;
    place-items: center;
}

.hc-auth-card {
    position: relative;
    overflow: hidden;
    width: 100%;
    box-sizing: border-box;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 1.5rem;
    box-shadow:
        0 20px 50px -12px rgba(15, 23, 42, 0.10),
        0 4px 16px -2px rgba(15, 23, 42, 0.04);
    padding: 2.25rem 2rem 2rem;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.hc-auth-card__accent {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #0284c7 0%, #0ea5e9 55%, #10b981 100%);
}

.hc-auth-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.hc-auth-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 0.75rem;
}

.hc-auth-brand__logo-wrap {
    width: 56px;
    height: 56px;
    border-radius: 1rem;
    background: linear-gradient(180deg, #ffffff 0%, #f0f9ff 100%);
    border: 1px solid #e0f2fe;
    box-shadow: 0 4px 12px -2px rgba(2, 132, 199, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem;
    box-sizing: border-box;
}

.hc-auth-brand__logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.hc-auth-brand__name {
    margin: 0;
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
}

.hc-auth-title {
    margin: 0;
    font-size: 1.35rem;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.01em;
}

.hc-auth-notice {
    text-align: center;
    padding: 0.55rem 0.85rem;
    border-radius: 0.65rem;
    font-size: 0.825rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.hc-auth-notice--info {
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #065f46;
}

.hc-auth-alert {
    text-align: center;
    font-size: 0.825rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.hc-auth-google-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.hc-auth-google-box .hc-auth-subtext {
    margin: 0;
    font-size: 0.8rem;
    color: #94a3b8;
    text-align: center;
}

.hc-auth-google-button {
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.hc-auth-status {
    margin: 0;
    font-size: 0.825rem;
    line-height: 1.5;
    text-align: center;
    color: #475569;
}

.hc-auth-status:empty {
    display: none;
}

.hc-auth-status[data-state="loading"] {
    color: #0369a1;
    font-weight: 600;
    background: #e0f2fe;
    border: 1px solid #bae6fd;
    padding: 0.45rem 0.85rem;
    border-radius: 0.6rem;
    width: 100%;
    box-sizing: border-box;
}

.hc-auth-status[data-state="error"] {
    color: #be123c;
    font-weight: 600;
    background: #fff1f2;
    border: 1px solid #fecdd3;
    padding: 0.6rem 0.85rem;
    border-radius: 0.65rem;
    width: 100%;
    box-sizing: border-box;
}

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

.hc-auth-label {
    display: grid;
    gap: 8px;
    font-weight: 700;
    color: var(--hc-text-muted);
    font-size: 0.95rem;
}

@media (max-width: 900px) {
    .hc-utility-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .hc-utility-shell {
        width: min(100%, calc(100% - 20px));
        padding: 16px 0 28px;
    }

    .hc-auth-shell {
        width: min(100%, calc(100% - 24px));
        padding: 16px 0;
    }

    .hc-utility-card {
        padding: 18px;
        border-radius: 20px;
    }

    .hc-auth-card {
        padding: 1.75rem 1.35rem 1.5rem;
        border-radius: 1.25rem;
    }
}
