/* ============================================================
   快推云 Design System — base.css
   天眼查风格 · 扁平简洁 · 中国B2B商务平台
   ============================================================ */

/* --- Custom Properties --- */
:root {
    /* Brand Blue (天眼查风格) */
    --blue-50: #e8f3ff;
    --blue-100: #d0e8ff;
    --blue-200: #a3d0ff;
    --blue-500: #1677ff;
    --blue-600: #0052d9;
    --blue-700: #003da6;
    --blue-800: #002b7a;

    /* Neutrals */
    --gray-50: #f7f8fa;
    --gray-100: #f2f3f5;
    --gray-200: #e5e6eb;
    --gray-300: #c9cdd4;
    --gray-400: #a0a3ad;
    --gray-500: #808288;
    --gray-600: #606266;
    --gray-700: #333333;
    --gray-800: #1d2129;
    --gray-900: #0d0e12;

    /* Semantic */
    --color-primary: var(--blue-600);
    --color-primary-hover: var(--blue-700);
    --color-primary-light: var(--blue-50);
    --color-primary-border: var(--blue-200);
    --color-bg: #f0f2f5;
    --color-surface: #ffffff;
    --color-text: var(--gray-800);
    --color-text-secondary: var(--gray-600);
    --color-text-muted: var(--gray-400);
    --color-border: #ebeef5;
    --color-border-light: var(--gray-100);

    --color-success: #00b578;
    --color-success-bg: #e8fff3;
    --color-warning: #ff8800;
    --color-warning-bg: #fff7e8;
    --color-error: #f53f3f;
    --color-error-bg: #fff0f0;

    /* Orange accent (天眼查风格强调色) */
    --orange-500: #ff6a00;
    --orange-bg: #fff7f0;

    /* Elevation – 天眼查完全扁平，不用阴影 */
    --shadow-xs: none;
    --shadow-sm: none;
    --shadow-md: none;
    --shadow-lg: none;
    --shadow-focus: 0 0 0 2px rgba(0, 82, 217, 0.15);

    /* Radius – 天眼查几乎无圆角 */
    --radius-xs: 0;
    --radius-sm: 2px;
    --radius-md: 2px;
    --radius-lg: 2px;
    --radius-xl: 4px;
    --radius-full: 9999px;

    /* Spacing scale (4px base) */
    --sp-1: 4px;
    --sp-2: 8px;
    --sp-3: 12px;
    --sp-4: 16px;
    --sp-5: 20px;
    --sp-6: 24px;
    --sp-8: 32px;
    --sp-10: 40px;
    --sp-12: 48px;

    /* Transitions */
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --duration-fast: 150ms;
    --duration-normal: 200ms;

    /* Layout */
    --page-max-width: 1200px;
    --nav-height: 60px;
}

/* --- Reset --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* --- Base Typography --- */
html {
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

body {
    font-family:
        -apple-system, BlinkMacSystemFont,
        "PingFang SC", "Hiragino Sans GB",
        "Microsoft YaHei UI", "Microsoft YaHei",
        "Source Han Sans SC", "Noto Sans SC",
        "Segoe UI", Roboto, sans-serif;
    font-size: 14px;
    line-height: 1.5715;
    color: var(--color-text);
    background: var(--color-bg);
}

h1, h2, h3, h4 {
    font-weight: 600;
    line-height: 1.35;
    color: var(--gray-800);
}

h1 { font-size: 24px; }
h2 { font-size: 18px; }
h3 { font-size: 16px; }

p {
    color: var(--color-text-secondary);
    line-height: 1.6;
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--duration-fast) ease;
}
a:hover {
    color: var(--color-primary-hover);
}

/* --- Card — 天眼查扁平卡片 --- */
.card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: var(--sp-6);
}

