:root {
    --primary-color: #5774d4;
    --bg-color: #f8fafc;
    --card-bg: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --radius: 12px;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-sans);
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.site-header {
    background: #fff;
    padding: 15px 0;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 40px;
}

.return-button {
    display: inline-block;
    padding: 8px 16px;
    background: var(--bg-color);
    color: var(--text-main);
    text-decoration: none;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s;
    border: 1px solid var(--border-color);
}

.return-button:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Tool Section */
.tool-title {
    font-size: 2.5rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 10px;
    color: var(--text-main);
}

.tool-subtitle {
    text-align: center;
    color: var(--text-muted);
    margin-bottom: 40px;
}

.color-picker-app {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 30px;
    display: grid;
    gap: 30px;
}

.display-area {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 20px;
    height: 300px;
}

.preview-tile {
    background-color: var(--primary-color);
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
}

.gradient-area {
    position: relative;
    border-radius: var(--radius);
    cursor: crosshair;
    overflow: hidden;
    background: linear-gradient(to top, #000, transparent),
        linear-gradient(to right, #fff, var(--primary-color));
}

.cursor {
    position: absolute;
    width: 14px;
    height: 14px;
    border: 2px solid white;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.5);
}

/* Controls */
.slider-container {
    margin: 20px 0;
}

.hue-slider {
    width: 100%;
    height: 24px;
    -webkit-appearance: none;
    appearance: none;
    background: linear-gradient(to right,
            #ff0000 0%, #ffff00 17%, #00ff00 33%,
            #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%);
    border-radius: 12px;
    outline: none;
}

.hue-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 24px;
    height: 24px;
    background: #fff;
    border: 3px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    border-radius: 50%;
    cursor: pointer;
}

/* Values Grid */
.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 15px;
}

.value-card {
    background: var(--bg-color);
    padding: 15px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
}

.value-card label {
    display: block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 5px;
}

.value-display {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: var(--font-mono);
    font-size: 0.95rem;
}

.copy-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    color: var(--text-muted);
    transition: color 0.2s;
    display: flex;
    align-items: center;
}

.copy-btn:hover {
    color: var(--primary-color);
}

.copy-btn svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

/* SEO Content */
.content-section {
    padding: 80px 0;
}

.seo-article {
    max-width: 800px;
    margin: 0 auto;
}

.seo-article h2 {
    font-size: 2.25rem;
    font-weight: 800;
    margin: 40px 0 20px;
    color: var(--text-main);
}

.seo-article h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 30px 0 15px;
    color: var(--text-main);
}

.seo-article p {
    margin-bottom: 20px;
    color: var(--text-muted);
    font-size: 1.1rem;
}

.seo-article ul,
.seo-article ol {
    margin-bottom: 30px;
    padding-left: 20px;
}

.seo-article li {
    margin-bottom: 10px;
    color: var(--text-muted);
}

.seo-article a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

.seo-article a:hover {
    text-decoration: underline;
}

.seo-article img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius);
    margin: 40px 0;
    box-shadow: var(--shadow);
}

.aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* Table Styles */
.table-container {
    overflow-x: auto;
    margin: 30px 0;
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow);
}

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

th,
td {
    padding: 15px 20px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

th {
    background: var(--bg-color);
    font-weight: 700;
    color: var(--text-main);
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.05em;
}

tr:last-child td {
    border-bottom: none;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin: 30px 0;
}

.callout {
    background: #eff6ff;
    padding: 25px;
    border-radius: var(--radius);
    border-left: 4px solid var(--primary-color);
    margin: 40px 0;
}

.callout p {
    margin-bottom: 0;
    color: #1e40af;
}

/* Footer */
.site-footer {
    text-align: center;
    padding: 40px 0;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 600px) {
    .display-area {
        grid-template-columns: 1fr;
        height: auto;
    }

    .preview-tile {
        height: 60px;
    }

    .gradient-area {
        height: 200px;
    }

    .tool-title {
        font-size: 2rem;
    }

    .grid-2 {
        grid-template-columns: 1fr;
    }
}