/**
 * Branding Page Styles
 */

.branding-content {
    max-width: 900px;
}

.branding-section {
    background: var(--gray-800);
    border: 1px solid var(--gray-700);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
}

.branding-section h3 {
    font-size: 18px;
    font-weight: 600;
    color: #fff;
    margin: 0 0 8px 0;
}

.branding-section p {
    font-size: 14px;
    color: var(--gray-400);
    margin: 0 0 20px 0;
}

.color-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
}

.color-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.color-item label {
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-300);
}

.color-picker-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--gray-900);
    border: 1px solid var(--gray-700);
    border-radius: 8px;
    padding: 8px 12px;
}

.color-preview {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    border: 2px solid var(--gray-600);
    cursor: pointer;
}

.color-hex {
    flex: 1;
    background: transparent;
    border: none;
    color: #fff;
    font-family: monospace;
    font-size: 14px;
    width: 100%;
}

.color-hex:focus {
    outline: none;
}

.color-picker-input {
    position: absolute;
    opacity: 0;
    width: 40px;
    height: 40px;
    cursor: pointer;
}

.color-preview-container {
    position: relative;
}

.palette-section {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--gray-700);
}

.palette-section h4 {
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-300);
    margin: 0 0 12px 0;
}

.palette-colors {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.palette-color {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    border: 2px solid var(--gray-600);
    cursor: pointer;
    transition: all 0.2s ease;
}

.palette-color:hover {
    transform: scale(1.1);
}

.style-options {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 12px;
}

.style-option {
    background: var(--gray-900);
    border: 2px solid var(--gray-700);
    border-radius: 10px;
    padding: 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.style-option:hover {
    border-color: var(--gray-600);
}

.style-option.selected {
    border-color: var(--red-500);
    background: rgba(239, 68, 68, 0.1);
}

.style-option-icon {
    font-size: 24px;
    margin-bottom: 8px;
}

.style-option-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-300);
}

.image-recommendation {
    background: var(--gray-900);
    border: 1px solid var(--gray-700);
    border-radius: 8px;
    padding: 16px;
    margin-top: 20px;
}

.image-recommendation h4 {
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-300);
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.image-recommendation p {
    font-size: 13px;
    color: var(--gray-400);
    margin: 0;
    line-height: 1.6;
}

.image-recommendation textarea {
    width: 100%;
    background: var(--gray-800);
    border: 1px solid var(--gray-700);
    border-radius: 8px;
    padding: 12px;
    font-size: 13px;
    color: #fff;
    resize: vertical;
    min-height: 80px;
    margin-top: 12px;
    font-family: inherit;
}

.image-recommendation textarea:focus {
    outline: none;
    border-color: var(--red-500);
}

.branding-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.btn-save {
    background: linear-gradient(135deg, var(--red-500), var(--red-600));
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.btn-save:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.btn-save:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.btn-reanalyze {
    background: var(--gray-700);
    color: var(--gray-200);
    border: 1px solid var(--gray-600);
    border-radius: 8px;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.btn-reanalyze:hover {
    background: var(--gray-600);
}

.btn-reanalyze:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.no-branding {
    text-align: center;
    padding: 60px 20px;
}

.no-branding svg {
    color: var(--gray-500);
    margin-bottom: 16px;
}

.no-branding h3 {
    font-size: 18px;
    font-weight: 600;
    color: #fff;
    margin: 0 0 8px 0;
}

.no-branding p {
    font-size: 14px;
    color: var(--gray-400);
    margin: 0 0 24px 0;
}

.success-message {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-radius: 8px;
    padding: 12px 16px;
    color: #22c55e;
    font-size: 14px;
    margin-bottom: 20px;
    display: none;
}

.success-message.show {
    display: flex;
    align-items: center;
    gap: 8px;
}

.design-elements {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.design-element-tag {
    background: var(--gray-700);
    border: 1px solid var(--gray-600);
    border-radius: 20px;
    padding: 6px 12px;
    font-size: 12px;
    color: var(--gray-300);
    cursor: pointer;
    transition: all 0.2s ease;
}

.design-element-tag.selected {
    background: rgba(239, 68, 68, 0.2);
    border-color: var(--red-500);
    color: var(--red-400);
}

.analyzed-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-radius: 20px;
    padding: 4px 12px;
    font-size: 12px;
    color: #22c55e;
    margin-left: 12px;
}

/* Company Info Section */
.branding-section h3 svg {
    vertical-align: middle;
    margin-right: 8px;
    color: var(--red-500);
}

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

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-300);
}

.form-input {
    background: var(--gray-900);
    border: 1px solid var(--gray-700);
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 14px;
    color: #fff;
    transition: all 0.2s ease;
}

.form-input:focus {
    outline: none;
    border-color: var(--red-500);
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-input::placeholder {
    color: var(--gray-500);
}

.form-textarea {
    background: var(--gray-900);
    border: 1px solid var(--gray-700);
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 14px;
    color: #fff;
    resize: vertical;
    min-height: 80px;
    font-family: inherit;
    transition: all 0.2s ease;
}

.form-textarea:focus {
    outline: none;
    border-color: var(--red-500);
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-textarea::placeholder {
    color: var(--gray-500);
}

.form-hint {
    font-size: 12px;
    color: var(--gray-500);
    margin-top: 4px;
}

/* Toggle Switch */
.toggle-label-inline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-300);
    padding: 10px 0;
}

.toggle-switch {
    position: relative;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--gray-700);
    border-radius: 24px;
    transition: 0.3s;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    border-radius: 50%;
    transition: 0.3s;
}

.toggle-switch input:checked + .toggle-slider {
    background-color: var(--red-500);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(20px);
}

.toggle-switch input:focus + .toggle-slider {
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
}

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

    .style-options {
        grid-template-columns: repeat(2, 1fr);
    }

    .branding-actions {
        flex-direction: column;
    }

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