/* --- Buttons --- */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--sp-2);
    height: 36px;
    padding: 0 var(--sp-5);
    background: var(--color-primary);
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--duration-fast) ease;
    white-space: nowrap;
    text-decoration: none;
}
.btn-primary:hover {
    background: var(--color-primary-hover);
    color: #fff;
}
.btn-primary:active {
    transform: scale(0.98);
}
.btn-primary:disabled {
    background: var(--blue-200);
    cursor: not-allowed;
    transform: none;
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--sp-2);
    height: 36px;
    padding: 0 var(--sp-5);
    background: var(--color-surface);
    color: var(--color-text);
    font-size: 14px;
    font-weight: 500;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--duration-fast) ease;
    white-space: nowrap;
    text-decoration: none;
}
.btn-secondary:hover {
    color: var(--color-primary);
    border-color: var(--color-primary);
}

.btn-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--sp-2);
    height: 32px;
    padding: 0 var(--sp-3);
    background: transparent;
    color: var(--color-text-secondary);
    font-size: 13px;
    font-weight: 500;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--duration-fast) ease;
}
.btn-ghost:hover {
    background: var(--gray-100);
    color: var(--color-text);
}

/* Full-width submit button */
.btn-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 42px;
    padding: 0 var(--sp-6);
    background: var(--color-primary);
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--duration-fast) ease;
}
.btn-submit:hover {
    background: var(--color-primary-hover);
}
.btn-submit:active {
    transform: scale(0.99);
}
.btn-submit:disabled {
    background: var(--blue-200);
    cursor: not-allowed;
    transform: none;
}

/* --- Forms --- */
.form-group {
    margin-bottom: var(--sp-5);
}

label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text);
    margin-bottom: var(--sp-2);
}

input, select, textarea {
    width: 100%;
    height: 36px;
    padding: 0 var(--sp-3);
    font-family: inherit;
    font-size: 14px;
    color: var(--color-text);
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    transition: border-color var(--duration-fast) ease;
    outline: none;
    box-sizing: border-box;
}
textarea {
    height: auto;
    min-height: 80px;
    padding: var(--sp-2) var(--sp-3);
    resize: vertical;
    line-height: 1.6;
}
select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%23a0a3ad' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 8px center;
    background-repeat: no-repeat;
    background-size: 16px;
    padding-right: 32px;
}
input:focus, select:focus, textarea:focus {
    border-color: var(--color-primary);
}
input::placeholder, textarea::placeholder {
    color: var(--color-text-muted);
}
input:disabled, select:disabled {
    background: var(--gray-50);
    color: var(--color-text-muted);
    cursor: not-allowed;
    opacity: 0.6;
}
input[readonly] {
    background: var(--gray-50);
}

/* --- Tips / Status Messages --- */
.tips {
    min-height: 20px;
    font-size: 12px;
    line-height: 1.5;
    padding: var(--sp-1) 0;
    color: var(--color-text-muted);
}
.tips.error { color: var(--color-error); }
.tips.success { color: var(--color-success); }
.tips.warn { color: var(--color-warning); }

.status {
    min-height: 20px;
    font-size: 12px;
    color: var(--color-text-muted);
}
.status.error { color: var(--color-error); }
.status.success { color: var(--color-success); }

/* --- Member Topbar --- */
.member-topbar {
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 56px;
    padding: 0 var(--sp-6);
    background: #fff;
    border-bottom: 1px solid var(--color-border);
}

.member-topbar-brand {
    display: flex;
    align-items: center;
    gap: var(--sp-2);
    font-size: 16px;
    font-weight: 600;
    color: var(--color-text);
    text-decoration: none;
}
.member-topbar-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: var(--color-primary);
    border-radius: var(--radius-sm);
}
.member-topbar-logo svg {
    width: 14px;
    height: 14px;
}
.member-topbar-brand:hover {
    color: var(--color-text);
}

