/* Global */
body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: radial-gradient(circle at top left, #e0f2fe 0, #f4f4ff 40%, #fdf2ff 80%);
    color: #111827;
    margin: 0;
}

/* Top bar */
.topbar {
    background: linear-gradient(90deg, #0ea5e9, #6366f1);
    color: #fff;
    padding: 0.75rem 0;
}

.brand {
    display: flex;
    align-items: center;
    font-weight: 600;
    letter-spacing: .03em;
}

.brand-logo {
    width: 30px;
    height: 30px;
    border-radius: 999px;
    background: rgba(255,255,255,0.15);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: .5rem;
    font-size: .85rem;
    font-weight: 700;
}

.brand-text {
    font-size: 1rem;
}

.top-link {
    color: #e0f2fe;
    font-size: .9rem;
    text-decoration: none;
    padding: .25rem .75rem;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,0.3);
    transition: all .2s ease;
}

.top-link:hover {
    color: #0f172a;
    background: #e0f2fe;
}

/* Layout */
.main-wrapper {
    padding-top: 2.5rem;
    padding-bottom: 2rem;
    max-width: 760px;
}

/* Hero */
.hero-title {
    font-size: 1.9rem;
    font-weight: 700;
    color: #0f172a;
}

.hero-subtitle {
    margin-top: .25rem;
    color: #6b7280;
    font-size: .95rem;
}

/* Card */
.glass-card {
    border-radius: 18px;
    border: 1px solid rgba(148, 163, 184, 0.3);
    background: rgba(255, 255, 255, 0.9);
    box-shadow:
        0 12px 30px rgba(15, 23, 42, 0.08),
        0 0 0 1px rgba(255, 255, 255, 0.6);
}

/* Input */
.link-input {
    border-radius: 999px 0 0 999px !important;
    border: 1px solid #cbd5f5;
    padding-left: 1.2rem;
}

.link-input:focus {
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.35);
    border-color: transparent;
}

/* Main download button */
.btn-download-main {
    border-radius: 0 999px 999px 0 !important;
    border: none;
    padding: 0 .8rem;
    min-width: 135px;
    font-weight: 600;
    letter-spacing: .03em;
    background: linear-gradient(135deg, #0ea5e9, #6366f1);
    color: #fff;
    box-shadow: 0 8px 18px rgba(59, 130, 246, 0.35);
    transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}

.btn-download-main:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 12px 26px rgba(59, 130, 246, 0.45);
    filter: brightness(1.05);
}

.btn-download-main:disabled {
    opacity: .7;
    cursor: wait;
}

/* Result card */
.result-card {
    margin-top: 1rem;
    padding: 1.2rem 1.4rem;
}

.preview-col {
    padding: .75rem;
    border-right: 1px dashed rgba(148, 163, 184, 0.5);
}

@media (max-width: 767.98px) {
    .preview-col {
        border-right: none;
        border-bottom: 1px dashed rgba(148, 163, 184, 0.5);
        margin-bottom: .75rem;
    }
}

/* Thumbnail */
.video-thumb {
    max-height: 180px;
    object-fit: cover;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.35);
}

.thumb-placeholder {
    width: 140px;
    height: 80px;
    border-radius: 14px;
    border: 2px dashed rgba(148, 163, 184, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(148, 163, 184, 0.9);
    font-size: 2rem;
}

.thumb-icon {
    transform: translateX(3px);
}

/* Title / source */
.video-title {
    font-weight: 600;
    color: #0f172a;
}

.video-source {
    color: #6b7280;
    word-break: break-all;
}

/* Download link buttons */
.link-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
}

.btn-download-variant {
    border-radius: 999px;
    padding: .45rem 1.1rem;
    font-size: .9rem;
    font-weight: 600;
    border: none;
    background: linear-gradient(135deg, #22c55e, #10b981);
    color: #ecfdf5;
    box-shadow: 0 8px 18px rgba(16, 185, 129, .35);
    text-decoration: none !important;
    transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}

.btn-download-variant:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 26px rgba(16, 185, 129, .45);
    filter: brightness(1.05);
    color: #ecfdf5;
}

/* Download another */
.btn-rounded {
    border-radius: 999px;
    padding-left: 1.4rem;
    padding-right: 1.4rem;
}

/* Footer */
.footer {
    background: transparent;
}

/* Ad box spacing */
#adBox {
    max-width: 728px;
    margin: 0 auto;
}
