/* Reel Hooks Generator Styles - Matches Hashtag Generator Design */

.generator-container {
    flex: 1;
    padding: 0.5rem 0;
    overflow: hidden;
}

/* Generator Layout */
.generator-layout {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 320px 1fr;
    height: calc(100vh - 150px);
    gap: 0;
}

/* Controls Sidebar */
.controls-sidebar {
    background: var(--bg-primary);
    border: 1px solid var(--border-light);
    border-right: 1px solid var(--border-light);
    overflow-y: auto;
    padding: 1.5rem;
}

.sidebar-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-primary);
}

.sidebar-title i {
    width: 20px;
    height: 20px;
    color: var(--accent-primary);
}

/* Control Sections */
.control-section {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-light);
}

.control-section:last-child {
    border-bottom: none;
}

.section-title {
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

/* Checkbox Group */
.checkbox-group {
    margin-bottom: 0.75rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.checkbox-label:hover {
    color: var(--text-primary);
}

/* Full Width Controls */
#reelTopic {
    width: 100%;
    resize: vertical;
    min-height: 80px;
}

#generateBtn {
    width: 100%;
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Disabled Button Styles */
.btn:disabled,
.btn-primary:disabled,
#generateBtn:disabled,
#regenerateBtn:disabled {
    background: var(--bg-tertiary) !important;
    color: var(--text-muted) !important;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
    opacity: 0.6;
}

.btn:disabled:hover,
.btn-primary:disabled:hover,
#generateBtn:disabled:hover,
#regenerateBtn:disabled:hover {
    transform: none !important;
    box-shadow: none !important;
    background: var(--bg-tertiary) !important;
    color: var(--text-muted) !important;
}

/* Results Area */
.results-area {
    background: var(--bg-secondary);
    padding: 2rem;
    overflow: auto;
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}

@media (max-width: 600px) {
    .results-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
}

.results-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.generation-status {
    font-size: 0.875rem;
    color: var(--text-secondary);
    background: var(--bg-primary);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    border: 1px solid var(--border-light);
}

.generation-status.generating {
    color: var(--accent-primary);
    background: rgba(0, 180, 182, 0.1);
    border-color: var(--accent-primary);
}

.generation-status.success {
    color: var(--success);
    background: rgba(22, 163, 74, 0.1);
    border-color: var(--success);
}

.generation-status.error {
    color: var(--error);
    background: rgba(220, 38, 38, 0.1);
    border-color: var(--error);
}

/* Hooks Placeholder */
.hooks-placeholder {
    background: var(--bg-primary);
    border: 2px dashed var(--border-medium);
    border-radius: 8px;
    padding: 3rem 2rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.hooks-placeholder i {
    font-size: 3rem;
    color: var(--text-muted);
}

.hooks-placeholder h4 {
    font-size: 1.25rem;
    color: var(--text-primary);
    margin: 0;
}

.hooks-placeholder p {
    color: var(--text-secondary);
    margin: 0;
}

.placeholder-features {
    display: flex;
    gap: 2rem;
    margin-top: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.feature-item i {
    width: 16px;
    height: 16px;
    color: var(--accent-primary);
}

/* Hooks List */
.hooks-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1rem;
}

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

.hook-item {
    background: var(--bg-primary);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 1.25rem;
    position: relative;
    transition: all 0.2s;
    display: flex;
    flex-direction: column;
    min-height: 120px;
}

.hook-item:hover {
    border-color: var(--accent-primary);
    box-shadow: 0 4px 12px rgba(0, 180, 182, 0.1);
    transform: translateY(-2px);
}

.hook-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.75rem;
    gap: 0.5rem;
}

.hook-number {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-primary);
    background: rgba(0, 180, 182, 0.1);
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    min-width: 24px;
    text-align: center;
    flex-shrink: 0;
}

.hook-actions {
    display: flex;
    gap: 0.25rem;
    flex-shrink: 0;
}

.hook-btn {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-light);
    border-radius: 4px;
    padding: 0.4rem;
    cursor: pointer;
    color: var(--text-secondary);
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hook-btn:hover {
    background: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

.hook-btn i {
    width: 14px;
    height: 14px;
}

.hook-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hook-text {
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--text-primary);
    font-weight: 500;
    margin-bottom: 0.75rem;
}