.member-topbar-nav {
    display: flex;
    align-items: center;
    gap: var(--sp-1);
}
.member-topbar-nav a {
    display: inline-flex;
    align-items: center;
    height: 32px;
    padding: 0 var(--sp-3);
    font-size: 13px;
    font-weight: 500;
    color: var(--color-text-secondary);
    border-radius: var(--radius-sm);
    transition: all var(--duration-fast) ease;
    text-decoration: none;
}
.member-topbar-nav a:hover,
.member-topbar-nav a.active {
    color: var(--color-primary);
    background: var(--color-primary-light);
}

/* --- Site Nav (天眼查风格蓝色顶栏) --- */
.site-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    height: var(--nav-height);
    background: var(--color-primary);
}
.site-nav-inner {
    max-width: var(--page-max-width);
    margin: 0 auto;
    padding: 0 20px;
    height: 100%;
    display: flex;
    align-items: center;
    gap: 0;
}
.site-nav-brand {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #fff;
    text-decoration: none;
    margin-right: 32px;
    flex-shrink: 0;
}
.site-nav-brand-mark {
    min-width: 30px;
    width: 30px;
    height: 30px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #2563eb;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    flex-shrink: 0;
}
.site-nav-brand-mark svg {
    width: 18px;
    height: 18px;
}
.site-nav-brand-text {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #fff;
}
.site-nav-links {
    display: flex;
    align-items: center;
    gap: 0;
    flex: 1;
    min-width: 0;
}
.site-nav-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: var(--nav-height);
    padding: 0 16px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    white-space: nowrap;
    transition: all var(--duration-fast) ease;
    border-bottom: 2px solid transparent;
}
.site-nav-links a:hover,
.site-nav-links a.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}
.site-nav-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    margin-left: auto;
}
.site-nav-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 32px;
    padding: 0 14px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: all var(--duration-fast) ease;
    color: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.35);
    background: transparent;
}
.site-nav-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.5);
}
.site-nav-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 32px;
    padding: 0 14px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: all var(--duration-fast) ease;
    color: var(--color-primary);
    background: #fff;
}
.site-nav-btn-primary:hover {
    background: rgba(255, 255, 255, 0.9);
    color: var(--color-primary-hover);
}

/* Nav – logged-in user dropdown */
.nav-user-wrap {
    position: relative;
}
.nav-user-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 32px;
    padding: 0 10px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius-sm);
    background: transparent;
    color: #fff;
    font-size: 13px;
    cursor: pointer;
    transition: background var(--duration-fast) ease;
}
.nav-user-btn:hover {
    background: rgba(255, 255, 255, 0.12);
}
.nav-user-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    font-size: 12px;
    font-weight: 600;
    color: #fff;
    flex-shrink: 0;
}
.nav-user-name {
    max-width: 80px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.nav-user-arrow {
    font-size: 12px;
    transition: transform var(--duration-fast) ease;
}
.nav-user-wrap.open .nav-user-arrow {
    transform: rotate(180deg);
}
.nav-user-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 140px;
    background: #fff;
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    padding: 4px 0;
    z-index: 1000;
}
.nav-user-wrap.open .nav-user-dropdown {
    display: block;
}
.nav-user-dropdown a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    font-size: 13px;
    color: var(--gray-700);
    text-decoration: none;
    transition: background var(--duration-fast) ease;
}
.nav-user-dropdown a:hover {
    background: var(--gray-50);
    color: var(--color-primary);
}
.nav-user-dropdown .iconfont {
    font-size: 14px;
    color: var(--gray-400);
}
.nav-user-dropdown a:hover .iconfont {
    color: var(--color-primary);
}

/* Home nav variant – transparent over hero */
.site-nav-home {
    background: var(--color-primary);
}

