/* ============================================================================
   HEXATLAS MOBILE COMPANION v2
   Real canvas top, draggable bottom sheet, detail overlay
   ============================================================================ */

/* --- Reset for mobile mode --- */
body.mobile-companion {
    overflow: hidden;
    position: fixed;
    inset: 0;
    background: #0f1419;
}

body.mobile-companion .app {
    display: flex !important;
    flex-direction: column;
    height: 100vh;
    height: 100dvh;
    visibility: visible !important;
    overflow: hidden;
}

/* Hide desktop chrome */
body.mobile-companion .topbar,
body.mobile-companion .sidebar-left,
body.mobile-companion .sidebar-right,
body.mobile-companion .minimap-header {
    display: none !important;
}

/* =========================================================================
   MOBILE HEADER
   ========================================================================= */
.mc-mobile-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 200;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 12px;
    background: rgba(15, 20, 25, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.mc-hdr-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.mc-hdr-right {
    display: flex;
    align-items: center;
    gap: 4px;
}

.mc-logo {
    width: 28px;
    height: 28px;
}

.mc-title {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.02em;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.mc-hdr-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: none;
    color: #a0aec0;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.mc-hdr-btn:active {
    background: rgba(255,255,255,0.08);
}

/* =========================================================================
   CANVAS AREA — fills space between header and bottom sheet
   ========================================================================= */
body.mobile-companion .canvas-container,
.mc-canvas-area {
    position: fixed !important;
    top: 48px;
    left: 0;
    right: 0;
    bottom: 40%;  /* matches initial sheet height */
    z-index: 1;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden;
}

body.mobile-companion .canvas-container canvas {
    width: 100% !important;
    height: 100% !important;
}

/* =========================================================================
   MINIMAP — small corner overlay
   ========================================================================= */
body.mobile-companion .minimap-container {
    position: fixed !important;
    bottom: calc(40% + 8px); /* sits above the sheet */
    right: 8px;
    width: 80px;
    height: 80px;
    z-index: 100;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(15, 20, 25, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 2px 12px rgba(0,0,0,0.4);
    transition: all 0.3s ease;
    display: block !important;
}

body.mobile-companion .minimap-container.mc-minimap-expanded {
    width: 240px;
    height: 240px;
    bottom: calc(40% + 8px);
    right: 8px;
}

body.mobile-companion .minimap-wrapper {
    width: 100%;
    height: 100%;
}

body.mobile-companion .minimap-canvas {
    width: 100% !important;
    height: 100% !important;
}

body.mobile-companion .minimap-viewport {
    display: none; /* hide viewport rect on mobile for now */
}

body.mobile-companion .minimap-stats {
    display: none;
}

/* =========================================================================
   BOTTOM SHEET
   ========================================================================= */
.mc-bottom-sheet {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40%;
    z-index: 150;
    background: #161b22;
    border-top-left-radius: 16px;
    border-top-right-radius: 16px;
    display: flex;
    flex-direction: column;
    transition: height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 -4px 24px rgba(0,0,0,0.5);
}

/* --- Drag Handle --- */
.mc-drag-handle {
    display: flex;
    justify-content: center;
    padding: 10px 0 6px;
    cursor: grab;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
}

.mc-drag-bar {
    width: 36px;
    height: 4px;
    border-radius: 2px;
    background: rgba(255,255,255,0.2);
}

/* --- Tabs --- */
.mc-sheet-tabs {
    display: flex;
    gap: 0;
    padding: 0 12px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    flex-shrink: 0;
}

.mc-tab {
    flex: 1;
    padding: 8px 0;
    border: none;
    background: none;
    color: #718096;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
    -webkit-tap-highlight-color: transparent;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.mc-tab.active {
    color: #f0f4f8;
    border-bottom-color: #667eea;
}

/* --- Search --- */
.mc-sheet-search {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    flex-shrink: 0;
}

.mc-sheet-search svg {
    color: #4a5568;
    flex-shrink: 0;
}

.mc-sheet-search input {
    flex: 1;
    border: none;
    background: none;
    color: #f0f4f8;
    font-size: 14px;
    outline: none;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.mc-sheet-search input::placeholder {
    color: #4a5568;
}

/* --- Sheet Body (scrollable) --- */
.mc-sheet-body {
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: env(safe-area-inset-bottom, 0);
}

/* =========================================================================
   ENTITY CARDS
   ========================================================================= */
.mc-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px 4px;
}

.mc-section-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #4a5568;
}

.mc-section-count {
    font-size: 11px;
    color: #4a5568;
    background: rgba(255,255,255,0.05);
    padding: 1px 7px;
    border-radius: 8px;
}

.mc-entity-card {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: background 0.15s;
}

.mc-entity-card:active {
    background: rgba(255,255,255,0.04);
}

.mc-entity-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.mc-entity-info {
    flex: 1;
    min-width: 0;
}

.mc-entity-name {
    font-size: 14px;
    font-weight: 500;
    color: #f0f4f8;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mc-entity-type {
    font-size: 11px;
    color: #667eea;
    margin-top: 1px;
    display: block;
}

.mc-entity-note {
    font-size: 12px;
    color: #718096;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mc-chevron {
    color: #4a5568;
    flex-shrink: 0;
}

/* =========================================================================
   CLOUD MAP CARDS
   ========================================================================= */
.mc-cloud-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: background 0.15s;
}

.mc-cloud-card:active {
    background: rgba(255,255,255,0.04);
}

.mc-cloud-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.mc-cloud-info {
    flex: 1;
    min-width: 0;
}

.mc-cloud-name {
    font-size: 14px;
    font-weight: 500;
    color: #f0f4f8;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mc-cloud-meta {
    font-size: 12px;
    color: #718096;
    margin-top: 2px;
}

/* =========================================================================
   LOADING & EMPTY STATES
   ========================================================================= */
.mc-loading-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 32px 16px;
    color: #718096;
    font-size: 13px;
}

