/* ==================== CSS Variables ==================== */
:root {
    /* Slate Colors - 深邃蓝色调 */
    --slate-50: #eff6ff;
    --slate-100: #dbeafe;
    --slate-200: #bfdbfe;
    --slate-300: #93c5fd;
    --slate-400: #60a5fa;
    --slate-500: #3b82f6;
    --slate-600: #2563eb;
    --slate-700: #1d4ed8;
    --slate-800: #1e40af;
    --slate-900: #1e3a8a;

    /* Primary Colors - 深邃蓝主题 */
    --red-500: #2563eb;
    --red-600: #1d4ed8;
    --blue-500: #3b82f6;
    --blue-600: #2563eb;
    --blue-700: #1d4ed8;
    --yellow-300: #93c5fd;
    --yellow-400: #60a5fa;
    --yellow-500: #3b82f6;

    /* Status Colors */
    --emerald-600: #059669;
    --teal-600: #0d9488;
    --violet-600: #7c3aed;
    --purple-600: #9333ea;
    --indigo-100: #dbeafe;
    --indigo-600: #2563eb;

    /* Semantic - 深邃蓝色调 */
    --background: #172554;
    --foreground: #ffffff;
    --border: #1e40af;
    --card-bg: #1e3a8a;
    --shadow-sm: 0 1px 2px 0 rgb(37 99 235 / 0.15);
    --shadow-md: 0 4px 6px -1px rgb(37 99 235 / 0.2), 0 2px 4px -2px rgb(37 99 235 / 0.15);
    --shadow-lg: 0 10px 15px -3px rgb(37 99 235 / 0.25), 0 4px 6px -4px rgb(37 99 235 / 0.2);
    --shadow-xl: 0 20px 25px -5px rgb(37 99 235 / 0.3), 0 8px 10px -6px rgb(37 99 235 / 0.25);
}

/* ==================== Global Reset ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC',
                 'Microsoft YaHei', 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(180deg, #0f172a 0%, #1e3a8a 50%, #1e40af 100%);
    color: var(--foreground);
    line-height: 1.6;
    min-height: 100vh;
    position: relative;
}

/* Background Pattern - 深邃星空点状图案 */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: 0;
    opacity: 0.6;
    pointer-events: none;
    background-image: radial-gradient(#60a5fa 1px, transparent 1px);
    background-size: 28px 28px;
}

body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    background: radial-gradient(ellipse at top, rgba(37, 99, 235, 0.15), transparent 70%);
}

/* Scrollbar Styling - 深邃蓝色 */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: rgba(30, 58, 138, 0.5);
}

::-webkit-scrollbar-thumb {
    background: #3b82f6;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #60a5fa;
}

/* Selection */
::selection {
    /* background: rgba(239, 68, 68, 0.1);
    color: #991b1b; */
}