/* --- Front Utilities --- */
.front-shell,
.page-container,
.wrap {
    width: 100%;
    max-width: var(--page-max-width);
    padding: 0 20px;
    margin: 0 auto;
}
.front-page-section {
    margin-top: 20px;
}
.platform-card {
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
}
.platform-card-soft {
    background: #fff;
    border: 1px solid var(--color-primary-border);
    border-radius: var(--radius-lg);
}
.platform-kicker {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 22px;
    padding: 0 8px;
    border-radius: var(--radius-sm);
    background: var(--color-primary-light);
    color: var(--color-primary);
    font-size: 12px;
    font-weight: 500;
}
.platform-section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}
.platform-section-head h2,
.platform-section-head h3 {
    margin: 0;
}
.platform-section-desc {
    margin-top: 4px;
    color: var(--color-text-secondary);
}
.platform-badge,
.platform-tag,
.platform-status {
    display: inline-flex;
    align-items: center;
    height: 22px;
    padding: 0 8px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 500;
}
.platform-badge,
.platform-tag {
    background: var(--gray-100);
    color: var(--gray-600);
}
.platform-status {
    background: var(--color-primary-light);
    color: var(--color-primary);
}
.platform-status-warn {
    background: var(--color-warning-bg);
    color: var(--color-warning);
}
.platform-grid-2 {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 16px;
}
.platform-empty {
    padding: 40px 20px;
    text-align: center;
    color: var(--color-text-muted);
}
.empty-tip {
    text-align: center;
    padding: var(--sp-10) var(--sp-6);
    color: var(--color-text-muted);
    font-size: 14px;
}

/* --- Toast --- */
.toast-container {
    position: fixed;
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    pointer-events: none;
}
.toast {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-md);
    font-size: 14px;
    line-height: 1.5;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    color: var(--color-text);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
    pointer-events: auto;
    animation: toastIn 0.3s var(--ease-out) both;
    max-width: 480px;
}
.toast-icon {
    font-size: 18px;
    flex-shrink: 0;
}
.toast.toast-success {
    background: var(--color-success-bg);
    border-color: var(--color-success);
    color: #0a6640;
}
.toast.toast-success .toast-icon { color: var(--color-success); }
.toast.toast-error {
    background: var(--color-error-bg);
    border-color: var(--color-error);
    color: #c02020;
}
.toast.toast-error .toast-icon { color: var(--color-error); }
.toast.toast-warning {
    background: var(--color-warning-bg);
    border-color: var(--color-warning);
    color: #8a4500;
}
.toast.toast-warning .toast-icon { color: var(--color-warning); }
.toast.toast-out {
    animation: toastOut 0.25s ease both;
}
@keyframes toastIn {
    from { opacity: 0; transform: translateY(-16px) scale(0.96); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes toastOut {
    from { opacity: 1; transform: translateY(0) scale(1); }
    to   { opacity: 0; transform: translateY(-12px) scale(0.96); }
}

/* Fade-in animation */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-in {
    animation: fadeInUp 0.3s ease both;
}

/* --- Tooltip (data-tip) --- */
[data-tip] {
    position: relative;
}
[data-tip]::after {
    content: attr(data-tip);
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: calc(100% + 8px);
    padding: 6px 12px;
    background: #fff;
    color: #999;
    font-size: 12px;
    line-height: 1.5;
    white-space: nowrap;
    border-radius: 6px;
    border: 1px solid #e5e6eb;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s, visibility 0.2s;
    z-index: 100;
}
[data-tip]::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%) rotate(45deg);
    bottom: calc(100% + 3px);
    width: 8px;
    height: 8px;
    background: #fff;
    border-right: 1px solid #e5e6eb;
    border-bottom: 1px solid #e5e6eb;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s, visibility 0.2s;
    z-index: 101;
}
[data-tip]:hover::after,
[data-tip]:hover::before {
    opacity: 1;
    visibility: visible;
}

/* --- Loading Spinner --- */
@keyframes spin { to { transform: rotate(360deg); } }
.loading-spinner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 24px 0;
    color: var(--color-text-muted);
    font-size: 13px;
}
.loading-spinner::before {
    content: "";
    width: 18px;
    height: 18px;
    border: 2px solid var(--color-border);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    flex-shrink: 0;
}