/* Hook Sections */
.hook-section {
    margin-bottom: 0.75rem;
}

.hook-section strong {
    display: block;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.hook-type-text {
    font-size: 0.85rem;
    color: var(--text-secondary);
    padding: 0.25rem 0;
}

.hook-explanation {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.4;
    padding: 0.25rem 0;
}

.hook-content-outline {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.4;
    padding: 0.25rem 0;
}

.hook-type {
    font-size: 0.75rem;
    color: var(--text-muted);
    background: var(--bg-tertiary);
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    margin-top: 0.75rem;
    align-self: flex-start;
    border: 1px solid var(--border-light);
}

/* Hook Performance Indicators */
.hook-indicators {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
    flex-wrap: wrap;
}

.hook-indicator {
    font-size: 0.7rem;
    padding: 0.15rem 0.4rem;
    border-radius: 10px;
    background: rgba(0, 180, 182, 0.1);
    color: var(--accent-primary);
    border: 1px solid rgba(0, 180, 182, 0.2);
}

.hook-indicator.curiosity {
    background: rgba(147, 51, 234, 0.1);
    color: #9333ea;
    border-color: rgba(147, 51, 234, 0.2);
}

.hook-indicator.engagement {
    background: rgba(245, 101, 101, 0.1);
    color: #f56565;
    border-color: rgba(245, 101, 101, 0.2);
}

.hook-indicator.viral {
    background: rgba(34, 197, 94, 0.1);
    color: #22c55e;
    border-color: rgba(34, 197, 94, 0.2);
}

/* Results Actions */
.results-actions {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-light);
    margin-top: 2rem;
}

/* History Button Styling (Same as hashtag generator) */
.btn-history {
    background: linear-gradient(135deg, rgba(0, 180, 182, 0.1), rgba(0, 180, 182, 0.05));
    color: var(--accent-primary);
    border: 1px solid rgba(0, 180, 182, 0.3);
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    position: relative;
    overflow: hidden;
}

.btn-history:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 180, 182, 0.15), transparent);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
}

.btn-history:hover {
    background: linear-gradient(135deg, rgba(0, 180, 182, 0.15), rgba(0, 180, 182, 0.1));
    border-color: var(--accent-primary);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 180, 182, 0.2);
}

.btn-history:hover:before {
    transform: translateX(0);
}

/* History Modal (Same as hashtag generator) */
.history-modal .modal {
    max-width: 90vw;
    width: 500px;
    max-height: 80vh;
}

.history-modal .modal-body {
    max-height: 60vh;
    overflow-y: auto;
}

@media (min-width: 768px) {
    .history-modal .modal {
        width: 700px;
    }
}

@media (min-width: 1200px) {
    .history-modal .modal {
        width: 800px;
    }
}

.history-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.history-item {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-light);
    border-radius: 6px;
    padding: 1rem;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
}

.history-item:hover {
    background: var(--bg-secondary);
    border-color: var(--border-medium);
}

.history-item-content {
    flex: 1;
    cursor: pointer;
}

.history-delete-btn {
    background: rgba(220, 38, 38, 0.1);
    border: 1px solid rgba(220, 38, 38, 0.2);
    border-radius: 4px;
    padding: 0.5rem;
    cursor: pointer;
    color: var(--error);
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    flex-shrink: 0;
}

.history-delete-btn:hover {
    background: var(--error);
    color: white;
    border-color: var(--error);
}

.history-delete-btn i {
    width: 16px;
    height: 16px;
}

.history-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.history-item-title {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-primary);
}

