/* ============================================
   Services Page Styles
   ============================================ */

/* Page Header */
.page-header {
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding-top: 120px;
    text-align: center;
}

.page-header-content {
    max-width: 800px;
    margin: 0 auto;
}

.page-badge {
    display: inline-block;
    padding: 10px 24px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 50px;
    color: var(--primary-color);
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 25px;
}

.page-header h1 {
    margin-bottom: 20px;
}

.page-header p {
    font-size: 1.2rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Service Detail Sections */
.service-detail {
    position: relative;
}

.service-detail.alternate {
    background: var(--darker-bg);
}

.service-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.service-detail-grid.reverse {
    direction: rtl;
}

.service-detail-grid.reverse > * {
    direction: ltr;
}

.service-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 50px;
    color: var(--primary-color);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.service-detail-content h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.service-detail-content .lead {
    font-size: 1.2rem;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 40px;
}

/* Service Features */
.service-features {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 40px;
}

.service-features .feature-item {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.service-features .feature-item i {
    color: #10b981;
    font-size: 1.3rem;
    flex-shrink: 0;
    margin-top: 2px;
}

.service-features .feature-item h4 {
    font-size: 1.1rem;
    margin-bottom: 5px;
    color: var(--text-primary);
}

.service-features .feature-item p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Service Pricing */
.service-pricing {
    display: flex;
    align-items: center;
    gap: 25px;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.price-tag {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

.price-tag span {
    font-size: 2rem;
    font-weight: 700;
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 0 5px;
}

/* Visual Cards */
.visual-card {
    background: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 30px;
    box-shadow: var(--shadow-lg);
}

/* Code Preview */
.code-preview {
    background: #1a1a24;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 20px;
}

.code-header {
    background: #252530;
    padding: 12px 15px;
    display: flex;
    gap: 8px;
}

.code-header .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red {
    background: #ff5f56;
}

.dot.yellow {
    background: #ffbd2e;
}

.dot.green {
    background: #27c93f;
}

.code-content {
    padding: 25px;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.6;
    color: #e0e0e0;
}

.code-content .comment {
    color: #6a9955;
}

.code-content .keyword {
    color: #569cd6;
}

.code-content .function {
    color: #dcdcaa;
}

.code-content .string {
    color: #ce9178;
}

.code-content .number {
    color: #b5cea8;
}

.code-content .boolean {
    color: #569cd6;
}

/* Stats Mini */
.stats-mini {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.stat-mini-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px;
    background: rgba(99, 102, 241, 0.05);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 12px;
}

.stat-mini-item i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.stat-mini-item h5 {
    font-size: 1rem;
    margin-bottom: 2px;
}

.stat-mini-item p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Image Gallery */
.image-gallery {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}

.gallery-item {
    aspect-ratio: 1;
    border-radius: 12px;
    overflow: hidden;
}

.placeholder-image {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    transition: transform 0.3s;
}

.gallery-item:hover .placeholder-image {
    transform: scale(1.05);
}

.generation-prompt {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 15px;
    background: rgba(99, 102, 241, 0.05);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 12px;
}

.generation-prompt p {
    flex: 1;
    color: var(--text-secondary);
    font-style: italic;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.85rem;
}

/* Chat Interface */
.chat-interface {
    background: #1a1a24;
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 20px;
}

.chat-header {
    background: var(--gradient-primary);
    padding: 15px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.chat-avatar {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.chat-header h4 {
    margin-bottom: 2px;
    font-size: 1rem;
}

.online-status {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    gap: 5px;
}

.online-status i {
    font-size: 0.5rem;
    color: #10b981;
}

.chat-messages {
    padding: 20px;
    min-height: 250px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.message {
    max-width: 80%;
    padding: 12px 16px;
    border-radius: 12px;
    animation: messageSlide 0.3s ease;
}

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

.bot-message {
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    align-self: flex-start;
}

.user-message {
    background: var(--gradient-primary);
    align-self: flex-end;
}

.typing-indicator {
    display: flex;
    gap: 5px;
    padding: 12px 16px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 12px;
    align-self: flex-start;
    width: fit-content;
}

.typing-indicator span {
    width: 8px;
    height: 8px;
    background: var(--primary-color);
    border-radius: 50%;
    animation: typing 1.4s infinite;
}

.typing-indicator span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.5;
    }
    30% {
        transform: translateY(-10px);
        opacity: 1;
    }
}

/* Analytics Dashboard */
.analytics-dashboard {
    background: #1a1a24;
    border-radius: 15px;
    padding: 20px;
}

.dashboard-header {
    margin-bottom: 20px;
}

.dashboard-header h4 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.1rem;
}

.dashboard-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.dash-stat {
    background: rgba(99, 102, 241, 0.05);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 12px;
    padding: 15px;
    position: relative;
}

.dash-stat .stat-value {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 5px;
}

.dash-stat .stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.stat-trend {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 0.85rem;
    padding: 4px 8px;
    border-radius: 6px;
}

.stat-trend.up {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
}

.dashboard-chart {
    background: rgba(99, 102, 241, 0.05);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 12px;
    padding: 20px;
    height: 150px;
}

.chart-bars {
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    height: 100%;
    gap: 10px;
}

.bar {
    flex: 1;
    background: var(--gradient-primary);
    border-radius: 6px 6px 0 0;
    animation: barGrow 1s ease;
}

@keyframes barGrow {
    from {
        height: 0;
    }
}

/* Video Preview */
.video-preview {
    background: #1a1a24;
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 20px;
}

.video-player {
    aspect-ratio: 16/9;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.play-button {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    transition: transform 0.3s;
}

.video-player:hover .play-button {
    transform: scale(1.1);
    background: rgba(255, 255, 255, 0.3);
}

.video-overlay {
    position: absolute;
    bottom: 20px;
    left: 20px;
    padding: 10px 20px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 8px;
    font-size: 0.9rem;
}

.video-timeline {
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    position: relative;
}

.timeline-progress {
    height: 100%;
    background: var(--gradient-primary);
    transition: width 0.3s;
}

.video-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 20px;
    background: #252530;
}

.video-controls button {
    background: none;
    border: none;
    color: white;
    font-size: 1rem;
    cursor: pointer;
    transition: color 0.3s;
}

.video-controls button:hover {
    color: var(--primary-color);
}

.video-controls .time {
    flex: 1;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Custom AI Visual */
.custom-ai-visual {
    background: #1a1a24;
    border-radius: 15px;
    padding: 40px;
    min-height: 400px;
    position: relative;
}

.ai-nodes {
    position: relative;
    height: 300px;
    margin-bottom: 30px;
}

.node {
    position: absolute;
    width: 80px;
    height: 80px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    box-shadow: 0 8px 32px rgba(99, 102, 241, 0.4);
    animation: nodeFloat 3s infinite ease-in-out;
}

.node-1 {
    top: 0;
    left: 50%;
    transform: translateX(-50%);
}

.node-2 {
    bottom: 0;
    left: 10%;
    animation-delay: -1s;
}

.node-3 {
    bottom: 0;
    right: 10%;
    animation-delay: -2s;
}

.node-4 {
    top: 50%;
    right: 0;
    animation-delay: -1.5s;
}

@keyframes nodeFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-15px);
    }
}

.connections {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.connections line {
    stroke: rgba(99, 102, 241, 0.3);
    stroke-width: 2;
    stroke-dasharray: 5, 5;
    animation: dash 20s linear infinite;
}

@keyframes dash {
    to {
        stroke-dashoffset: -100;
    }
}

.integration-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.integration-badges .badge {
    padding: 8px 16px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--primary-color);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .service-detail-grid {
        grid-template-columns: 1fr;
        gap: 50px;
    }
    
    .service-detail-grid.reverse {
        direction: ltr;
    }
    
    .service-pricing {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .page-header {
        min-height: 50vh;
        padding-top: 100px;
    }
    
    .service-detail-content h2 {
        font-size: 2rem;
    }
    
    .stats-mini {
        grid-template-columns: 1fr;
    }
    
    .dashboard-stats {
        grid-template-columns: 1fr;
    }
    
    .image-gallery {
        grid-template-columns: 1fr;
    }
    
    .generation-prompt {
        flex-direction: column;
    }
    
    .ai-nodes {
        height: 250px;
    }
    
    .node {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
}