/* ===================================================================
   SECTIONS.CSS - Page Sections (Hero, Services, Pricing, etc.)
   =================================================================== */

/* ===== Hero Section ===== */
.hero {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    padding: 120px 24px 80px;
    max-width: 1400px;
    margin: 0 auto;
}

.hero-content {
    max-width: 600px;
}

.hero-badge {
    display: inline-block;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary-light);
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 24px;
    border: 1px solid rgba(99, 102, 241, 0.3);
}

.hero h1 {
    font-size: clamp(40px, 6vw, 64px);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 8px;
}

.hero h1 .highlight {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero h2 {
    font-size: clamp(24px, 3.5vw, 36px);
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.hero-subtitle {
    font-size: 18px;
    color: var(--text-muted);
    margin-bottom: 32px;
    max-width: 480px;
}

.hero-cta {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 48px;
}

.hero-stats {
    display: flex;
    gap: 48px;
    align-items: flex-start;
}

.hero-visual {
    display: flex;
    justify-content: center;
}

/* ===== Code Window (Hero Interactive) ===== */
.code-window {
    background: var(--bg-card);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-xl), var(--shadow-glow);
    max-width: 500px;
    width: 100%;
    border: 1px solid var(--border-color);
}

.code-window.interactive {
    max-width: 520px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.code-window.minimized {
    transform: scale(0.95);
}

.code-window.minimized .code-content,
.code-window.minimized .code-output {
    max-height: 0;
    padding: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.code-window .code-content,
.code-window .code-output {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 1;
}

.code-window.minimized .code-header {
    border-radius: 0 0 var(--border-radius-lg) var(--border-radius-lg);
}

.dot.yellow.minimized-indicator {
    animation: pulse-yellow 1s infinite;
}

@keyframes pulse-yellow {
    0%, 100% { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.5); }
    50% { box-shadow: 0 0 0 6px rgba(245, 158, 11, 0); }
}

.code-header {
    background: var(--bg-dark);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 1px solid var(--border-color);
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
}

.dot:hover {
    transform: scale(1.2);
}

.dot.red { background: #ef4444; }
.dot.yellow { background: #f59e0b; }
.dot.green { background: #10b981; }

.code-title {
    font-size: 13px;
    color: var(--text-muted);
    margin-left: 8px;
    font-family: 'Monaco', 'Menlo', monospace;
}

.run-btn {
    margin-left: auto;
    background: var(--success);
    color: white;
    border: none;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
}

.run-btn:hover {
    background: #0d9668;
    transform: scale(1.05);
}

.code-content {
    padding: 0;
    font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
    font-size: 13px;
    line-height: 1.6;
}

#code-editor {
    width: 100%;
    min-height: 240px;
    padding: 16px;
    background: #0d1117;
    border: none;
    color: #c9d1d9;
    font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
    font-size: 13px;
    line-height: 1.6;
    resize: none;
    outline: none;
    tab-size: 2;
}

#code-editor:focus {
    background: #0d1117;
}

.code-output {
    border-top: 1px solid var(--border-color);
    background: #0d1117;
}

.output-header {
    padding: 8px 16px;
    background: rgba(0, 0, 0, 0.3);
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 1px solid var(--border-color);
}

.output-content {
    padding: 12px 16px;
    min-height: 80px;
    max-height: 150px;
    overflow-y: auto;
    font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
    font-size: 12px;
    line-height: 1.6;
}

.output-hint {
    color: var(--text-muted);
    font-style: italic;
}

.output-line {
    margin-bottom: 4px;
    color: #c9d1d9;
}

.output-line.log { color: #c9d1d9; }
.output-line.error { color: #f85149; }
.output-line.success { color: var(--success); }
.output-line .output-object { color: #79c0ff; }

.code-content pre {
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* Code Window Close Animation */
.code-window.closing {
    animation: windowClose 0.5s ease-out forwards;
}

@keyframes windowClose {
    0% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.9); }
    100% { opacity: 0; transform: scale(0) rotate(10deg); visibility: hidden; }
}

.code-window.hidden {
    display: none;
}

/* ===== Impossible Puzzle Game ===== */
.puzzle-container {
    display: none;
    max-width: 520px;
    width: 100%;
}

.puzzle-container.active {
    display: block;
    animation: puzzleAppear 0.6s ease-out;
}

@keyframes puzzleAppear {
    0% { opacity: 0; transform: scale(0.5) rotate(-5deg); }
    50% { transform: scale(1.05) rotate(2deg); }
    100% { opacity: 1; transform: scale(1) rotate(0deg); }
}

.puzzle-window {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    border: 2px solid #e94560;
    box-shadow: 
        0 0 20px rgba(233, 69, 96, 0.3),
        0 0 60px rgba(233, 69, 96, 0.1),
        inset 0 0 60px rgba(0, 0, 0, 0.3);
}

.puzzle-header {
    background: linear-gradient(90deg, #e94560, #ff6b6b);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.puzzle-icon {
    font-size: 20px;
    animation: iconSpin 2s linear infinite;
}

@keyframes iconSpin {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(10deg); }
    75% { transform: rotate(-10deg); }
}

.puzzle-title {
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 13px;
    letter-spacing: 1px;
}

.puzzle-status {
    padding: 16px;
    background: rgba(233, 69, 96, 0.1);
    border-bottom: 1px solid rgba(233, 69, 96, 0.3);
    font-size: 14px;
    color: #ff6b6b;
    text-align: center;
    font-weight: 600;
    animation: statusBlink 1s ease-in-out infinite;
}

@keyframes statusBlink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.puzzle-progress {
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #00d9ff, #e94560, #ff6b6b);
    background-size: 200% 100%;
    animation: progressGradient 2s linear infinite;
    width: 0%;
    transition: width 0.3s ease;
}

@keyframes progressGradient {
    0% { background-position: 0% 0%; }
    100% { background-position: 200% 0%; }
}

.puzzle-question {
    padding: 24px 20px;
    font-size: 16px;
    line-height: 1.6;
    color: #ffffff;
    text-align: center;
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.puzzle-question .question-number {
    display: block;
    font-size: 12px;
    color: #00d9ff;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.puzzle-answers {
    padding: 0 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.puzzle-answer {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 14px 18px;
    border-radius: 10px;
    color: #e0e0e0;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
}

.puzzle-answer:hover {
    background: rgba(233, 69, 96, 0.2);
    border-color: #e94560;
    transform: translateX(8px);
    box-shadow: 0 0 20px rgba(233, 69, 96, 0.2);
}

.puzzle-answer.correct {
    background: rgba(16, 185, 129, 0.3);
    border-color: #10b981;
    animation: correctPulse 0.5s ease;
}

.puzzle-answer.wrong {
    background: rgba(239, 68, 68, 0.3);
    border-color: #ef4444;
    animation: wrongShake 0.5s ease;
}

@keyframes correctPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); }
}

@keyframes wrongShake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-10px); }
    40% { transform: translateX(10px); }
    60% { transform: translateX(-5px); }
    80% { transform: translateX(5px); }
}

.puzzle-timer {
    padding: 16px;
    background: rgba(0, 0, 0, 0.3);
    text-align: center;
    font-size: 14px;
    color: var(--text-muted);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

#countdown {
    color: #00d9ff;
    font-weight: 700;
    font-size: 18px;
}

/* ===== Services Section ===== */
.services {
    background: var(--bg-dark);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.service-card {
    background: var(--bg-card);
    border-radius: var(--border-radius-lg);
    padding: 32px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    position: relative;
}

.service-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
    box-shadow: var(--shadow-glow);
}

.service-card.featured {
    border-color: var(--primary);
    background: linear-gradient(180deg, rgba(99, 102, 241, 0.1) 0%, var(--bg-card) 100%);
}

.service-icon {
    font-size: 48px;
    margin-bottom: 20px;
}

.service-card h3 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 12px;
}