.history-item-date {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.history-item-preview {
    font-size: 0.875rem;
    color: var(--text-secondary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
}

.history-item-count {
    font-size: 0.75rem;
    color: var(--accent-primary);
    background: rgba(0, 180, 182, 0.1);
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    margin-top: 0.5rem;
    display: inline-block;
}

.history-empty {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
}

.history-empty i {
    font-size: 3rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
    display: block;
}

.history-empty p {
    margin: 0.5rem 0;
}

/* Dark Mode History Styles */
[data-theme="dark"] .history-item {
    background: var(--bg-tertiary);
    border-color: var(--border-medium);
}

[data-theme="dark"] .history-item:hover {
    background: var(--border-light);
}

[data-theme="dark"] .history-item-title {
    color: var(--text-primary);
}

[data-theme="dark"] .history-delete-btn {
    background: rgba(220, 38, 38, 0.15);
    border-color: rgba(220, 38, 38, 0.3);
}

[data-theme="dark"] .history-delete-btn:hover {
    background: var(--error);
    color: white;
    border-color: var(--error);
}

[data-theme="dark"] .history-empty {
    color: var(--text-secondary);
}

/* Dark Mode Styles */
[data-theme="dark"] .controls-sidebar {
    background: var(--bg-primary);
    border-color: var(--border-light);
}

[data-theme="dark"] .hook-item {
    background: var(--bg-primary);
    border-color: var(--border-light);
}

[data-theme="dark"] .hook-item:hover {
    border-color: var(--accent-primary);
}

[data-theme="dark"] .hook-btn {
    background: var(--bg-tertiary);
    border-color: var(--border-medium);
}

[data-theme="dark"] .hook-type {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
}

/* AI Notice Styling */
.ai-notice {
    background: rgba(234, 179, 8, 0.1);
    border: 1px solid var(--warning);
    border-radius: 6px;
    padding: 0.75rem;
    margin-top: 0.5rem;
}

.ai-notice p {
    margin: 0;
    font-size: 0.875rem;
    color: var(--warning);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    line-height: 1.4;
}

.ai-notice i {
    color: var(--warning);
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.btn-link {
    background: none;
    border: none;
    color: var(--warning);
    text-decoration: underline;
    cursor: pointer;
    font-size: inherit;
    padding: 0;
    margin: 0 0 0 0.25rem;
}

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

[data-theme="dark"] .ai-notice {
    background: rgba(234, 179, 8, 0.15);
    border-color: var(--warning);
}

[data-theme="dark"] .ai-notice p {
    color: var(--warning);
}

[data-theme="dark"] .ai-notice i {
    color: var(--warning);
}

/* Footer Styling - Same as hashtag generator */
.footer {
    background: var(--bg-primary);
    border-top: 1px solid var(--border-light);
    padding: 1rem;
    text-align: center;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 100;
}

.powered-by {
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-align: center;
}

.powered-by a {
    color: var(--accent-primary);
    text-decoration: none;
    margin-left: 0.25rem;
}

.powered-by a:hover {
    text-decoration: underline;
}

[data-theme="dark"] .footer {
    background: var(--bg-primary);
    border-top-color: var(--border-light);
}

/* Responsive Design */
@media (max-width: 1200px) {
    .generator-layout {
        grid-template-columns: 280px 1fr;
    }
}

@media (max-width: 968px) {
    .generator-layout {
        grid-template-columns: 1fr;
        grid-template-rows: 40vh 1fr;
        height: calc(100vh - 150px);
        gap: 0;
    }
    
    .controls-sidebar {
        border-right: none;
        border-bottom: 1px solid var(--border-light);
        max-height: 40vh;
        overflow-y: auto;
    }
    
    .results-area {
        padding: 1rem;
        overflow-y: auto;
        justify-content: flex-start;
    }
    
    .hooks-placeholder {
        padding: 2rem 1rem;
        min-height: 300px;
    }
}

@media (max-width: 480px) {
    .generator-layout {
        padding: 0 0.5rem;
        gap: 0.5rem;
    }
    
    .controls-sidebar {
        padding: 1rem;
    }
    
    .results-area {
        padding: 0.5rem;
    }
    
    .control-section {
        margin-bottom: 1.5rem;
        padding-bottom: 1rem;
    }
    
    .placeholder-features {
        gap: 1rem;
    }
    
    .hook-item {
        padding: 1rem;
        min-height: 100px;
    }
    
    .hook-header {
        margin-bottom: 0.5rem;
    }
}