html {
    scroll-behavior: smooth;
}

body { 
    font-family: 'Segoe UI', Arial, sans-serif; 
    background: #f7f8fa;
    color: #222; 
    margin: 0;
    min-height: 100vh;
}

.container { 
    max-width: 1100px; 
    margin: 0 auto; 
    padding: 24px;
    background: #fff;
    border-radius: 20px;
    margin-top: 20px;
    margin-bottom: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
}

header { 
    text-align: center; 
    margin-bottom: 40px;
    padding: 20px 0;
}

header h1 { 
    font-size: 3rem; 
    margin: 0 0 12px; 
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
    letter-spacing: -1px;
}

header p { 
    color: #666;
    font-size: 1.2rem;
    margin: 0;
}

.converters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 32px;
    align-items: stretch;
    justify-items: center;
    margin-bottom: 40px;
}

.converters-grid > h2 {
    margin-bottom: 24px;
}

.converter-card {
    width: 100%;
    max-width: 370px;
    min-height: 320px;
    background: #fff; 
    border-radius: 20px; 
    box-shadow: 0 8px 32px rgba(26,110,216,0.08); 
    padding: 36px 28px; 
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(26,110,216,0.05);
    position: relative;
    overflow: hidden;
}

.converter-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.converter-card:hover::before {
    transform: scaleX(1);
}

.converter-card:hover { 
    box-shadow: 0 16px 48px rgba(26,110,216,0.15);
    transform: translateY(-4px);
}