.service-card p {
    color: var(--text-secondary);
    margin-bottom: 20px;
    font-size: 15px;
}

.service-features {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.service-features li {
    color: var(--text-muted);
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.service-features li::before {
    content: '✓';
    color: var(--success);
    font-weight: 600;
}

/* ===== About Section ===== */
.about-content {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 80px;
    align-items: center;
}

.about-image {
    position: relative;
}

.about-image-wrapper {
    position: relative;
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    aspect-ratio: 1;
    max-width: 400px;
}

.about-placeholder {
    width: 100%;
    height: 100%;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 120px;
    font-weight: 800;
    color: white;
}

.about-badge {
    position: absolute;
    bottom: -20px;
    right: -20px;
    background: var(--bg-card);
    padding: 16px 24px;
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    gap: 12px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-lg);
}

.badge-icon {
    font-size: 24px;
}

.about-text .section-badge {
    margin-bottom: 16px;
}

.about-text h2 {
    font-size: clamp(32px, 4vw, 48px);
    font-weight: 800;
    margin-bottom: 20px;
}

.about-text p {
    color: var(--text-secondary);
    font-size: 17px;
    margin-bottom: 16px;
}

.about-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-top: 32px;
}

.feature {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 500;
}

.feature-icon {
    color: var(--success);
}

