/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Cairo', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
    direction: rtl;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Header Styles - Matching Nafezly */
.header {
    background: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid #e9ecef;
}

.nav-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 0;
    position: relative;
}

.logo {
    display: flex;
    align-items: center;
}

.logo-img {
    height: 35px;
    width: auto;
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    padding: 20px;
    min-width: 600px;
    max-height: 70vh;
    overflow-y: auto;
    z-index: 9999;
}

.nav.show {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.5rem;
}

.nav-section h3 {
    color: #495057;
    margin-bottom: 0.8rem;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.nav-section ul {
    list-style: none;
}

.nav-section li {
    margin-bottom: 0.3rem;
}

.nav-section a {
    text-decoration: none;
    color: #6c757d;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.6rem;
    border-radius: 6px;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.nav-section a:hover,
.nav-section a.active {
    background-color: #f8f9fa;
    color: #007bff;
}

.nav-section i {
    font-size: 0.8rem;
    width: 16px;
}

.lang-btn {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    color: #495057;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
}

.lang-btn:hover {
    background: #e9ecef;
}

.menu-btn {
    display: flex;
    align-items: center;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    color: #495057;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    gap: 0.5rem;
    transition: all 0.2s ease;
}

.menu-btn:hover {
    background: #e9ecef;
}

/* Main Content */
.main {
    padding: 1.5rem 0;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    font-size: 0.85rem;
    color: #6c757d;
}

.breadcrumb a {
    color: #007bff;
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb i {
    font-size: 0.7rem;
}

.hero {
    text-align: center;
    margin-bottom: 2rem;
}

.hero h1 {
    font-size: 2.2rem;
    color: #212529;
    margin-bottom: 0.8rem;
    font-weight: 700;
}

.hero-description {
    font-size: 1.1rem;
    color: #6c757d;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.5;
}

/* Color Controls Section */
.color-controls {
    margin-bottom: 2rem;
}

.controls-card {
    background: white;
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    border: 1px solid #dee2e6;
}

.controls-header {
    margin-bottom: 1.5rem;
}

.controls-header h2 {
    color: #495057;
    font-size: 1.3rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.controls-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.2rem;
    align-items: end;
}

.control-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.control-group label {
    font-weight: 600;
    color: #495057;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.control-group input,
.control-group select {
    padding: 0.8rem;
    border: 2px solid #dee2e6;
    border-radius: 6px;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    background: white;
}

.control-group input:focus,
.control-group select:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.view-mode-buttons {
    display: flex;
    gap: 0.5rem;
}

.view-mode-btn {
    flex: 1;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    color: #6c757d;
    padding: 0.6rem 0.8rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
}

.view-mode-btn:hover {
    background: #e9ecef;
    border-color: #007bff;
}

.view-mode-btn.active {
    background: #007bff;
    color: white;
    border-color: #007bff;
}

.color-stats {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.8rem;
    background: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #e9ecef;
}

.stats-label {
    color: #6c757d;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stats-count {
    color: #007bff;
    font-weight: 600;
    font-size: 0.9rem;
}

.btn-export {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    border: none;
    padding: 0.8rem 1.2rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-export:hover {
    background: linear-gradient(135deg, #218838, #1ea080);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

/* Selected Color Display */
.selected-color {
    margin-bottom: 2rem;
}

.selected-card {
    background: white;
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    border: 1px solid #dee2e6;
    display: grid;
    grid-template-columns: 150px 1fr auto;
    gap: 1.5rem;
    align-items: center;
}

.selected-preview {
    width: 150px;
    height: 150px;
    border-radius: 10px;
    border: 2px solid #dee2e6;
    position: relative;
    overflow: hidden;
}

.selected-info {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.selected-info h3 {
    color: #495057;
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.color-value {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0.8rem;
    background: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #e9ecef;
    font-family: monospace;
    font-size: 0.9rem;
}

.color-value-label {
    color: #6c757d;
    font-weight: 600;
}

.color-value-code {
    color: #495057;
    font-weight: 500;
}

.selected-actions {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.btn-copy,
.btn-palette {
    background: #007bff;
    color: white;
    border: none;
    padding: 0.6rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
}

.btn-copy:hover {
    background: #0056b3;
}

.btn-palette {
    background: #28a745;
}

.btn-palette:hover {
    background: #1e7e34;
}

/* Colors Section */
.colors-section {
    margin-bottom: 2rem;
}

.colors-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding: 0 0.5rem;
}

.colors-header h2 {
    color: #495057;
    font-size: 1.5rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.colors-actions {
    display: flex;
    gap: 0.8rem;
}

.btn-shuffle,
.btn-favorites {
    background: #6c757d;
    color: white;
    border: none;
    padding: 0.6rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-shuffle:hover {
    background: #545b62;
}

.btn-favorites {
    background: #dc3545;
}

.btn-favorites:hover {
    background: #c82333;
}

.btn-favorites.active {
    background: #28a745;
}

/* Colors Grid */
.colors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
}

.colors-grid.list-view {
    grid-template-columns: 1fr;
    gap: 0.5rem;
}

.colors-grid.compact-view {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 0.5rem;
}

.color-item {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: all 0.2s ease;
    cursor: pointer;
    border: 2px solid transparent;
    position: relative;
}

.color-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
    border-color: #007bff;
}

.color-item.selected {
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.2);
}

.color-preview {
    height: 120px;
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.colors-grid.compact-view .color-preview {
    height: 80px;
}

.colors-grid.list-view .color-item {
    display: grid;
    grid-template-columns: 80px 1fr auto;
    align-items: center;
    gap: 1rem;
    padding: 0;
}

.colors-grid.list-view .color-preview {
    height: 60px;
    width: 80px;
    border-radius: 6px;
    margin: 0.5rem;
}

.color-info {
    padding: 0.8rem;
    text-align: center;
}

.colors-grid.list-view .color-info {
    text-align: right;
    padding: 0;
}

.color-name {
    font-weight: 600;
    color: #495057;
    font-size: 0.9rem;
    margin-bottom: 0.3rem;
}

.color-hex {
    font-family: monospace;
    color: #6c757d;
    font-size: 0.8rem;
    background: #f8f9fa;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    display: inline-block;
}

.color-actions {
    padding: 0.5rem;
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    border-top: 1px solid #f1f3f4;
}

.colors-grid.list-view .color-actions {
    border: none;
    padding: 0.5rem;
}

.colors-grid.compact-view .color-actions {
    padding: 0.3rem;
}

.color-action-btn {
    background: transparent;
    border: 1px solid #dee2e6;
    color: #6c757d;
    width: 28px;
    height: 28px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}

.color-action-btn:hover {
    background: #f8f9fa;
    border-color: #007bff;
    color: #007bff;
}

.color-action-btn.favorited {
    background: #dc3545;
    border-color: #dc3545;
    color: white;
}

.favorite-icon {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    width: 24px;
    height: 24px;
    background: rgba(220, 53, 69, 0.9);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    opacity: 0;
    transform: scale(0);
    transition: all 0.2s ease;
}

.color-item.favorited .favorite-icon {
    opacity: 1;
    transform: scale(1);
}

/* Custom Palette */
.custom-palette {
    margin-bottom: 2rem;
}

.palette-card {
    background: white;
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    border: 1px solid #dee2e6;
}

.palette-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.palette-header h3 {
    color: #495057;
    font-size: 1.2rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.palette-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-clear-palette,
.btn-export-palette {
    background: #6c757d;
    color: white;
    border: none;
    padding: 0.5rem 0.8rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.btn-clear-palette {
    background: #dc3545;
}

.btn-clear-palette:hover {
    background: #c82333;
}

.btn-export-palette:hover {
    background: #545b62;
}

.palette-colors {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    gap: 0.5rem;
    min-height: 80px;
    border: 2px dashed #dee2e6;
    border-radius: 6px;
    padding: 0.8rem;
    align-items: center;
}

.palette-colors.empty {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6c757d;
    font-size: 0.9rem;
}

.palette-color {
    height: 60px;
    border-radius: 6px;
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid rgba(255,255,255,0.2);
}

.palette-color:hover {
    transform: scale(1.05);
    border-color: #007bff;
}

.palette-color-remove {
    position: absolute;
    top: -5px;
    right: -5px;
    width: 18px;
    height: 18px;
    background: #dc3545;
    color: white;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    font-size: 0.7rem;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.palette-color:hover .palette-color-remove {
    opacity: 1;
}

/* Color Harmony Generator */
.harmony-section {
    margin-bottom: 2rem;
}

.harmony-card {
    background: white;
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    border: 1px solid #dee2e6;
}

.harmony-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.harmony-header h3 {
    color: #495057;
    font-size: 1.3rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.harmony-header p {
    color: #6c757d;
    font-size: 0.95rem;
}

.harmony-controls {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 1.5rem;
    align-items: center;
    margin-bottom: 1.5rem;
}

.base-color-picker {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.8rem;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.base-color-picker label {
    font-weight: 600;
    color: #495057;
    font-size: 0.9rem;
    white-space: nowrap;
}

.base-color-picker input[type="color"] {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    background: none;
}

.base-color-picker input[type="text"] {
    width: 100px;
    padding: 0.5rem;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.85rem;
    text-align: center;
    background: white;
}

.harmony-types {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.harmony-btn {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    color: #6c757d;
    padding: 0.6rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
    white-space: nowrap;
}

.harmony-btn:hover {
    background: #e9ecef;
    border-color: #007bff;
}

.harmony-btn.active {
    background: #007bff;
    color: white;
    border-color: #007bff;
}

.harmony-result {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 1rem;
    min-height: 120px;
    align-items: center;
}

.harmony-color {
    text-align: center;
}

.harmony-color-preview {
    height: 80px;
    width: 100%;
    border-radius: 8px;
    margin-bottom: 0.5rem;
    border: 2px solid rgba(255,255,255,0.2);
    cursor: pointer;
    transition: all 0.2s ease;
}

.harmony-color-preview:hover {
    transform: translateY(-2px);
    border-color: #007bff;
}

.harmony-color-info {
    font-size: 0.8rem;
    color: #6c757d;
    font-family: monospace;
}

/* Info Section - Two Column Layout */
.info-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.info-section .info-card,
.about-card {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border: 1px solid #dee2e6;
}

.info-section .info-card h2,
.about-card h2 {
    color: #495057;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.1rem;
    font-weight: 600;
}

.info-section .info-card i {
    color: #007bff;
}

.info-section .info-card p,
.about-card p {
    color: #6c757d;
    line-height: 1.7;
    font-size: 0.95rem;
}

/* Color Guide */
.color-guide {
    margin-bottom: 2.5rem;
}

.color-guide h2 {
    text-align: center;
    color: #495057;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    font-weight: 600;
}

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

.guide-card {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    text-align: center;
    border: 1px solid #dee2e6;
    transition: all 0.2s ease;
}

.guide-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-color: #007bff;
}

.guide-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    margin-bottom: 1rem;
}

.guide-header i {
    font-size: 2rem;
    color: #007bff;
}

.guide-header h3 {
    color: #495057;
    font-size: 1.1rem;
    font-weight: 600;
}

.guide-card p {
    color: #6c757d;
    line-height: 1.6;
    font-size: 0.9rem;
}

/* Popular Tools */
.popular-tools {
    margin-bottom: 2rem;
}

.popular-tools h2 {
    text-align: center;
    color: #495057;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    font-weight: 600;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
}

.tool-card {
    background: white;
    padding: 1.2rem;
    border-radius: 6px;
    text-align: center;
    text-decoration: none;
    color: #6c757d;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border: 1px solid #dee2e6;
}

.tool-card:hover,
.tool-card.active {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    color: #007bff;
}

.tool-card i {
    font-size: 1.8rem;
    margin-bottom: 0.8rem;
    color: #007bff;
}

.tool-card span {
    display: block;
    font-weight: 500;
    font-size: 0.9rem;
}

/* Footer */
.footer {
    background: #f8f9fa;
    border-top: 1px solid #dee2e6;
    padding: 2rem 0 1rem;
    margin-top: 2rem;
}

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

.footer-section h3 {
    margin-bottom: 0.8rem;
    color: #495057;
    font-size: 1rem;
    font-weight: 600;
}

.footer-logo {
    height: 35px;
    margin-bottom: 0.8rem;
}

.footer-section p {
    color: #6c757d;
    font-size: 0.9rem;
}

.social-links {
    display: flex;
    gap: 0.8rem;
}

.social-links a {
    display: inline-block;
    width: 35px;
    height: 35px;
    background: #e9ecef;
    border-radius: 6px;
    text-align: center;
    line-height: 35px;
    color: #6c757d;
    text-decoration: none;
    transition: all 0.2s ease;
}

.social-links a:hover {
    background: #007bff;
    color: white;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.4rem;
}

.footer-section ul a {
    color: #6c757d;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.footer-section ul a:hover {
    color: #007bff;
}

.footer-bottom {
    text-align: center;
    padding-top: 1rem;
    border-top: 1px solid #dee2e6;
    color: #6c757d;
    font-size: 0.85rem;
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.3s ease-in;
}

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

/* Copy success animation */
@keyframes copySuccess {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.btn-copy.copied {
    animation: copySuccess 0.3s ease;
    background: #28a745 !important;
}

/* Color selection animation */
@keyframes colorSelect {
    0% { transform: scale(1); }
    50% { transform: scale(0.95); }
    100% { transform: scale(1); }
}

.color-item.selecting {
    animation: colorSelect 0.2s ease;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav {
        min-width: 280px;
        grid-template-columns: 1fr;
    }

    .hero h1 {
        font-size: 1.8rem;
    }

    .controls-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .view-mode-buttons {
        grid-template-columns: repeat(3, 1fr);
    }

    .selected-card {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 1rem;
    }

    .selected-preview {
        width: 100%;
        max-width: 200px;
        justify-self: center;
    }

    .selected-actions {
        flex-direction: row;
        justify-content: center;
        flex-wrap: wrap;
    }

    .colors-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .colors-actions {
        justify-content: center;
    }

    .colors-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .colors-grid.compact-view {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }

    .harmony-controls {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .harmony-types {
        justify-content: center;
    }

    .base-color-picker {
        justify-content: center;
    }

    .palette-colors {
        grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
    }

    .info-section {
        grid-template-columns: 1fr;
    }

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

    .tools-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 10px;
    }

    .hero h1 {
        font-size: 1.6rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .controls-card,
    .selected-card,
    .harmony-card,
    .palette-card {
        padding: 1rem;
    }

    .colors-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 0.8rem;
    }

    .color-preview {
        height: 100px;
    }

    .selected-preview {
        height: 120px;
    }

    .harmony-result {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    }

    .harmony-color-preview {
        height: 60px;
    }

    .palette-colors {
        grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
    }

    .palette-color {
        height: 40px;
    }

    .guide-grid {
        gap: 1rem;
    }
}

/* Additional utility classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.text-muted { color: #6c757d; }
.d-none { display: none; }
.d-block { display: block; }
.d-flex { display: flex; }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }

/* Loading animation */
.loading {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}