/*
Theme Name: FreeSubtitles
Theme URI: https://freesubtitles.gr
Description: Free online subtitle generator - Create SRT/VTT subtitles from video using AI
Version: 1.0.0
Author: FreeSubtitles.gr
Text Domain: freesubtitles
*/

:root {
    --primary: #f59e0b;
    --primary-dark: #d97706;
    --secondary: #fbbf24;
    --accent: #f97316;
    --dark: #1e293b;
    --gray: #64748b;
    --light: #f8fafc;
    --gradient: linear-gradient(135deg, #f59e0b 0%, #f97316 50%, #ef4444 100%);
    --gradient-dark: linear-gradient(135deg, #1e1b4b 0%, #312e81 100%);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--light);
    color: var(--dark);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}
.btn-primary {
    background: var(--gradient);
    color: white;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.4);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(245, 158, 11, 0.5);
}
.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}
.btn-outline:hover {
    background: var(--primary);
    color: white;
}
.btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}
.btn-lg { padding: 16px 32px; font-size: 1.1rem; }

/* Header */
.site-header {
    background: white;
    box-shadow: 0 2px 20px rgba(0,0,0,0.08);
    position: sticky;
    top: 0;
    z-index: 1000;
}
.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}
.logo {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--dark);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
}
.logo-icon {
    width: 45px;
    height: 45px;
    background: var(--gradient);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.4rem;
}
.logo span { color: var(--primary); }

.main-nav { display: flex; gap: 30px; align-items: center; }
.main-nav a {
    color: var(--gray);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}
.main-nav a:hover { color: var(--primary); }

.lang-switch {
    display: flex;
    gap: 5px;
    background: var(--light);
    padding: 5px;
    border-radius: 8px;
}
.lang-switch a {
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    text-decoration: none;
    color: var(--gray);
}
.lang-switch a.active {
    background: var(--primary);
    color: white;
}

/* Hero Section */
.hero {
    background: var(--gradient);
    padding: 80px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none'%3E%3Cg fill='%23ffffff' fill-opacity='0.08'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero h1 {
    color: white;
    font-size: 3rem;
    margin-bottom: 20px;
    position: relative;
    text-shadow: 0 2px 10px rgba(0,0,0,0.2);
}
.hero p {
    color: rgba(255,255,255,0.95);
    font-size: 1.25rem;
    max-width: 700px;
    margin: 0 auto 30px;
    position: relative;
}
.hero-badges {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 25px;
    position: relative;
}
.badge {
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    background: rgba(255,255,255,0.2);
    color: white;
    backdrop-filter: blur(10px);
}

/* Sections */
.section {
    padding: 70px 0;
}
.section-header {
    text-align: center;
    margin-bottom: 50px;
}
.section-header h2 {
    font-size: 2.2rem;
    margin-bottom: 15px;
    color: var(--dark);
}
.section-header p {
    color: var(--gray);
    font-size: 1.1rem;
}

/* Tools Grid */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}
.tool-card {
    background: white;
    border-radius: 20px;
    padding: 35px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    border: 2px solid transparent;
    text-align: center;
}
.tool-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(245, 158, 11, 0.15);
    border-color: var(--primary);
}
.tool-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 2rem;
}
.tool-card h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: var(--dark);
}
.tool-card p {
    color: var(--gray);
    margin-bottom: 20px;
    line-height: 1.6;
}

/* Category */
.category-section { margin-bottom: 50px; }
.category-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 25px;
}
.category-icon {
    width: 45px;
    height: 45px;
    background: var(--gradient);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}
.category-title h2 {
    font-size: 1.5rem;
    color: var(--dark);
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}
.feature-item {
    text-align: center;
    padding: 30px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}
.feature-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #fff7ed, #ffedd5);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: var(--primary);
}
.feature-item h4 {
    margin-bottom: 10px;
    color: var(--dark);
}
.feature-item p {
    color: var(--gray);
    font-size: 0.95rem;
}

/* Footer */
.site-footer {
    background: var(--dark);
    color: white;
    padding: 60px 0 30px;
}
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}
@media (max-width: 900px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
    .footer-grid { grid-template-columns: 1fr; }
}
.footer-col h4 {
    margin-bottom: 20px;
    font-size: 1.1rem;
    color: var(--secondary);
}
.footer-col p { color: #94a3b8; line-height: 1.8; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 12px; }
.footer-col a {
    color: #94a3b8;
    text-decoration: none;
    transition: color 0.2s;
}
.footer-col a:hover { color: var(--secondary); }
.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #334155;
    color: #64748b;
}

/* Ad Placeholder */
.ad-placeholder {
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
    border: 2px dashed #cbd5e1;
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    color: var(--gray);
}

/* Upload Area */
.upload-area {
    border: 3px dashed #cbd5e1;
    border-radius: 24px;
    padding: 60px 40px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
}
.upload-area:hover, .upload-area.drag-over {
    border-color: var(--primary);
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    transform: scale(1.02);
}
.upload-area-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}
.upload-area h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: var(--dark);
}
.upload-area p {
    color: var(--gray);
}

/* Progress Bar */
.progress-container {
    background: #e2e8f0;
    border-radius: 10px;
    height: 20px;
    overflow: hidden;
    margin: 20px 0;
}
.progress-bar {
    height: 100%;
    background: var(--gradient);
    border-radius: 10px;
    transition: width 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Subtitle Editor */
.subtitle-editor {
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    overflow: hidden;
}
.subtitle-toolbar {
    background: linear-gradient(135deg, #1e1b4b, #312e81);
    padding: 15px 20px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.subtitle-toolbar .btn {
    padding: 8px 16px;
    font-size: 0.9rem;
}
.subtitle-list {
    max-height: 400px;
    overflow-y: auto;
}
.subtitle-item {
    display: grid;
    grid-template-columns: 100px 1fr 50px;
    gap: 15px;
    padding: 15px 20px;
    border-bottom: 1px solid #e2e8f0;
    align-items: center;
}
.subtitle-item:hover {
    background: #f8fafc;
}
.subtitle-time {
    font-family: monospace;
    font-size: 0.85rem;
    color: var(--primary);
    font-weight: 600;
}
.subtitle-text {
    padding: 10px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.95rem;
    resize: none;
    min-height: 50px;
}
.subtitle-text:focus {
    outline: none;
    border-color: var(--primary);
}
.subtitle-delete {
    background: #fee2e2;
    color: #ef4444;
    border: none;
    padding: 8px;
    border-radius: 8px;
    cursor: pointer;
}

/* Video Preview */
.video-preview-container {
    background: #000;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
}
.video-preview-container video {
    width: 100%;
    display: block;
}
.subtitle-overlay {
    position: absolute;
    bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 1.1rem;
    text-align: center;
    max-width: 80%;
}

/* Responsive */
@media (max-width: 768px) {
    .hero h1 { font-size: 2rem; }
    .hero p { font-size: 1rem; }
    .main-nav { display: none; }
    .tools-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
}