/* ==================== Loading Screen ==================== */
.loading-screen {
    position: fixed;
    inset: 0;
    background: var(--background);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.loading-spinner {
    width: 2.5rem;
    height: 2.5rem;
    border: 3px solid rgba(59, 130, 246, 0.3);
    border-top-color: #3b82f6;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.loading-text {
    margin-top: 1rem;
    color: #93c5fd;
    font-size: 0.875rem;
}

/* ==================== Main Container ==================== */
.main-app {
    position: relative;
    z-index: 1;
    min-height: 100vh;
}

.container {
    max-width: 1152px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* ==================== Navbar ==================== */
.navbar {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(30, 58, 138, 0.95);
    backdrop-filter: blur(24px);
    border-bottom: 1px solid rgba(59, 130, 246, 0.4);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.navbar-container {
    max-width: 1152px;
    margin: 0 auto;
    padding: 0 1rem;
}

.navbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.navbar-logo {
    width: 40px;
    display: flex;
    align-items: center;
}
.navbar-logo img {
    width: 100%;
    box-shadow: var(--shadow-mg);
}


.navbar-logo:hover {
    transform: rotate(0deg);
}

.navbar-title-wrapper {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.navbar-title {
    font-weight: 800;
    font-size: 1.25rem;
    letter-spacing: -0.025em;
    color: #ffffff;
    line-height: 1;
}

.navbar-title .highlight {
    color: #60a5fa;
}

.navbar-subtitle {
    font-size: 10px;
    color: #93c5fd;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

/* Desktop Nav */
.nav-items {
    display: none;
    gap: 0.5rem;
    align-items: center;
}

.nav-item {
    position: relative;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 700;
    transition: all 0.2s;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
}

.nav-item svg {
    width: 16px;
    height: 16px;
}

.nav-item.active {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: white;
    box-shadow: 0 10px 15px -3px rgba(37, 99, 235, 0.5);
}
.nav-item.activeDownload {
    background: linear-gradient(135deg, #2563eb, #1d4ed8) !important;
    color: white !important;
    box-shadow: 0 10px 15px -3px rgba(37, 99, 235, 0.5);
}
.nav-item.activeDownload svg {
    fill: white;
}


.nav-item:not(.active) {
    color: #93c5fd;
}

.nav-item:not(.active):hover {
    background: rgba(59, 130, 246, 0.2);
    color: #ffffff;
}

@media (min-width: 768px) {
    .nav-items {
        display: flex;
    }
}

/* Mobile Bottom Nav */
.mobile-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(30, 58, 138, 0.98);
    backdrop-filter: blur(12px);
    border-top: 1px solid rgba(59, 130, 246, 0.4);
    z-index: 50;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
    display: flex;
    padding-bottom: env(safe-area-inset-bottom);
}

.mobile-nav-content {
    display: flex;
    justify-content: space-around;
    align-items: center;
    height: 64px;
    width: 100%;
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    gap: 0.25rem;
    transition: color 0.2s;
    background: none;
    border: none;
    cursor: pointer;
    color: #93c5fd;
}

.mobile-nav-item.active {
    color: #60a5fa;
}

.mobile-nav-item svg {
    width: 20px;
    height: 20px;
    stroke-width: 2;
}

.mobile-nav-item.active svg {
    width: 22px;
    height: 22px;
    stroke-width: 2.5;
}

.mobile-nav-item span {
    font-size: 10px;
    font-weight: 700;
}

@media (min-width: 768px) {
    .mobile-nav {
        display: none;
    }
}

/* ==================== Main Content ==================== */
.main-content {
    position: relative;
    z-index: 10;
    max-width: 1152px;
    margin: 0 auto;
    padding: 2rem 1rem;
    min-height: calc(100vh - 64px);
}

@media (max-width: 767px) {
    .main-content {
        /* margin-bottom: 64px; */
    }
}

/* ==================== Tab System ==================== */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==================== Hero Banner (Ticket Style) ==================== */
.hero-banner {
    position: relative;
    background: linear-gradient(135deg, #1e40af, #2563eb, #3b82f6);
    border-radius: 1.5rem;
    padding: 1px;
    box-shadow: var(--shadow-xl), 0 0 40px rgba(37, 99, 235, 0.5);
    overflow: hidden;
    margin-bottom: 2rem;
}

.hero-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20"><rect width="20" height="20" fill="white" opacity="0.1"/></svg>');
    opacity: 0.1;
}

.hero-banner-blur-1 {
    position: absolute;
    right: -40px;
    top: -40px;
    width: 300px;
    height: 300px;
    background: #60a5fa;
    border-radius: 50%;
    mix-blend-mode: screen;
    filter: blur(60px);
    opacity: 0.5;
    animation: pulse 3s ease-in-out infinite;
}

.hero-banner-blur-2 {
    position: absolute;
    left: -40px;
    bottom: -40px;
    width: 300px;
    height: 300px;
    background: #1d4ed8;
    border-radius: 50%;
    mix-blend-mode: screen;
    filter: blur(60px);
    opacity: 0.4;
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 0.7; }
}

.hero-banner-content {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(4px);
    border-radius: 1.25rem;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    z-index: 10;
    color: white;
}

.hero-banner-grid {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.hero-banner-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.hero-badge-tag {
    background: rgba(255, 255, 255, 0.95);
    color: #1e40af;
    font-size: 0.75rem;
    font-weight: 900;
    padding: 0.125rem 0.5rem;
    border-radius: 0.25rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.hero-badge-countdown {
    color: #bfdbfe;
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.025em;
    opacity: 0.95;
}

.hero-title {
    font-size: 2rem;
    font-weight: 900;
    color: white;
    margin-bottom: 0.5rem;
    letter-spacing: -0.025em;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.hero-title-gradient {
    background: linear-gradient(to right, #60a5fa, #93c5fd);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    color: #dbeafe;
    font-size: 0.875rem;
    font-weight: 500;
}

.hero-meta-item {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    background: rgba(0, 0, 0, 0.2);
    padding: 0.375rem 0.75rem;
    border-radius: 9999px;
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-meta-item svg {
    width: 15px;
    height: 15px;
    color: #60a5fa;
}

.hero-date-badge {
    background: rgba(255, 255, 255, 0.95);
    color: #1e40af;
    padding: 0.5rem 1rem;
    border-radius: 0.75rem;
    font-family: 'Courier New', monospace;
    font-weight: 700;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
    transform: rotate(2deg);
    border-bottom: 4px solid rgba(220, 38, 38, 0.1);
}

.hero-date-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-top: 0.5rem;
}

@media (min-width: 768px) {
    .hero-banner-content {
        padding: 2rem;
    }

    .hero-banner-grid {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }

    .hero-title {
        font-size: 2.25rem;
    }
}

/* ==================== Info Card ==================== */
.info-card {
    background: #ffffff;
    border-left: 4px solid #3b82f6;
    border-radius: 0 0.75rem 0.75rem 0;
    padding: 1.25rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 2rem;
}

.info-card-icon {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    padding: 0.5rem;
    border-radius: 9999px;
    color: #ffffff;
    flex-shrink: 0;
    margin-top: 0.125rem;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.4);
}

.info-card-icon svg {
    width: 20px;
    height: 20px;
}

.info-card-content {
    font-size: 0.875rem;
    color: #475569;
    line-height: 1.6;
}

.info-card-title {
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.25rem;
    font-size: 1rem;
}

.info-card-content .highlight-red {
    font-weight: 700;
    color: #dc2626;
}

.info-card-content .highlight-blue {
    font-weight: 700;
    color: #2563eb;
}

/* ==================== Model Cards Grid ==================== */
.models-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

@media (min-width: 1024px) {
    .models-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ==================== Model Prediction Card ==================== */
.model-card {
    position: relative;
    background: #ffffff;
    border-radius: 1rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    border: 1px solid #e2e8f0;
    overflow: hidden;
    transform: translateY(0);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.model-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    border-color: #3b82f6;
}

/* Model Header */
.model-card-header {
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

.model-card-header::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 128px;
    height: 128px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    margin-right: -64px;
    margin-top: -64px;
    filter: blur(32px);
}

/* Model Colors */
.model-header-gpt {
    background: linear-gradient(to right, var(--emerald-600), var(--teal-600));
    color: white;
}

.model-header-claude {
    background: linear-gradient(to right, var(--violet-600), var(--purple-600));
    color: white;
}

.model-header-deepseek {
    background: linear-gradient(to right, var(--blue-600), #0891b2);
    color: white;
}

.model-header-gemini {
    background: linear-gradient(to right, #ea580c, #dc2626);
    color: white;
}

.model-card-header-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    z-index: 10;
}

.model-icon-box {
    padding: 0.375rem;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(12px);
    border-radius: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    box-shadow: var(--shadow-sm);
}

.model-icon-box svg {
    width: 20px;
    height: 20px;
}

.model-name-wrapper h3 {
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: -0.025em;
}

.model-id {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 10px;
    color: rgba(255, 255, 255, 0.8);
    font-family: 'Courier New', monospace;
}

.model-card-ticket-icon {
    color: rgba(255, 255, 255, 0.2);
    transform: rotate(-12deg);
    position: absolute;
    right: 1rem;
    stroke-width: 1;
}

.model-card-ticket-icon svg {
    width: 48px;
    height: 48px;
}

/* Model Content */
.model-card-content {
    padding: 0.5rem 1.25rem 1rem;
}

.strategy-group {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Strategy Row */
.strategy-row {
    position: relative;
    padding: 1rem 0;
}

.strategy-row:first-child {
    padding-top: 0.5rem;
}

.strategy-row:last-child {
    padding-bottom: 0;
}

.strategy-row:last-child .strategy-separator {
    display: none;
}

.strategy-header {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.strategy-label-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.strategy-group-badge {
    background: #dbeafe;
    color: #1d4ed8;
    font-size: 10px;
    font-weight: 700;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border: 1px solid #93c5fd;
}

.strategy-name {
    font-size: 0.875rem;
    font-weight: 700;
    color: #1e293b;
    background: linear-gradient(to right, #dbeafe, transparent);
    padding: 0.125rem 0.5rem;
    border-radius: 0.25rem;
}

/* Balls Display */
.strategy-balls {
    display: flex;
    gap: 0.5rem;
    padding-left: 0.25rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
    margin-bottom: 0.75rem;
}

.strategy-balls::-webkit-scrollbar {
    height: 4px;
}

.ball-divider {
    align-self: center;
    font-size: 2rem;
    height: 36px;
    line-height: 30px;
    color: #959595;
}
.lottery-ball-text,.mini-result-ball-text{
    width: 100%;
    text-align: center;
    font-size: 0.9rem;
    color: #000000;
    padding: 5px 0;
}
/* Lottery Ball */
.lottery-ball {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1rem;
    color: #000000;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
    border-bottom: 2px solid rgba(0, 0, 0, 0.1);
    background-image: url(../images/ball_grey_tool.png);
    background-repeat: no-repeat;
    background-size: 100%;
    background-position: center;
}

.lottery-ball.size-sm {
    width: 28px;
    height: 28px;
    font-size: 0.75rem;
}

.lottery-ball.size-md {
    width: 36px;
    height: 36px;
    font-size: 1rem;
}

.lottery-ball.size-lg {
    width: 48px;
    height: 48px;
    font-size: 1.125rem;
}

.lottery-ball::before {
    content: '';
    position: absolute;
    top: 4px;
    left: 6px;
    width: 40%;
    height: 30%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.4), transparent);
    border-radius: 50%;
    filter: blur(1px);
}

.lottery-ball span {
    position: relative;
    z-index: 10;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    padding-bottom: 0.25rem;
    padding-left: 0.1rem;
}

.lottery-ball.red {
    background-image: url(../images/ball_red_tool.png);
    color: rgb(0, 0, 0);
}

.lottery-ball.blue {
    background-image: url(../images/ball_blue_tool.png);
    color: rgb(0, 0, 0);
}
.lottery-ball.green {
    background-image: url(../images/ball_green_tool.png);
    color: rgb(0, 0, 0);
}

.lottery-ball.hit {
    /* ring: 2px solid var(--yellow-400);
    ring-offset: 2px;
    scale: 1.1;
    z-index: 10;
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(250, 204, 21, 0.6); */
}

/* Strategy Description */
.strategy-description {
    color: #475569;
    font-size: 0.75rem;
    line-height: 1.6;
    background: #f8fafc;
    padding: 0.5rem;
    border-radius: 0.25rem;
    border: 1px solid #e2e8f0;
    transition: background-color 0.2s;
}

.strategy-row:hover .strategy-description {
    background: #f1f5f9;
}

/* Ticket Separator */
.strategy-separator {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    border-bottom: 2px dashed #cbd5e1;
    width: 100%;
    transform: scaleX(1.06);
    transform-origin: center;
}

.strategy-separator::before,
.strategy-separator::after {
    content: '';
    position: absolute;
    bottom: -6px;
    width: 16px;
    height: 16px;
    background: #ffffff;
    border-radius: 50%;
    z-index: 10;
}

.strategy-separator::before {
    left: -20px;
    border-right: 1px solid #cbd5e1;
}

.strategy-separator::after {
    right: -20px;
    border-left: 1px solid #cbd5e1;
}

/* ==================== Section Headers ==================== */
.section-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}
.AiFormula-list{
    /* width: 25%; */
    margin-right: -15px;
}

.grid {
    /* margin: 0;
    padding: 0;
    list-style: none; */
    /* width: 25%; */
}
.grid-item{
    width: 25%;
    padding-right: 15px;
    padding-bottom: 15px;
}
@media (max-width: 1024px) {
    .grid-item{
        width: 33.333%;
    }
}
@media (max-width: 815px) {
    .grid-item{
        width: 50%;
    }
}
@media (max-width: 450px) {
    .grid-item{
        width: 100%;
    }
}


/* .AiFormula-list{
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}
@media (min-width: 1024px) {
    .AiFormula-list {
        grid-template-columns: repeat(4, 1fr);
    }
}
@media (max-width: 1024px) {
    .AiFormula-list {
        grid-template-columns: repeat(3, 1fr);
    }
}
@media (max-width: 815px) {
    .AiFormula-list {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 450px) {
    .AiFormula-list {
        grid-template-columns: 1fr;
    }
} */
.AiFormula-item{
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    cursor: pointer;
    height: auto;
    padding: 15px;
    /* width: 280px; */
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.AiFormula-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    border-color: #3b82f6;
}

.AiFormula-item img{
    width: 100%;
}
.AiFormula-item-text{
    width: 100%;
    text-align: center;
    padding: 5px 0;
    font-size: 1rem;
    color: #1e293b;
}
.AiFormula-item-buttons{
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 0 0;
}
.AiFormula-item-button{
    width: 9rem;
    height: 2rem;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 2rem;
    font-size: 0.9rem;
    font-weight: 700;
    color: #fff;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.5);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.AiFormula-item-button:hover {
    transform: scale(1.02);
    box-shadow: 0 6px 18px rgba(37, 99, 235, 0.6);
}
.AiFormula-item-button-icon{
    width: 0;
    height: 0;
    border: 6px solid;
    margin-left: 5px;
    border-color: transparent transparent transparent #fff;
}

.section-icon {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    padding: 0.5rem;
    border-radius: 0.5rem;
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.4);
}

.section-icon svg {
    width: 24px;
    height: 24px;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: -0.025em;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* ==================== History View ==================== */
.history-section {
    /* margin-bottom: 2.5rem; */
}

/* Accuracy Card */
.accuracy-card {
    background: #ffffff;
    border-radius: 1rem;
    border: 1px solid #e2e8f0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    margin-bottom: 2rem;
    transition: box-shadow 0.3s;
}

.accuracy-card:hover {
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.accuracy-card-header {
    background: linear-gradient(135deg, #1e40af, #2563eb);
    padding: 1rem 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.accuracy-card-header::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 80px;
    height: 100%;
    background: linear-gradient(to left, rgba(255, 255, 255, 0.1), transparent);
    transform: skewX(12deg);
}

.accuracy-header-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    z-index: 10;
}

.accuracy-trophy-icon {
    background: var(--yellow-500);
    padding: 0.375rem;
    border-radius: 0.5rem;
    color: var(--slate-900);
    box-shadow: 0 4px 10px rgba(234, 179, 8, 0.5);
}

.accuracy-trophy-icon svg {
    width: 18px;
    height: 18px;
    stroke-width: 3;
}

.accuracy-header-title {
    font-weight: 700;
    color: white;
    font-size: 1.125rem;
    line-height: 1;
}

.accuracy-header-subtitle {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.75rem;
}

.accuracy-header-date {
    font-family: 'Courier New', monospace;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.75rem;
    background: rgba(0, 0, 0, 0.2);
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
}

/* Actual Result */
.actual-result-section {
    padding: 1.25rem 1.5rem;
    background: linear-gradient(to bottom, #f8fafc, #ffffff);
    border-bottom: 1px solid #e2e8f0;
}

.actual-result-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.actual-result-bar {
    width: 4px;
    height: 16px;
    background: linear-gradient(to bottom, #3b82f6, #2563eb);
    border-radius: 9999px;
}

.actual-result-text {
    font-size: 0.75rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
}

.actual-result-balls {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Model Hits List */
.model-hits-list {
    padding: 1rem 1.5rem;
}

.model-hit-item {
    position: relative;
    margin-bottom: 1.5rem;
}

.model-hit-item:last-child {
    margin-bottom: 0;
}

.model-hit-connector {
    position: absolute;
    left: 11px;
    top: 32px;
    bottom: -24px;
    width: 1px;
    background: #e2e8f0;
    z-index: 0;
}

.model-hit-item:last-child .model-hit-connector {
    display: none;
}

.model-hit-row {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    position: relative;
    z-index: 10;
}

.model-hit-number {
    margin-top: 0.25rem;
    min-width: 24px;
    height: 24px;
    border-radius: 9999px;
    background: #ffffff;
    border: 2px solid #3b82f6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
    color: #2563eb;
}

.model-hit-content {
    flex: 1;
}

.model-hit-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.model-hit-name {
    font-size: 0.875rem;
    font-weight: 700;
    color: #1e293b;
}

.high-hit-badge {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 10px;
    font-weight: 700;
    background: #dbeafe;
    color: #1d4ed8;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    border: 1px solid #93c5fd;
}

.high-hit-badge svg {
    width: 10px;
    height: 10px;
    fill: currentColor;
}

/* Prediction Groups in History */
.prediction-groups {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.5rem;
}

.prediction-group-row {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    font-size: 0.75rem;
    padding: 0.75rem;
    border-radius: 0.75rem;
    border: 1px solid transparent;
    transition: all 0.2s;
}

.prediction-group-row.winning {
    background: #dbeafe;
    border-color: #93c5fd;
    box-shadow: 0 1px 3px rgba(59, 130, 246, 0.2);
}

.prediction-group-row:not(.winning) {
    background: #f8fafc;
}

.prediction-group-row:not(.winning):hover {
    border-color: #bfdbfe;
}

.prediction-group-balls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.25rem;
}

.prediction-group-strategy {
    font-weight: 700;
    font-size: 10px;
    color: #64748b;
    text-transform: uppercase;
    /* width: 64px; */
    flex-shrink: 0;
}

.prediction-group-balls-list {
    display: flex;
    gap: 0.375rem;
}

.mini-ball {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.8rem;
    color: #000000;
    transition: all 0.2s;
    background-image: url(../images/ball_grey_tool.png);
    background-repeat: no-repeat;
    background-size: 100%;
    background-position: center;
    padding-bottom: 3px;
    padding-left: 1px;
}
.mini-ball.red {
    background-image: url(../images/ball_red_tool.png);
    color: #000000;
}

.mini-ball.blue {
    background-image: url(../images/ball_blue_tool.png);
    color: #000000;
}
.mini-ball.green {
    background-image: url(../images/ball_green_tool.png);
    color: #000000;
}
.mini-ball-text{
    width: 100%;
    text-align: center;
    font-size: 0.75rem;
    color: #000000;
    padding: 4px 0;
}
.mini-ball-text.hit{
    color: #dc2626;
}

.prediction-group-stats {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    justify-content: flex-end;
    padding-left: 0.25rem;
}

.stat-item {
    display: flex;
    align-items: baseline;
    gap: 0.25rem;
}

.stat-value {
    font-weight: 800;
    font-size: 0.875rem;
}

.stat-value.has-hit {
    color: #2563eb;
}

.stat-value.no-hit {
    color: #cbd5e1;
}

.stat-value.blue-hit {
    color: #3b82f6;
}

.stat-label {
    font-size: 10px;
    color: #64748b;
}

.stat-divider {
    width: 1px;
    height: 12px;
    background: #e2e8f0;
}

/* History Table */
.history-table-container {
    background: #ffffff;
    border-radius: 1rem;
    border: 1px solid #e2e8f0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.history-table-scroll {
    overflow-x: auto;
}

.history-table {
    width: 100%;
    text-align: left;
    font-size: 0.875rem;
}

.history-table thead {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.history-table th {
    padding: 1rem 1.5rem;
    font-weight: 700;
    color: #475569;
    white-space: nowrap;
}

.history-table tbody tr {
    border-bottom: 1px solid #f1f5f9;
}

.history-table tr {
    transition: background-color 0.2s;
}

.history-table tbody tr:hover {
    background: #f1f5f9;
}

.history-table td {
    padding: 1rem 1.5rem;
    color: #1e293b;
}

.history-table .period-cell {
    font-weight: 700;
    color: #2563eb;
}

.history-table tbody tr:hover .period-cell {
    color: #3b82f6;
}

.history-table .date-cell {
    color: #64748b;
    font-family: 'Courier New', monospace;
}

.history-table .balls-cell {
    display: flex;
    gap: 0.375rem;
    transform: scale(0.9);
    transform-origin: left;
}

/* ==================== Chart Container ==================== */
.chart-container {
    background: #ffffff;
    border-radius: 1rem;
    border: 1px solid #e2e8f0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.chart-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.chart-icon {
    color: #60a5fa;
}

.chart-icon svg {
    width: 20px;
    height: 20px;
}

.chart-title-wrapper h3 {
    font-weight: 700;
    color: #1e293b;
    font-size: 1.125rem;
}

.chart-description {
    font-size: 0.75rem;
    color: #64748b;
}

.chart-canvas {
    height: 350px;
    width: 100%;
}

/* ==================== Footer ==================== */
.footer {
    position: relative;
    z-index: 10;
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
    padding: 2.5rem 0;
    margin-bottom: 64px;
}

@media (min-width: 768px) {
    .footer {
        margin-bottom: 0;
    }
}

.footer-content {
    max-width: 1152px;
    margin: 0 auto;
    padding: 0 1rem;
    text-align: center;
}

.footer-copyright {
    color: #1e293b;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

.footer-disclaimer {
    font-size: 0.75rem;
    color: #64748b;
}

/* ==================== Disclaimer Card ==================== */
.disclaimer-card {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: #1e40af;
    font-size: 0.75rem;
    margin-top: 2rem;
    background: #dbeafe;
    padding: 0.75rem;
    border-radius: 0.5rem;
    border: 1px solid #93c5fd;
}

.disclaimer-card svg {
    width: 14px;
    height: 14px;
}

/* ==================== Drawn Status Banner ==================== */
.drawn-status-banner {
    background: #ffffff;
    border-left: 4px solid #22c55e;
    border-radius: 0 0.75rem 0.75rem 0;
    padding: 1.25rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    grid-column: 1 / -1; /* 跨越所有列 */
    animation: slideIn 0.5s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.drawn-status-icon {
    background: #d1fae5;
    padding: 0.5rem;
    border-radius: 9999px;
    color: #059669;
    flex-shrink: 0;
}

.drawn-status-icon svg {
    width: 20px;
    height: 20px;
}

.drawn-status-content {
    flex: 1;
}

.drawn-status-title {
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.25rem;
    font-size: 1rem;
}

.drawn-status-subtitle {
    font-size: 0.875rem;
    color: #64748b;
}

.drawn-status-balls {
    display: flex;
    gap: 0.375rem;
    flex-wrap: wrap;
    align-items: center;
}

.mini-result-ball {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.8rem;
    color: #000;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
    background-image: url(../images/ball_grey_tool.png);
    background-repeat: no-repeat;
    background-size: 100%;
    background-position: center;
    padding-bottom: 3px;
    padding-left: 1px;
}
.mini-ball-divider{
    align-self: center;
    font-size: 1.8rem;
    height: 28px;
    line-height: 24px;
    color: #959595;
}
.mini-result-ball.red {
    background-image: url(../images/ball_red_tool.png);
    color: #000000;
}

.mini-result-ball.blue {
    background-image: url(../images/ball_blue_tool.png);
    color: #000000;
}
.mini-result-ball.green {
    background-image: url(../images/ball_green_tool.png);
    color: #000000;
}


/* ==================== Model Card Enhancements ==================== */
.model-card-header-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    z-index: 10;
}
.model-buttons{
    display: flex;
    align-items: center;
    justify-content: center;
    padding-bottom: 1.25rem;
}
.model-card-button-more{
    width: 10rem;
    height: 2.5rem;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius:  2.5rem;
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.5);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.model-card-button-more:hover {
    transform: scale(1.03);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.6);
}
.model-card-button-more-icon{
    width: 0;
    height: 0;
    border: 6px solid;
    margin-left: 5px;
    border-color: transparent transparent transparent #fff;
}

.model-best-hit-badge {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    border: 1px solid #3b82f6;
    padding: 0.375rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.4);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 2px 4px rgba(251, 191, 36, 0.3);
    }
    50% {
        box-shadow: 0 4px 8px rgba(251, 191, 36, 0.5);
    }
}
@keyframes loadingCircle {
    100% {
        -webkit-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}

.model-best-hit-badge svg {
    width: 14px;
    height: 14px;
    color: #f59e0b;
}

/* ==================== Strategy Group Enhancements ==================== */
.strategy-group-badge.best {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    border-color: #3b82f6;
    color: #ffffff;
    box-shadow: 0 0 10px rgba(37, 99, 235, 0.4);
}

.strategy-hit-stats {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    margin-left: auto;
}

.hit-stat {
    padding: 0.25rem 0.5rem;
    border-radius: 0.375rem;
    font-size: 0.75rem;
    font-weight: 700;
    border: 1px solid;
}

.hit-stat.red {
    background: rgba(220, 38, 38, 0.3);
    border-color: rgba(248, 113, 113, 0.5);
    color: #fca5a5;
}

.hit-stat.blue {
    background: rgba(37, 99, 235, 0.3);
    border-color: rgba(96, 165, 250, 0.5);
    color: #93c5fd;
}

.hit-stat.miss {
    background: rgba(30, 58, 138, 0.5);
    border-color: rgba(59, 130, 246, 0.3);
    color: #93c5fd;
}

/* ==================== Analysis Page Enhancements ==================== */
/* Prize Rules Card */
.prize-rules-card {
    background: #ffffff;
    border-radius: 0.75rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
    overflow: hidden;
}

.prize-rules-header {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid #e2e8f0;
}

.prize-rules-icon {
    background: rgba(255, 255, 255, 0.95);
    padding: 0.5rem;
    border-radius: 9999px;
    color: #2563eb;
    flex-shrink: 0;
}

.prize-rules-icon svg {
    width: 20px;
    height: 20px;
}

.prize-rules-header h3 {
    font-weight: 700;
    color: #ffffff;
    font-size: 1.125rem;
}

.prize-rules-content {
    padding: 1.5rem;
}

.prize-rules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.prize-rule-item {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    padding: 1rem;
    transition: all 0.3s ease;
}

.prize-rule-item:hover {
    border-color: #bfdbfe;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
    transform: translateY(-2px);
}

.prize-level {
    font-size: 0.875rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.prize-condition {
    font-size: 1.25rem;
    font-weight: 800;
    color: #2563eb;
    margin-bottom: 0.375rem;
}

.prize-desc {
    font-size: 0.75rem;
    color: #64748b;
}

.prize-rules-note {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    background: #eff6ff;
    padding: 1rem;
    border-radius: 0.5rem;
    border-left: 4px solid #3b82f6;
}

.prize-rules-note svg {
    width: 18px;
    height: 18px;
    color: #60a5fa;
    flex-shrink: 0;
    margin-top: 0.125rem;
}

.prize-rules-note span {
    font-size: 0.875rem;
    color: #1e40af;
    line-height: 1.5;
}

/* Statistics Cards Grid */
.stats-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: #ffffff;
    border-radius: 0.75rem;
    padding: 1.25rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all 0.3s ease;
}

.stat-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.stat-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-card-icon svg {
    width: 24px;
    height: 24px;
    color: white;
}

.stat-card-icon.red {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
}

.stat-card-icon.blue {
    background: linear-gradient(135deg, var(--blue-500), var(--blue-600));
}

.stat-card-icon.purple {
    background: linear-gradient(135deg, #a855f7, #9333ea);
}

.stat-card-icon.yellow {
    background: linear-gradient(135deg, #facc15, #f59e0b);
}

.stat-card-content {
    flex: 1;
}

.stat-card-label {
    font-size: 0.75rem;
    color: #64748b;
    margin-bottom: 0.25rem;
}

.stat-card-value {
    font-size: 1.5rem;
    font-weight: 800;
    color: #1e293b;
}

/* Analysis Charts Grid */
.analysis-charts-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .analysis-charts-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .analysis-charts-grid .chart-container.full-width {
        grid-column: 1 / -1;
    }
}

/* ==================== Responsive Design ==================== */
@media (min-width: 640px) {
    .strategy-header {
        flex-direction: row;
        align-items: center;
    }

    .prediction-group-row {
        flex-direction: row;
        align-items: center;
    }

    .prediction-group-balls {
        margin-bottom: 0;
    }

    .prediction-group-stats {
        padding-left: 0;
    }
}

/* ==================== Utilities ==================== */
.hidden {
    display: none !important;
}

.scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.scrollbar-hide::-webkit-scrollbar {
    display: none;
}

/* Icons - Using inline SVG data URLs for simplicity */
.icon-layout-dashboard {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect width="7" height="9" x="3" y="3" rx="1"/><rect width="7" height="5" x="14" y="3" rx="1"/><rect width="7" height="9" x="14" y="12" rx="1"/><rect width="7" height="5" x="3" y="16" rx="1"/></svg>');
}
.more-view{
    display: flex;
    align-items: center;
    justify-content: center;
}
.load-more{
    width: 10rem;
    height: 2.5rem;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 2.5rem;
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.5);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.load-more:hover {
    transform: scale(1.03);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.6);
}
a {
    text-decoration: none;
    /* color: #fff; */
}
.load-more-loading{
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    height: 2.5rem;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 2.5rem;
    color: #fff;
    padding: 0 8px;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.5);
}
.load-more-loading.hide,.load-more.hide,.more-view.hide{
    display: none;
}
.load-more-loading svg{
    animation: loadingCircle 1s infinite linear;
}

