/* Tailwind CSS 自定义版本 - 为qd.html提取的必要样式 */

/* Reset & Base */
*, ::before, ::after {
    box-sizing: border-box;
    border-width: 0;
    border-style: solid;
    border-color: #e5e7eb;
}

body {
    margin: 0;
    line-height: inherit;
}

/* Layout */
.min-h-screen {
    min-height: 100vh;
}

.max-w-5xl {
    max-width: 64rem;
}

.mx-auto {
    margin-left: auto;
    margin-right: auto;
}

/* Spacing */
.py-8 {
    padding-top: 2rem;
    padding-bottom: 2rem;
}

.px-4 {
    padding-left: 1rem;
    padding-right: 1rem;
}

.p-6 {
    padding: 1.5rem;
}

.p-8 {
    padding: 2rem;
}

.p-12 {
    padding: 3rem;
}

.p-4 {
    padding: 1rem;
}

.px-3 {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

.py-1 {
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
}

.mb-8 {
    margin-bottom: 2rem;
}

.mb-6 {
    margin-bottom: 1.5rem;
}

.mb-4 {
    margin-bottom: 1rem;
}

.mb-3 {
    margin-bottom: 0.75rem;
}

.mb-2 {
    margin-bottom: 0.5rem;
}

.mt-8 {
    margin-top: 2rem;
}

.mt-3 {
    margin-top: 0.75rem;
}

.mt-2 {
    margin-top: 0.5rem;
}

.mr-3 {
    margin-right: 0.75rem;
}

.mr-2 {
    margin-right: 0.5rem;
}

/* Display */
.flex {
    display: flex;
}

.grid {
    display: grid;
}

.hidden {
    display: none;
}

.inline-block {
    display: inline-block;
}

/* Flexbox */
.flex-col {
    flex-direction: column;
}

.flex-row {
    flex-direction: row;
}

.items-center {
    align-items: center;
}

.justify-between {
    justify-content: space-between;
}

.gap-3 {
    gap: 0.75rem;
}

.gap-4 {
    gap: 1rem;
}

.gap-6 {
    gap: 1.5rem;
}

.self-center {
    align-self: center;
}

/* Grid */
.grid-cols-1 {
    grid-template-columns: repeat(1, minmax(0, 1fr));
}

.grid-cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.col-span-2 {
    grid-column: span 2 / span 2;
}

.col-span-4 {
    grid-column: span 4 / span 4;
}

/* Typography */
.text-center {
    text-align: center;
}

.text-lg {
    font-size: 1.125rem;
    line-height: 1.75rem;
}

.text-xl {
    font-size: 1.25rem;
    line-height: 1.75rem;
}

.text-2xl {
    font-size: 1.5rem;
    line-height: 2rem;
}

.text-sm {
    font-size: 0.875rem;
    line-height: 1.25rem;
}

.font-bold {
    font-weight: 700;
}

.font-medium {
    font-weight: 500;
}

.font-sans {
    font-family: Inter, system-ui, sans-serif;
}

.leading-relaxed {
    line-height: 1.625;
}

/* Colors - Background */
.bg-neutral {
    background-color: #f3f4f6;
}

.bg-white {
    background-color: #ffffff;
}

.bg-primary\/10 {
    background-color: rgba(30, 64, 175, 0.1);
}

.bg-secondary\/10 {
    background-color: rgba(217, 119, 6, 0.1);
}

.bg-white\/10 {
    background-color: rgba(255, 255, 255, 0.1);
}

.bg-gradient-to-r {
    background-image: linear-gradient(to right, var(--tw-gradient-stops));
}

.from-primary {
    --tw-gradient-from: #1e40af;
    --tw-gradient-to: rgba(30, 64, 175, 0);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to);
}

.to-secondary {
    --tw-gradient-to: #d97706;
}

/* Colors - Text */
.text-primary {
    color: #1e40af;
}

.text-secondary {
    color: #d97706;
}

.text-dark {
    color: #1f2937;
}

.text-dark\/70 {
    color: rgba(31, 41, 55, 0.7);
}

.text-dark\/80 {
    color: rgba(31, 41, 55, 0.8);
}

.text-dark\/50 {
    color: rgba(31, 41, 55, 0.5);
}

.text-white {
    color: #ffffff;
}

.text-primary\/90 {
    color: rgba(30, 64, 175, 0.9);
}

/* Borders */
.rounded-2xl {
    border-radius: 1rem;
}

.rounded-xl {
    border-radius: 0.75rem;
}

.rounded-full {
    border-radius: 9999px;
}

.border-t {
    border-top-width: 1px;
}

.border-b-2 {
    border-bottom-width: 2px;
}

.border-l-4 {
    border-left-width: 4px;
}

.border-2 {
    border-width: 2px;
}

.border-gray-200 {
    border-color: #e5e7eb;
}

.border-secondary {
    border-color: #d97706;
}

.border-white {
    border-color: #ffffff;
}

.border-primary {
    border-color: #1e40af;
}

.pl-4 {
    padding-left: 1rem;
}

.pt-4 {
    padding-top: 1rem;
}

/* Effects */
.card-shadow {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.card-hover {
    transition: all 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.backdrop-blur-sm {
    backdrop-filter: blur(4px);
}

/* Sizing */
.w-8 {
    width: 2rem;
}

.h-8 {
    height: 2rem;
}

.h-12 {
    height: 3rem;
}

.w-12 {
    width: 3rem;
}

/* Custom animations */
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.animate-spin {
    animation: spin 1s linear infinite;
}

/* Star active color */
.star-active {
    color: #fbbf24;
}

/* Responsive */
@media (min-width: 640px) {
    .sm\:px-6 {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
    
    .sm\:p-8 {
        padding: 2rem;
    }
    
    .sm\:flex-row {
        flex-direction: row;
    }
    
    .sm\:mb-0 {
        margin-bottom: 0;
    }
    
    .sm\:grid-cols-2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    
    .sm\:col-span-2 {
        grid-column: span 2 / span 2;
    }
}

@media (min-width: 768px) {
    .md\:grid-cols-2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    
    .md\:grid-cols-4 {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
    
    .md\:col-span-2 {
        grid-column: span 2 / span 2;
    }
}

@media (min-width: 1024px) {
    .lg\:px-8 {
        padding-left: 2rem;
        padding-right: 2rem;
    }
    
    .lg\:grid-cols-3 {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
    
    .lg\:col-span-3 {
        grid-column: span 3 / span 3;
    }
}

/* Clamp for title */
.text-\[clamp\(1\.8rem\,4vw\,2\.5rem\)\] {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
}

/* Custom color variables */
:root {
    --color-primary: #1e40af;
    --color-secondary: #d97706;
    --color-neutral: #f3f4f6;
    --color-dark: #1f2937;
}

/* 回到顶部按钮 */
.back-to-top-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #1e40af 0%, #d97706 100%);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
}

.back-to-top-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.back-to-top-btn:active {
    transform: translateY(-2px);
}

.back-to-top-btn.show {
    opacity: 1;
    visibility: visible;
}

@media (max-width: 640px) {
    .back-to-top-btn {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
}