.mc-empty-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 36px 24px;
    text-align: center;
}

.mc-empty-icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.mc-empty-text {
    font-size: 14px;
    font-weight: 600;
    color: #a0aec0;
}

.mc-empty-sub {
    font-size: 12px;
    color: #4a5568;
    margin-top: 4px;
    max-width: 260px;
}

/* =========================================================================
   DETAIL OVERLAY
   ========================================================================= */
.mc-detail-overlay {
    position: fixed;
    inset: 0;
    z-index: 300;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.mc-detail-overlay.open {
    pointer-events: auto;
    opacity: 1;
}

.mc-detail-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.5);
}

.mc-detail-panel {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    max-height: 85vh;
    background: #1a1f26;
    border-top-left-radius: 16px;
    border-top-right-radius: 16px;
    padding: 16px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.mc-detail-overlay.open .mc-detail-panel {
    transform: translateY(0);
}

/* --- Detail Header --- */
.mc-detail-top {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.mc-detail-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 16px;
    font-weight: 700;
    color: #fff;
}

.mc-detail-title {
    flex: 1;
    min-width: 0;
}

.mc-detail-name {
    font-size: 17px;
    font-weight: 600;
    color: #f0f4f8;
}

.mc-detail-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #718096;
    margin-top: 2px;
}

.mc-detail-type {
    color: #667eea;
    font-weight: 500;
}

.mc-detail-coords {
    color: #4a5568;
}

/* --- Attributes --- */
.mc-detail-attrs {
    background: rgba(255,255,255,0.03);
    border-radius: 10px;
    padding: 8px 12px;
    margin-bottom: 12px;
}

.mc-attr {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}

.mc-attr:last-child {
    border-bottom: none;
}

.mc-attr-key {
    font-size: 12px;
    color: #718096;
    font-weight: 500;
}

.mc-attr-val {
    font-size: 12px;
    color: #f0f4f8;
}

/* --- Notes --- */
.mc-notes-section {
    margin-top: 4px;
}

.mc-notes-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #4a5568;
    margin-bottom: 6px;
    display: block;
}

.mc-notes-input {
    width: 100%;
    min-height: 100px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    color: #f0f4f8;
    font-size: 14px;
    padding: 10px 12px;
    resize: vertical;
    outline: none;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    box-sizing: border-box;
}

.mc-notes-input:focus {
    border-color: #667eea;
}

.mc-save-btn {
    display: block;
    width: 100%;
    margin-top: 10px;
    padding: 10px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    transition: opacity 0.2s;
}

.mc-save-btn:active {
    opacity: 0.85;
}

.mc-save-btn.saved {
    background: #10B981;
}

/* =========================================================================
   ACCOUNT BODY (inside detail panel)
   ========================================================================= */
.mc-account-body {
    padding-top: 4px;
}

.mc-account-body p {
    font-size: 13px;
    color: #718096;
    margin-bottom: 16px;
    line-height: 1.5;
}

.mc-action-btn {
    display: block;
    text-align: center;
    padding: 10px;
    border-radius: 10px;
    background: rgba(255,255,255,0.06);
    color: #f0f4f8;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    -webkit-tap-highlight-color: transparent;
    transition: background 0.15s;
}

.mc-action-btn:active {
    background: rgba(255,255,255,0.1);
}

/* --- Google Sign-In Button --- */
.mc-google-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 11px;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 10px;
    background: rgba(255,255,255,0.04);
    color: #f0f4f8;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    transition: background 0.15s;
}