/* ===== Pricing Section ===== */
.pricing {
    background: var(--bg-dark);
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    align-items: stretch;
}

.pricing-card {
    background: var(--bg-card);
    border-radius: var(--border-radius-lg);
    padding: 40px 32px;
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    position: relative;
    transition: var(--transition);
}

.pricing-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
}

.pricing-card.featured {
    border-color: var(--primary);
    background: linear-gradient(180deg, rgba(99, 102, 241, 0.1) 0%, var(--bg-card) 100%);
    transform: scale(1.05);
    z-index: 1;
}

.pricing-card.featured:hover {
    transform: scale(1.08);
}

.pricing-header {
    text-align: center;
    margin-bottom: 32px;
    padding-bottom: 32px;
    border-bottom: 1px solid var(--border-color);
}

.pricing-header h3 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 16px;
}

.price {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 4px;
}

.currency {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-top: 8px;
}

.amount {
    font-size: 64px;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
}

.price-plus {
    font-size: 32px;
    font-weight: 700;
    color: var(--text-secondary);
    margin-top: 8px;
}

.price-desc {
    color: var(--text-muted);
    margin-top: 8px;
}

.pricing-features {
    flex-grow: 1;
    margin-bottom: 32px;
}

.pricing-features li {
    padding: 12px 0;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid rgba(51, 65, 85, 0.5);
}

.pricing-features li:last-child {
    border-bottom: none;
}

.pricing-features li::before {
    content: '✓';
    color: var(--success);
    font-weight: 600;
    font-size: 16px;
}

.pricing-card .btn {
    margin-top: auto;
}

.pricing-note {
    text-align: center;
    color: var(--text-muted);
    margin-top: 40px;
    font-size: 15px;
}

/* ===== Testimonials Section ===== */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.testimonial-card {
    background: var(--bg-card);
    border-radius: var(--border-radius-lg);
    padding: 32px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.testimonial-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary);
}

.testimonial-content {
    margin-bottom: 24px;
}

.stars {
    font-size: 18px;
    margin-bottom: 16px;
}

.testimonial-content p {
    color: var(--text-secondary);
    font-size: 16px;
    font-style: italic;
    line-height: 1.7;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 16px;
}

.author-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
}

.author-info {
    display: flex;
    flex-direction: column;
}

.author-name {
    font-weight: 600;
}

.author-role {
    color: var(--text-muted);
    font-size: 14px;
}

/* ===== Contact Section ===== */
.contact {
    background: var(--bg-dark);
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 80px;
    align-items: start;
}

.contact-info .section-badge {
    margin-bottom: 16px;
}

.contact-info h2 {
    font-size: clamp(32px, 4vw, 48px);
    font-weight: 800;
    margin-bottom: 16px;
}

.contact-info > p {
    color: var(--text-secondary);
    font-size: 17px;
    margin-bottom: 32px;
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 32px;
}

.contact-method {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: var(--bg-card);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.contact-method:hover {
    border-color: var(--primary);
    transform: translateX(8px);
}

.method-icon {
    font-size: 24px;
}

.method-text {
    font-weight: 500;
}

.response-time {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--success);
    font-weight: 500;
}

.contact-form {
    background: var(--bg-card);
    border-radius: var(--border-radius-lg);
    padding: 40px;
    border: 1px solid var(--border-color);
}
