/* Converter Wrapper */
.pantone-converter-wrapper {
    margin-bottom: 2rem;
}

.converter-card {
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

/* Converter Grid */
.converter-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    padding: 2rem;
}

@media (max-width: 991px) {
    .converter-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 1.5rem;
    }
}

@media (max-width: 767px) {
    .converter-grid {
        padding: 1rem;
        gap: 1rem;
    }
}

/* Input Panel */
.input-panel {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.panel-header {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.panel-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    flex-shrink: 0;
}

.panel-title-group {
    flex: 1;
}

.panel-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 0.25rem 0;
    color: #1a1a1a;
}

.panel-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0;
}

@media (max-width: 767px) {
    .panel-title {
        font-size: 1.25rem;
    }
    
    .panel-icon {
        width: 40px;
        height: 40px;
    }
}

/* Input Container */
.input-container {
    position: relative;
}

.pantone-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: #f9fafb;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    transition: all 0.2s ease;
}

.pantone-input-wrapper:focus-within {
    border-color: #667eea;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.input-prefix {
    padding: 0 1rem;
    font-weight: 600;
    color: #6b7280;
    font-size: 0.875rem;
    border-right: 1px solid #e5e7eb;
    white-space: nowrap;
}

.pantone-input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 1rem;
    font-size: 1rem;
    color: #1a1a1a;
    outline: none;
    
}

.pantone-input::placeholder {
    color: #9ca3af;
}

.input-clear {
    padding: 0.5rem;
    margin-right: 0.5rem;
    background: transparent;
    border: none;
    cursor: pointer;
    color: #9ca3af;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: all 0.2s ease;
    opacity: 0;
    pointer-events: none;
}

.pantone-input-wrapper:focus-within .input-clear,
.input-clear.visible {
    opacity: 1;
    pointer-events: all;
}

.input-clear:hover {
    background: #e5e7eb;
    color: #374151;
}

/* Pantone Suggestions */
.pantone-suggestions {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 0;
    right: 0;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
}

.pantone-suggestions.visible {
    display: block;
}

.pantone-suggestion {
    padding: 0.875rem 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: background 0.15s ease;
    border-bottom: 1px solid #f3f4f6;
}

.pantone-suggestion:last-child {
    border-bottom: none;
}

.pantone-suggestion:hover {
    background: #f9fafb;
}

.pantone-suggestion-color {
    width: 32px;
    height: 24px;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
    flex-shrink: 0;
}

.pantone-suggestion-info {
    flex: 1;
    min-width: 0;
}

.pantone-suggestion-code {
    font-weight: 600;
    font-size: 0.875rem;
    color: #1a1a1a;
    margin-bottom: 0.125rem;
}

.pantone-suggestion-name {
    font-size: 0.75rem;
    color: #6b7280;
}

/* Quick Actions */
.quick-actions {
    display: flex;
    gap: 0.75rem;
}

.action-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s ease;
}

.action-btn:hover {
    border-color: #667eea;
    color: #667eea;
    background: #f5f7ff;
}

.action-btn svg {
    flex-shrink: 0;
}

@media (max-width: 767px) {
    .action-btn span {
        display: none;
    }
    
    .action-btn {
        padding: 0.75rem;
    }
}

/* Preview Panel */
.preview-panel {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.color-display-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.color-preview {
    width: 100%;
    max-width: 280px;
    aspect-ratio: 1;
    border-radius: 20px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.color-preview::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        linear-gradient(45deg, #e5e7eb 25%, transparent 25%),
        linear-gradient(-45deg, #e5e7eb 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, #e5e7eb 75%),
        linear-gradient(-45deg, transparent 75%, #e5e7eb 75%);
    background-size: 16px 16px;
    background-position: 0 0, 0 8px, 8px -8px, -8px 0px;
    z-index: 1;
}

.color-fill {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    background-color: rgb(220, 38, 127);
    transition: background-color 0.3s ease;
}

.preview-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1.5rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6), transparent);
    z-index: 3;
}

.preview-text {
    color: #ffffff;
    
    font-size: 1.125rem;
    font-weight: 600;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

@media (max-width: 767px) {
    .color-preview {
        max-width: 100%;
    }
}

/* Accuracy Meter */
.accuracy-meter {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    padding: 1.25rem;
    color: #ffffff;
}

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

.accuracy-label {
    font-size: 0.875rem;
    font-weight: 600;
    opacity: 0.9;
}

.accuracy-value {
    font-size: 1.125rem;
    font-weight: 700;
}

.accuracy-bar {
    height: 8px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    overflow: hidden;
}

.accuracy-fill {
    height: 100%;
    background: #ffffff;
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 95%;
}

/* Output Panel */
.output-panel {
    padding: 2rem;
    border-top: 1px solid #e5e7eb;
    background: #f9fafb;
}

@media (max-width: 767px) {
    .output-panel {
        padding: 1.5rem 1rem;
    }
}

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

.output-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 0.25rem 0;
    color: #1a1a1a;
}

.output-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0;
}

/* RGB Display Grid */
.rgb-display-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

@media (max-width: 767px) {
    .rgb-display-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
}