.mc-google-btn:active {
    background: rgba(255,255,255,0.08);
}

/* --- Sign-In Divider --- */
.mc-signin-divider {
    display: flex;
    align-items: center;
    margin: 14px 0;
    gap: 12px;
}

.mc-signin-divider::before,
.mc-signin-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255,255,255,0.08);
}

.mc-signin-divider span {
    font-size: 12px;
    color: #4a5568;
}

/* --- Form Inputs --- */
.mc-input {
    display: block;
    width: 100%;
    padding: 10px 12px;
    margin-bottom: 8px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    color: #f0f4f8;
    font-size: 14px;
    outline: none;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    box-sizing: border-box;
}

.mc-input:focus {
    border-color: #667eea;
}

.mc-input::placeholder {
    color: #4a5568;
}

/* --- Auth Links --- */
.mc-auth-links {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
}

.mc-auth-links a {
    font-size: 12px;
    color: #667eea;
    text-decoration: none;
}

.mc-auth-links a:active {
    opacity: 0.7;
}

/* --- Patreon Button --- */
.mc-patreon-btn {
    background: rgba(249, 104, 84, 0.12) !important;
    color: #f96854 !important;
    border: 1px solid rgba(249, 104, 84, 0.25);
}

.mc-patreon-btn:active {
    background: rgba(249, 104, 84, 0.2) !important;
}

/* --- Sign Out Button --- */
.mc-signout-btn {
    color: #e53e3e !important;
    background: rgba(229, 62, 62, 0.08) !important;
}

.mc-signout-btn:active {
    background: rgba(229, 62, 62, 0.15) !important;
}

/* =========================================================================
   SAFE AREA (notch phones)
   ========================================================================= */
@supports (padding-top: env(safe-area-inset-top)) {
    .mc-mobile-header {
        padding-top: env(safe-area-inset-top);
        height: calc(48px + env(safe-area-inset-top));
    }

    body.mobile-companion .canvas-container,
    .mc-canvas-area {
        top: calc(48px + env(safe-area-inset-top));
    }

    .mc-detail-panel {
        padding-bottom: calc(16px + env(safe-area-inset-bottom));
    }
}

/* =========================================================================
   WIP BANNER (Early Adopters see this)
   ========================================================================= */
.mc-wip-banner {
    position: fixed;
    top: 48px;
    left: 0;
    right: 0;
    z-index: 199;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 14px;
    background: rgba(249, 115, 22, 0.12);
    border-bottom: 1px solid rgba(249, 115, 22, 0.2);
    font-size: 11px;
    color: #fb923c;
    font-weight: 500;
}

.mc-wip-discord {
    color: #fb923c;
    text-decoration: none;
    font-weight: 600;
    font-size: 11px;
    white-space: nowrap;
}

@supports (padding-top: env(safe-area-inset-top)) {
    .mc-wip-banner {
        top: calc(48px + env(safe-area-inset-top));
    }
}

/* Push canvas down when WIP banner is present */
body.mobile-companion .mc-wip-banner ~ .app .canvas-container,
body.mobile-companion:has(.mc-wip-banner) .canvas-container {
    top: calc(48px + 28px);
}

@supports (padding-top: env(safe-area-inset-top)) {
    body.mobile-companion:has(.mc-wip-banner) .canvas-container {
        top: calc(48px + 28px + env(safe-area-inset-top));
    }
}

/* =========================================================================
   VIEW-ONLY BANNER (shared map links)
   ========================================================================= */
.mc-view-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 150;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 14px 16px;
    padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px));
    background: rgba(15, 20, 25, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid rgba(255,255,255,0.06);
    text-align: center;
}

.mc-view-banner span:first-child {
    font-size: 14px;
    font-weight: 600;
    color: #f0f4f8;
}

.mc-view-banner-sub {
    font-size: 12px;
    color: #718096;
    margin-top: 2px;
}

/* =========================================================================
   GATE SCREEN (non-subscribers)
   ========================================================================= */
.mc-gate-screen {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 55%;
    z-index: 150;
    background: #161b22;
    border-top-left-radius: 16px;
    border-top-right-radius: 16px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-shadow: 0 -4px 24px rgba(0,0,0,0.5);
}

.mc-gate-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 24px 20px;
    padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px));
    text-align: center;
}

.mc-gate-badge {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: #fb923c;
    background: rgba(249, 115, 22, 0.12);
    border: 1px solid rgba(249, 115, 22, 0.25);
    padding: 3px 10px;
    border-radius: 20px;
    margin-bottom: 10px;
}

.mc-gate-icon {
    font-size: 36px;
    margin-bottom: 8px;
}