/* --- Footer (公共底部) --- */
.site-footer {
    background: #2c3e50;
    color: rgba(255, 255, 255, 0.65);
    font-size: 13px;
    margin-top: 40px;
}
.site-footer-inner {
    max-width: var(--page-max-width);
    margin: 0 auto;
    padding: 32px 20px 24px;
}
.site-footer-top {
    display: flex;
    justify-content: space-between;
    gap: 40px;
    padding-bottom: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.footer-brand {
    flex-shrink: 0;
}
.footer-brand-name {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 8px;
}
.footer-brand-desc {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    max-width: 260px;
    line-height: 1.6;
}
.footer-links {
    display: flex;
    gap: 48px;
}
.footer-col h4 {
    font-size: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 12px;
}
.footer-col a {
    display: block;
    padding: 3px 0;
    color: rgba(255, 255, 255, 0.55);
    font-size: 13px;
    transition: color .15s;
}
.footer-col a:hover {
    color: #fff;
}
.site-footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 16px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.35);
}
.site-footer-bottom a {
    color: rgba(255, 255, 255, 0.45);
}
.site-footer-bottom a:hover {
    color: rgba(255, 255, 255, 0.7);
}
.footer-disclaimer {
    padding: 12px 0;
    margin-bottom: 4px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 12px;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.32);
}
.footer-disclaimer a {
    color: rgba(255, 255, 255, 0.5);
    text-decoration: underline;
}
.footer-disclaimer a:hover {
    color: rgba(255, 255, 255, 0.75);
}

/* --- AI Content Badge --- */
.badge-ai {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 12px;
    font-weight: 400;
    color: #8b5cf6;
    background: #f5f3ff;
    border: 1px solid #ede9fe;
    border-radius: 4px;
    padding: 2px 8px;
    margin-left: 8px;
    vertical-align: middle;
    line-height: 1.4;
}
.badge-ai::before {
    content: "AI";
    font-size: 10px;
    font-weight: 700;
    background: #8b5cf6;
    color: #fff;
    border-radius: 2px;
    padding: 0 3px;
    line-height: 1.4;
}

/* --- Info Correction Link --- */
.info-correction {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #9ca3af;
    transition: color .15s;
}
.info-correction:hover {
    color: #3b82f6;
}

/* --- Hamburger Button (hidden on desktop) --- */
.nav-hamburger {
    display: none;
    width: 36px;
    height: 36px;
    padding: 0;
    border: none;
    background: transparent;
    cursor: pointer;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    margin-left: auto;
}
.nav-hamburger span {
    display: block;
    width: 20px;
    height: 2px;
    background: #fff;
    transition: all .2s;
}
.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* --- Responsive: Mobile-first tables --- */
.m-table-card {
    display: none;
}

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