.rgb-channel {
    background: #ffffff;
    border-radius: 12px;
    padding: 1.25rem;
    border: 1px solid #e5e7eb;
}

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

.channel-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.channel-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1a1a1a;
    
}

.channel-slider-wrapper {
    position: relative;
}

.channel-slider {
    width: 100%;
    height: 8px;
    border-radius: 4px;
    outline: none;
    -webkit-appearance: none;
    cursor: default;
    background: transparent;
}

.channel-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #ffffff;
    border: 2px solid rgba(0, 0, 0, 0.2);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
    cursor: pointer;
    margin-top: -8px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.channel-slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #ffffff;
    cursor: default;
    border: 2px solid currentColor;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: transform 0.2s ease;
}

.channel-slider::-webkit-slider-runnable-track {
    height: 8px;
    border-radius: 4px;
}

.channel-slider::-moz-range-track {
    height: 8px;
    border-radius: 4px;
}

.red-slider {
    color: #ef4444;
}

.red-slider::-webkit-slider-runnable-track {
    background: linear-gradient(to right, #000000 0%, #ef4444 100%);
}

.red-slider::-moz-range-track {
    background: linear-gradient(to right, #000000 0%, #ef4444 100%);
}

.green-slider {
    color: #10b981;
}

.green-slider::-webkit-slider-runnable-track {
    background: linear-gradient(to right, #000000 0%, #10b981 100%);
}

.green-slider::-moz-range-track {
    background: linear-gradient(to right, #000000 0%, #10b981 100%);
}

.blue-slider {
    color: #3b82f6;
}

.blue-slider::-webkit-slider-runnable-track {
    background: linear-gradient(to right, #000000 0%, #3b82f6 100%);
}

.blue-slider::-moz-range-track {
    background: linear-gradient(to right, #000000 0%, #3b82f6 100%);
}

/* Results Panel */
.results-panel {
    padding: 2rem;
    border-top: 1px solid #e5e7eb;
}

@media (max-width: 767px) {
    .results-panel {
        padding: 1.5rem 1rem;
    }
}

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

.results-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 0.25rem 0;
    color: #1a1a1a;
}

.results-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

@media (max-width: 991px) {
    .results-grid {
        grid-template-columns: 1fr;
    }
}

.result-item {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 1.25rem;
    transition: all 0.2s ease;
}

.result-item:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.1);
}

.result-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.75rem;
}

.result-value-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.result-value {
    flex: 1;
    
    font-size: 0.9375rem;
    color: #1a1a1a;
    background: #f9fafb;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    word-break: break-all;
}

.copy-btn {
    padding: 0.5rem;
    background: transparent;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    cursor: pointer;
    color: #6b7280;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.copy-btn:hover {
    background: #667eea;
    border-color: #667eea;
    color: #ffffff;
}

.copy-btn:active {
    transform: scale(0.95);
}

/* Popular Colors Panel */
.popular-colors-panel {
    padding: 2rem;
    border-top: 1px solid #e5e7eb;
    background: #f9fafb;
}

@media (max-width: 767px) {
    .popular-colors-panel {
        padding: 1.5rem 1rem;
    }
}

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

.popular-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 0.25rem 0;
    color: #1a1a1a;
}

.popular-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0;
}

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

@media (max-width: 767px) {
    .popular-colors-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
}

.popular-color-item {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.popular-color-item:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
    transform: translateY(-2px);
}

.popular-color-chip {
    width: 100%;
    height: 60px;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.popular-color-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.popular-color-code {
    font-size: 0.8125rem;
    font-weight: 600;
    color: #1a1a1a;
    
}

.popular-color-name {
    font-size: 0.75rem;
    color: #6b7280;
}

/* Info Section */
.info-section {
    margin-top: 4rem;
    padding: 3rem 0;
    background: #f9fafb;
}

@media (max-width: 767px) {
    .info-section {
        margin-top: 2rem;
        padding: 2rem 0;
    }
}

.info-content {
    max-width: 1200px;
    margin: 0 auto;
}

.info-title {
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 2rem 0;
    color: #1a1a1a;
    text-align: center;
}

@media (max-width: 767px) {
    .info-title {
        font-size: 1.5rem;
        margin-bottom: 1.5rem;
    }
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-bottom: 2rem;
}

@media (max-width: 991px) {
    .info-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

.info-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 2rem;
    border: 1px solid #e5e7eb;
}

.info-card-full {
    grid-column: 1 / -1;
}

@media (max-width: 991px) {
    .info-card-full {
        grid-column: 1;
    }
}

.info-card-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 1rem 0;
    color: #1a1a1a;
}

.info-card-subtitle {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 1.5rem 0 0.75rem 0;
    color: #374151;
}

.info-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.info-list li {
    padding: 0.5rem 0;
    color: #4b5563;
    line-height: 1.6;
    padding-left: 1.5rem;
    position: relative;
}

.info-list li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: #667eea;
    font-weight: bold;
}

.info-two-column {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 1.5rem;
}

@media (max-width: 767px) {
    .info-two-column {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .info-card {
        padding: 1.5rem;
    }
}