.mc-gate-title {
    font-size: 20px;
    font-weight: 700;
    color: #f0f4f8;
    margin-bottom: 6px;
}

.mc-gate-sub {
    font-size: 13px;
    color: #718096;
    line-height: 1.5;
    max-width: 300px;
    margin-bottom: 16px;
}

.mc-gate-sub strong {
    color: #f0f4f8;
}

.mc-gate-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    width: 100%;
    max-width: 280px;
    margin-bottom: 18px;
}

.mc-gate-feature {
    font-size: 12px;
    color: #a0aec0;
    text-align: left;
    padding: 4px 0;
}

.mc-gate-cta {
    display: block;
    width: 100%;
    max-width: 280px;
    padding: 12px;
    border-radius: 10px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    text-align: center;
    text-decoration: none;
    font-size: 15px;
    font-weight: 600;
    -webkit-tap-highlight-color: transparent;
}

.mc-gate-cta:active {
    opacity: 0.85;
}

.mc-gate-price {
    font-size: 12px;
    color: #4a5568;
    margin-top: 6px;
}

.mc-gate-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    max-width: 280px;
    margin: 14px 0;
}

.mc-gate-divider::before,
.mc-gate-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255,255,255,0.08);
}

.mc-gate-divider span {
    font-size: 12px;
    color: #4a5568;
}

.mc-gate-signin {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    max-width: 280px;
    padding: 10px;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 10px;
    background: rgba(255,255,255,0.04);
    color: #f0f4f8;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.mc-gate-signin:active {
    background: rgba(255,255,255,0.08);
}

.mc-gate-email-btn {
    display: block;
    width: 100%;
    max-width: 280px;
    margin-top: 8px;
    padding: 10px;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    background: none;
    color: #718096;
    font-size: 13px;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.mc-gate-email-btn:active {
    background: rgba(255,255,255,0.04);
}

.mc-gate-signed {
    font-size: 13px;
    color: #718096;
    margin-top: 10px;
}

.mc-gate-signed strong {
    color: #f0f4f8;
}

.mc-gate-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.mc-gate-link {
    font-size: 12px;
    color: #667eea;
    text-decoration: none;
}

.mc-gate-link:active {
    opacity: 0.7;
}

.mc-gate-sep {
    color: #4a5568;
    font-size: 12px;
}

/* --- Gate Inline Sign-In Form --- */
.mc-gate-error {
    width: 100%;
    max-width: 280px;
    padding: 8px 12px;
    margin-bottom: 10px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.25);
    border-radius: 8px;
    color: #f87171;
    font-size: 12px;
    text-align: center;
}

.mc-gate-confirm {
    font-size: 13px;
    color: #10B981;
    text-align: center;
    padding: 12px 0;
}

.mc-gate-input {
    display: block;
    width: 100%;
    max-width: 280px;
    padding: 10px 12px;
    margin: 0 auto 8px auto;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 10px;
    color: #f0f4f8;
    font-size: 14px;
    outline: none;
    -webkit-appearance: none;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    box-sizing: border-box;
}

.mc-gate-input:focus {
    border-color: #667eea;
}

.mc-gate-input::placeholder {
    color: #4a5568;
}

.mc-gate-submit {
    display: block;
    width: 100%;
    max-width: 280px;
    margin: 4px auto 0 auto;
    padding: 10px;
    border: none;
    border-radius: 10px;
    background: #667eea;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.mc-gate-submit:active {
    opacity: 0.85;
}

.mc-gate-submit:disabled {
    opacity: 0.5;
    pointer-events: none;
}

.mc-gate-form-links {
    display: flex;
    justify-content: space-between;
    max-width: 280px;
    margin: 8px auto 0 auto;
}

.mc-gate-form-links a {
    font-size: 12px;
    color: #667eea;
    text-decoration: none;
}

.mc-gate-form-links a:active {
    opacity: 0.7;
}

.mc-gate-form-hint {
    font-size: 12px;
    color: #718096;
    text-align: center;
    margin-bottom: 8px;
    max-width: 280px;
}

.mc-gate-divider-sm {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    max-width: 280px;
    margin: 10px auto;
}

.mc-gate-divider-sm::before,
.mc-gate-divider-sm::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255,255,255,0.06);
}

.mc-gate-divider-sm span {
    font-size: 11px;
    color: #4a5568;
}

.mc-gate-link-btn {
    display: block;
    width: 100%;
    max-width: 280px;
    margin: 8px auto 0 auto;
    padding: 9px 12px;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    background: none;
    color: #667eea;
    font-size: 13px;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.mc-gate-link-btn:active {
    background: rgba(255,255,255,0.04);
}

.mc-gate-signout {
    color: #e53e3e;
    border-color: rgba(229, 62, 62, 0.15);
}