.converter-card.coming-soon::before {
    background: linear-gradient(90deg, #e5e7eb 0%, #d1d5db 100%);
}

.converter-icon { 
    margin-bottom: 20px; 
    color: #667eea;
    transition: transform 0.3s ease;
}

.converter-card:hover .converter-icon {
    transform: scale(1.1);
}

.converter-card h3 { margin: 0 0 8px; font-size: 1.3rem; }
.converter-card p { color: #444; text-align: center; margin-bottom: 16px; }
.btn { 
    display: inline-block; 
    padding: 16px 32px; 
    border-radius: 12px; 
    text-decoration: none; 
    font-weight: 600; 
    font-size: 1.05rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
    min-width: 140px;
    text-align: center;
    line-height: 1.2;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn.primary { 
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.3);
}

.btn.primary:hover { 
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.btn.secondary { 
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: #fff;
    box-shadow: 0 6px 20px rgba(240, 147, 251, 0.3);
}

.btn.secondary:hover { 
    background: linear-gradient(135deg, #e085e8 0%, #e04a5f 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(240, 147, 251, 0.4);
}

.btn.secondary.disabled { 
    background: linear-gradient(135deg, #e5e7eb 0%, #d1d5db 100%);
    color: #9ca3af;
    cursor: not-allowed;
    transform: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.btn.disabled, .btn:disabled {
    background: linear-gradient(135deg, #e5e7eb 0%, #d1d5db 100%) !important;
    color: #9ca3af !important;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
}

.btn:active {
    transform: translateY(0);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
}
.coming-soon { opacity: 0.7; }
.features { 
    margin-bottom: 50px;
    padding: 40px 0;
}

.features h2 {
    text-align: center;
    font-size: 2.2rem;
    margin-bottom: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
}

.features-grid { 
    display: flex; 
    gap: 28px; 
    flex-wrap: wrap; 
    justify-content: center; 
}

.feature { 
    background: #fff; 
    border-radius: 16px; 
    box-shadow: 0 8px 32px rgba(26,110,216,0.08); 
    padding: 28px 22px; 
    width: 240px; 
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(26,110,216,0.05);
}

.feature:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(26,110,216,0.15);
}

.feature-icon { 
    font-size: 2.5rem; 
    margin-bottom: 16px;
    display: block;
}

.feature h3 {
    font-size: 1.2rem;
    margin: 0 0 12px;
    color: #333;
    font-weight: 600;
}

.feature p {
    color: #666;
    line-height: 1.6;
    margin: 0;
}

.seo-content { 
    background: #fff; 
    border-radius: 16px; 
    box-shadow: 0 8px 32px rgba(26,110,216,0.08); 
    padding: 32px 28px; 
    margin-bottom: 40px;
    border: 1px solid rgba(26,110,216,0.05);
}

.seo-content h2 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: #333;
    font-weight: 700;
}

.seo-content h3 {
    font-size: 1.4rem;
    margin: 24px 0 16px;
    color: #444;
    font-weight: 600;
}

.seo-content p {
    line-height: 1.7;
    color: #555;
    margin-bottom: 16px;
}

.seo-content ul {
    line-height: 1.7;
    color: #555;
}

.seo-content li {
    margin-bottom: 8px;
}

footer { 
    text-align: center; 
    color: #666; 
    font-size: 1rem; 
    margin-top: 40px;
    padding: 20px 0;
    border-top: 1px solid rgba(26,110,216,0.1);
}

.upload-area {
    background: #fff;
    border: 2px dashed #1a6ed8;
    border-radius: 16px;
    padding: 32px 24px;
    text-align: center;
    margin-bottom: 32px;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    user-select: none;
}

.upload-area:hover {
    border-color: #155bb5;
    background: #f8faff;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(26, 110, 216, 0.15);
}

.upload-area.dragover {
    border-color: #155bb5;
    background: #e3eaf6;
    transform: scale(1.02);
    box-shadow: 0 12px 35px rgba(26, 110, 216, 0.25);
    border-style: solid;
}

.upload-area.dragover::before {
    content: 'Отпустите файлы здесь';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(26, 110, 216, 0.9);
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    z-index: 10;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.05); }
    100% { transform: translate(-50%, -50%) scale(1); }
}

.upload-message svg {
    margin-bottom: 12px;
    color: #1a6ed8;
    transition: transform 0.3s ease;
}

.upload-area:hover .upload-message svg {
    transform: scale(1.1);
}

.upload-message {
    margin-bottom: 12px;
    pointer-events: none;
}

.browse-btn {
    color: #1a6ed8;
    font-weight: 600;
    text-decoration: underline;
    cursor: pointer;
    transition: color 0.2s;
}

.browse-btn:hover {
    color: #155bb5;
}

.file-size-limit {
    color: #222;
    font-size: 1rem;
    margin: 0;
}

.file-list {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 24px;
}
.file-item {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 6px rgba(26,110,216,0.08);
    padding: 12px 10px;
    width: 160px;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: box-shadow 0.2s;
}
.file-item:hover {
    box-shadow: 0 4px 16px rgba(26,110,216,0.13);
}
.file-preview img {
    max-width: 64px;
    max-height: 64px;
    border-radius: 6px;
    margin-bottom: 6px;
    background: #f7f8fa;
}
.file-name {
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 4px;
    text-align: center;
    word-break: break-all;
}
.file-status {
    font-size: 0.85rem;
    color: #1a6ed8;
    margin-bottom: 8px;
}
.preview-text {
    font-size: 0.8rem;
    color: #666;
    margin-top: 4px;
    text-align: center;
}
.file-actions {
    display: flex;
    gap: 8px;
}
.file-btn {
    padding: 4px 12px;
    border-radius: 6px;
    border: none;
    background: #e3eaf6;
    color: #1a6ed8;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}
.file-btn:hover {
    background: #1a6ed8;
    color: #fff;
}

.actions {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin: 32px 0 24px 0;
    flex-wrap: wrap;
}
.actions .btn {
    min-width: 180px;
    font-size: 1.08rem;
    padding: 16px 24px;
    box-shadow: none;
    white-space: nowrap;
}

.options-panel > div {
    margin-top: 16px;
    margin-bottom: 8px;
}
.options-panel label {
    font-weight: 500;
    margin-right: 8px;
}
.options-panel select, .options-panel input[type=range] {
    padding: 4px 8px;
    border-radius: 6px;
    border: 1px solid #c3d0e8;
    font-size: 1rem;
    margin-left: 4px;
}

.tooltip-wrap {
    position: relative;
    display: inline-block;
    margin-left: 6px;
}
.tooltip-icon {
    display: inline-block;
    width: 18px;
    height: 18px;
    background: #e3eaf6;
    color: #1a6ed8;
    border-radius: 50%;
    text-align: center;
    font-weight: bold;
    font-size: 1rem;
    line-height: 18px;
    cursor: pointer;
    border: 1px solid #c3d0e8;
    transition: background 0.2s, color 0.2s;
}
.tooltip-icon:hover {
    background: #1a6ed8;
    color: #fff;
}
.tooltip-text {
    visibility: hidden;
    opacity: 0;
    width: 260px;
    background: #fff;
    color: #222;
    text-align: left;
    border-radius: 8px;
    border: 1px solid #c3d0e8;
    box-shadow: 0 2px 12px rgba(26,110,216,0.10);
    padding: 12px 16px;
    position: absolute;
    z-index: 10;
    left: 50%;
    top: 130%;
    transform: translateX(-50%);
    transition: opacity 0.2s;
    font-size: 0.98rem;
    pointer-events: none;
}
.tooltip-wrap:hover .tooltip-text,
.tooltip-wrap:focus-within .tooltip-text {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
}

.share-block {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 6px rgba(26,110,216,0.06);
    padding: 18px 16px;
    margin: 32px 0 24px 0;
    text-align: center;
}
.share-block h3 {
    margin-top: 0;
    margin-bottom: 12px;
}
.share-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    margin-bottom: 8px;
}
.share-btn {
    display: inline-block;
    padding: 8px 18px;
    border-radius: 8px;
    background: #e3eaf6;
    color: #1a6ed8;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid #c3d0e8;
    transition: background 0.2s, color 0.2s;
    cursor: pointer;
    font-size: 1rem;
}
.share-btn:hover, .share-btn:focus {
    background: #1a6ed8;
    color: #fff;
}
.share-btn.copy {
    background: #f7f8fa;
    color: #444;
    border-style: dashed;
}
.seo-extended {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 6px rgba(26,110,216,0.04);
    padding: 24px 18px;
    margin-bottom: 32px;
    margin-top: 24px;
}
.seo-extended h2, .seo-extended h3 {
    color: #1a6ed8;
    margin-top: 0;
}
.seo-extended ul {
    margin: 0 0 16px 18px;
    padding: 0;
}
.seo-extended li {
    margin-bottom: 6px;
}
.seo-extended b {
    color: #155bb5;
}

.converter-card .btn {
    min-width: 160px;
    padding: 14px 28px;
    margin-top: 8px;
}

@media (min-width: 900px) {
  .converters-grid {
    justify-content: center;
  }
}

/* File status styles */
.file-status.converting {
    color: #f59e0b;
    font-weight: 600;
}

.file-status.converted {
    color: #10b981;
    font-weight: 600;
}

.file-status.error {
    color: #ef4444;
    font-weight: 600;
}

/* Progress bar styles */
.progress-container {
    background: #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
    margin: 16px 0;
}

.progress-bar {
    height: 8px;
    background: linear-gradient(90deg, #1a6ed8, #155bb5);
    transition: width 0.3s ease;
    border-radius: 8px;
}

.progress-bar.error {
    background: linear-gradient(90deg, #ef4444, #dc2626);
}

/* Loading spinner animation */
.spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Preview loading and error states */
.preview-loading, .preview-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #6b7280;
}

.preview-error {
    color: #ef4444;
}

.preview-loading svg {
    margin-bottom: 8px;
} 