/* === Mobile: 768px === */
@media (max-width: 768px) {
    /* Nav: hamburger mode — actions + links all go into dropdown */
    .site-nav {
        height: auto;
        min-height: 50px;
    }
    .site-nav-inner {
        flex-wrap: wrap;
        padding: 0 12px;
        min-height: 50px;
    }
    .site-nav-brand {
        margin-right: 0;
    }
    /* Hide both links and action buttons by default */
    .site-nav-links {
        display: none;
        width: 100%;
        flex-direction: column;
        gap: 0;
        padding: 0 0 8px;
        order: 3;
        border-top: 1px solid rgba(255,255,255,0.15);
    }
    .site-nav-links.open {
        display: flex;
    }
    .site-nav-links a {
        height: 44px;
        padding: 0 12px;
        font-size: 14px;
        justify-content: flex-start;
        border-bottom: none;
        color: rgba(255,255,255,0.85);
    }
    .site-nav-links a:hover {
        background: rgba(255,255,255,0.08);
    }
    /* Hide desktop action buttons, they go into the dropdown */
    .site-nav-actions {
        display: none;
        width: 100%;
        order: 4;
        padding: 4px 0 8px;
        gap: 8px;
        border-top: 1px solid rgba(255,255,255,0.1);
    }
    .site-nav-actions.open {
        display: flex;
    }
    .site-nav-btn-secondary,
    .site-nav-btn-primary {
        flex: 1;
        height: 36px;
        font-size: 13px;
        justify-content: center;
    }
    .nav-hamburger {
        display: flex;
        margin-left: auto;
    }
    .nav-user-wrap {
        width: 100%;
    }
    .nav-user-btn {
        width: 100%;
        justify-content: center;
        height: 36px;
    }
    .nav-user-dropdown {
        position: static;
        box-shadow: none;
        background: rgba(255, 255, 255, 0.08);
        border-radius: 0;
        margin-top: 4px;
    }
    .nav-user-dropdown a {
        color: rgba(255, 255, 255, 0.85);
        justify-content: center;
    }
    .nav-user-dropdown a:hover {
        background: rgba(255, 255, 255, 0.08);
        color: #fff;
    }
    .nav-user-dropdown .iconfont,
    .nav-user-dropdown a:hover .iconfont {
        color: rgba(255, 255, 255, 0.6);
    }

    /* Layout */
    .front-shell,
    .page-container,
    .wrap {
        padding: 0 12px;
    }

    /* Typography */
    h1 { font-size: 20px; }
    h2 { font-size: 16px; }

    /* Table → Card layout on mobile */
    .enterprise-table thead { display: none; }
    .enterprise-table,
    .enterprise-table tbody,
    .enterprise-table tr,
    .enterprise-table td {
        display: block;
        width: 100%;
    }
    .enterprise-table tr {
        padding: 12px 0;
        border-bottom: 1px solid #e8e8e8;
    }
    .enterprise-table td {
        padding: 2px 0;
        border: none;
        font-size: 13px;
    }
    .enterprise-table td:first-child {
        font-size: 15px;
        font-weight: 600;
        margin-bottom: 4px;
    }
    .enterprise-table td:first-child a {
        font-size: 15px;
    }
    .enterprise-table tbody tr:hover {
        background: transparent;
    }
    .enterprise-table-wrap {
        overflow-x: visible;
    }

    /* Info table → each row stacks label on top of value */
    .info-table,
    .info-table tbody,
    .info-table tr,
    .info-table td {
        display: block;
        width: 100%;
    }
    .info-table td {
        border: none;
    }
    .info-table tr {
        border-bottom: 1px solid #f0f0f0;
    }
    .info-table tr:last-child {
        border-bottom: none;
    }
    .info-table .info-label {
        width: 100%;
        background: transparent;
        padding: 8px 0 2px;
        font-size: 12px;
        color: #999;
    }
    .info-table .info-value {
        padding: 0 0 8px;
        font-size: 14px;
        color: #333;
    }

    /* Footer */
    .site-footer-top {
        flex-direction: column;
        gap: 20px;
    }
    .footer-links {
        gap: 20px;
        flex-wrap: wrap;
    }
    .site-footer-bottom {
        flex-direction: column;
        gap: 6px;
        text-align: center;
    }
    .site-footer-inner {
        padding: 24px 12px 16px;
    }

    /* Buttons: bigger touch targets */
    .btn-primary, .btn-secondary {
        height: 40px;
        font-size: 14px;
    }
    .btn-submit {
        height: 44px;
    }

    /* Pagination: bigger on mobile */
    .pagination a,
    .pagination span,
    .table-pagination a,
    .table-pagination span {
        min-width: 36px;
        height: 36px;
        font-size: 14px;
    }
}

/* === Small phone: 480px === */
@media (max-width: 480px) {
    h1 { font-size: 18px; }
    h2 { font-size: 15px; }
    h3 { font-size: 14px; }

    .front-shell,
    .page-container,
    .wrap {
        padding: 0 10px;
    }

    .site-nav-brand-text {
        font-size: 16px;
    }

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