downtube / desktop /static /style.css
b4x's picture
Initial commit: DownTube - YouTube Downloader v1.0
f350839
Raw
History Blame Contribute Delete
22.1 kB
/* YouTube Downloader - Desktop Styles */
/* تصميم عصري و نظيف مع دعم RTL */
:root {
--primary: #ff4444;
--primary-dark: #cc0000;
--primary-light: #ff6666;
--secondary: #282828;
--secondary-light: #404040;
--bg-dark: #0f0f0f;
--bg-card: #1a1a1a;
--bg-input: #222222;
--text-primary: #ffffff;
--text-secondary: #aaaaaa;
--text-muted: #666666;
--success: #00c853;
--warning: #ffab00;
--danger: #ff1744;
--info: #448aff;
--border: #333333;
--shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
--radius: 12px;
--radius-sm: 8px;
--transition: all 0.3s ease;
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: 'Cairo', 'Inter', sans-serif;
background: var(--bg-dark);
color: var(--text-primary);
min-height: 100vh;
direction: rtl;
}
.app-container {
max-width: 900px;
margin: 0 auto;
padding: 20px;
min-height: 100vh;
display: flex;
flex-direction: column;
}
/* Header */
.app-header {
background: linear-gradient(135deg, var(--secondary), var(--bg-card));
border-radius: var(--radius);
padding: 20px 24px;
margin-bottom: 24px;
border: 1px solid var(--border);
box-shadow: var(--shadow);
}
.header-content {
display: flex;
justify-content: space-between;
align-items: center;
}
.logo {
display: flex;
align-items: center;
gap: 16px;
}
.logo-icon {
width: 52px;
height: 52px;
background: linear-gradient(135deg, var(--primary), var(--primary-dark));
border-radius: var(--radius-sm);
display: flex;
align-items: center;
justify-content: center;
font-size: 24px;
color: white;
box-shadow: 0 4px 12px rgba(255, 68, 68, 0.3);
}
.logo-text h1 {
font-size: 22px;
font-weight: 800;
background: linear-gradient(to left, var(--primary-light), var(--text-primary));
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
background-clip: text;
}
.logo-text p {
font-size: 13px;
color: var(--text-secondary);
margin-top: 2px;
}
.header-actions {
display: flex;
gap: 10px;
}
.btn-icon {
width: 42px;
height: 42px;
border-radius: var(--radius-sm);
background: var(--bg-input);
border: 1px solid var(--border);
color: var(--text-secondary);
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
font-size: 16px;
transition: var(--transition);
}
.btn-icon:hover {
background: var(--secondary-light);
color: var(--text-primary);
border-color: var(--primary);
}
/* Card */
.card {
background: var(--bg-card);
border-radius: var(--radius);
padding: 24px;
margin-bottom: 20px;
border: 1px solid var(--border);
box-shadow: var(--shadow);
transition: var(--transition);
}
.card:hover {
border-color: #444;
}
.section-header {
display: flex;
align-items: center;
gap: 10px;
margin-bottom: 18px;
color: var(--text-primary);
}
.section-header i {
color: var(--primary);
font-size: 18px;
}
.section-header h2 {
font-size: 18px;
font-weight: 700;
}
/* URL Input */
.url-input-group {
display: flex;
gap: 12px;
}
.input-wrapper {
flex: 1;
position: relative;
}
.input-wrapper input {
width: 100%;
padding: 14px 48px 14px 16px;
background: var(--bg-input);
border: 2px solid var(--border);
border-radius: var(--radius-sm);
color: var(--text-primary);
font-size: 15px;
font-family: 'Cairo', sans-serif;
transition: var(--transition);
direction: ltr;
text-align: right;
}
.input-wrapper input:focus {
outline: none;
border-color: var(--primary);
box-shadow: 0 0 0 3px rgba(255, 68, 68, 0.15);
}
.input-wrapper input::placeholder {
color: var(--text-muted);
text-align: right;
direction: rtl;
}
.btn-paste {
position: absolute;
left: 8px;
top: 50%;
transform: translateY(-50%);
background: none;
border: none;
color: var(--text-muted);
cursor: pointer;
padding: 8px;
font-size: 16px;
transition: var(--transition);
}
.btn-paste:hover {
color: var(--primary);
}
/* Buttons */
.btn-primary {
padding: 14px 28px;
background: linear-gradient(135deg, var(--primary), var(--primary-dark));
border: none;
border-radius: var(--radius-sm);
color: white;
font-size: 15px;
font-weight: 700;
font-family: 'Cairo', sans-serif;
cursor: pointer;
display: flex;
align-items: center;
gap: 8px;
transition: var(--transition);
white-space: nowrap;
}
.btn-primary:hover {
transform: translateY(-2px);
box-shadow: 0 6px 20px rgba(255, 68, 68, 0.4);
}
.btn-primary:active {
transform: translateY(0);
}
.btn-primary:disabled {
opacity: 0.5;
cursor: not-allowed;
transform: none;
box-shadow: none;
}
.btn-secondary {
padding: 12px 24px;
background: var(--bg-input);
border: 2px solid var(--border);
border-radius: var(--radius-sm);
color: var(--text-primary);
font-size: 14px;
font-weight: 600;
font-family: 'Cairo', sans-serif;
cursor: pointer;
display: flex;
align-items: center;
gap: 8px;
transition: var(--transition);
white-space: nowrap;
}
.btn-secondary:hover {
border-color: var(--primary);
background: var(--secondary-light);
}
.btn-danger {
padding: 12px 28px;
background: transparent;
border: 2px solid var(--danger);
border-radius: var(--radius-sm);
color: var(--danger);
font-size: 14px;
font-weight: 700;
font-family: 'Cairo', sans-serif;
cursor: pointer;
display: flex;
align-items: center;
gap: 8px;
transition: var(--transition);
margin-top: 16px;
}
.btn-danger:hover {
background: var(--danger);
color: white;
}
.btn-large {
padding: 16px 36px;
font-size: 17px;
}
/* Video Info */
.video-info-grid {
display: grid;
grid-template-columns: 280px 1fr;
gap: 20px;
}
.video-thumbnail {
position: relative;
border-radius: var(--radius-sm);
overflow: hidden;
aspect-ratio: 16/9;
}
.video-thumbnail img {
width: 100%;
height: 100%;
object-fit: cover;
}
.duration-badge {
position: absolute;
bottom: 8px;
left: 8px;
background: rgba(0, 0, 0, 0.85);
color: white;
padding: 3px 8px;
border-radius: 4px;
font-size: 12px;
font-weight: 600;
}
.video-details h3 {
font-size: 18px;
font-weight: 700;
line-height: 1.5;
margin-bottom: 10px;
color: var(--text-primary);
}
.video-meta {
display: flex;
gap: 20px;
color: var(--text-secondary);
font-size: 13px;
margin-bottom: 12px;
}
.video-meta i {
margin-left: 4px;
color: var(--text-muted);
}
.video-description {
color: var(--text-secondary);
font-size: 13px;
line-height: 1.6;
max-height: 80px;
overflow: hidden;
text-overflow: ellipsis;
}
/* Options Grid */
.options-grid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 20px;
margin-bottom: 24px;
}
.option-group {
display: flex;
flex-direction: column;
gap: 10px;
}
.option-group > label {
font-size: 14px;
font-weight: 700;
color: var(--text-secondary);
display: flex;
align-items: center;
gap: 8px;
}
.option-group > label i {
color: var(--primary);
}
.radio-group {
display: flex;
gap: 8px;
flex-wrap: wrap;
}
.radio-card {
cursor: pointer;
}
.radio-card input {
display: none;
}
.radio-label {
display: flex;
align-items: center;
gap: 6px;
padding: 10px 18px;
background: var(--bg-input);
border: 2px solid var(--border);
border-radius: var(--radius-sm);
font-size: 14px;
font-weight: 600;
color: var(--text-secondary);
transition: var(--transition);
}
.radio-card input:checked + .radio-label {
border-color: var(--primary);
background: rgba(255, 68, 68, 0.1);
color: var(--primary);
}
.radio-label:hover {
border-color: #555;
}
.flag {
font-size: 16px;
}
.toggle-card {
cursor: pointer;
display: flex;
align-items: flex-start;
gap: 10px;
}
.toggle-card input {
display: none;
}
.toggle-label {
position: relative;
padding-right: 44px;
font-size: 13px;
color: var(--text-secondary);
line-height: 1.5;
}
.toggle-label::before {
content: '';
position: absolute;
right: 0;
top: 2px;
width: 36px;
height: 20px;
background: var(--bg-input);
border: 2px solid var(--border);
border-radius: 10px;
transition: var(--transition);
}
.toggle-label::after {
content: '';
position: absolute;
right: 4px;
top: 6px;
width: 12px;
height: 12px;
background: var(--text-muted);
border-radius: 50%;
transition: var(--transition);
}
.toggle-card input:checked + .toggle-label::before {
background: rgba(255, 68, 68, 0.2);
border-color: var(--primary);
}
.toggle-card input:checked + .toggle-label::after {
right: 20px;
background: var(--primary);
}
/* Download Actions */
.download-actions {
display: flex;
gap: 12px;
justify-content: center;
flex-wrap: wrap;
}
/* Progress */
.progress-container {
margin-bottom: 24px;
}
.progress-bar {
height: 12px;
background: var(--bg-input);
border-radius: 6px;
overflow: hidden;
margin-bottom: 10px;
}
.progress-fill {
height: 100%;
background: linear-gradient(90deg, var(--primary), var(--primary-light));
border-radius: 6px;
transition: width 0.5s ease;
position: relative;
}
.progress-fill::after {
content: '';
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: linear-gradient(
90deg,
transparent,
rgba(255, 255, 255, 0.2),
transparent
);
animation: shimmer 2s infinite;
}
@keyframes shimmer {
0% { transform: translateX(-100%); }
100% { transform: translateX(100%); }
}
.progress-info {
display: flex;
justify-content: space-between;
font-size: 13px;
color: var(--text-secondary);
}
#progressPercent {
color: var(--primary);
font-weight: 700;
font-size: 15px;
}
/* Steps */
.steps-container {
display: flex;
align-items: center;
justify-content: center;
gap: 0;
margin-bottom: 20px;
padding: 16px 0;
}
.step {
display: flex;
flex-direction: column;
align-items: center;
gap: 6px;
min-width: 80px;
}
.step-icon {
width: 40px;
height: 40px;
border-radius: 50%;
background: var(--bg-input);
border: 2px solid var(--border);
display: flex;
align-items: center;
justify-content: center;
font-size: 14px;
color: var(--text-muted);
transition: var(--transition);
}
.step span {
font-size: 11px;
color: var(--text-muted);
text-align: center;
font-weight: 600;
}
.step-connector {
width: 40px;
height: 2px;
background: var(--border);
margin: 0 4px;
margin-bottom: 20px;
transition: var(--transition);
}
/* Step States */
.step.active .step-icon {
border-color: var(--primary);
color: var(--primary);
background: rgba(255, 68, 68, 0.1);
animation: pulse 1.5s infinite;
}
.step.active span {
color: var(--primary);
}
.step.completed .step-icon {
border-color: var(--success);
color: var(--success);
background: rgba(0, 200, 83, 0.1);
}
.step.completed span {
color: var(--success);
}
.step-connector.active {
background: var(--primary);
}
.step-connector.completed {
background: var(--success);
}
@keyframes pulse {
0%, 100% { box-shadow: 0 0 0 0 rgba(255, 68, 68, 0.3); }
50% { box-shadow: 0 0 0 8px rgba(255, 68, 68, 0); }
}
.progress-message {
text-align: center;
color: var(--text-secondary);
font-size: 14px;
margin-bottom: 8px;
}
/* Completed */
.completed-files {
display: flex;
flex-direction: column;
gap: 12px;
}
.file-item {
display: flex;
align-items: center;
gap: 14px;
padding: 16px;
background: var(--bg-input);
border-radius: var(--radius-sm);
border: 1px solid var(--border);
transition: var(--transition);
}
.file-item:hover {
border-color: var(--primary);
}
.file-icon {
width: 44px;
height: 44px;
border-radius: var(--radius-sm);
display: flex;
align-items: center;
justify-content: center;
font-size: 20px;
}
.file-icon.video {
background: rgba(255, 68, 68, 0.15);
color: var(--primary);
}
.file-icon.subtitle {
background: rgba(68, 138, 255, 0.15);
color: var(--info);
}
.file-info {
flex: 1;
}
.file-info h4 {
font-size: 14px;
font-weight: 600;
margin-bottom: 2px;
}
.file-info p {
font-size: 12px;
color: var(--text-muted);
}
.file-actions {
display: flex;
gap: 8px;
}
.btn-save {
padding: 8px 16px;
background: var(--primary);
border: none;
border-radius: 6px;
color: white;
font-size: 12px;
font-weight: 600;
font-family: 'Cairo', sans-serif;
cursor: pointer;
display: flex;
align-items: center;
gap: 4px;
transition: var(--transition);
}
.btn-save:hover {
opacity: 0.9;
transform: translateY(-1px);
}
/* Modal */
.modal {
position: fixed;
inset: 0;
background: rgba(0, 0, 0, 0.7);
display: flex;
align-items: center;
justify-content: center;
z-index: 1000;
backdrop-filter: blur(4px);
}
.modal-content {
background: var(--bg-card);
border-radius: var(--radius);
border: 1px solid var(--border);
width: 90%;
max-width: 700px;
max-height: 80vh;
overflow: hidden;
display: flex;
flex-direction: column;
}
.modal-small {
max-width: 400px;
}
.modal-header {
display: flex;
justify-content: space-between;
align-items: center;
padding: 20px 24px;
border-bottom: 1px solid var(--border);
}
.modal-header h2 {
font-size: 18px;
display: flex;
align-items: center;
gap: 10px;
}
.modal-header h2 i {
color: var(--primary);
}
.downloads-list {
padding: 16px;
overflow-y: auto;
max-height: 60vh;
}
.download-item {
display: flex;
align-items: center;
gap: 12px;
padding: 12px;
background: var(--bg-input);
border-radius: var(--radius-sm);
margin-bottom: 8px;
border: 1px solid var(--border);
}
.download-item-icon {
width: 36px;
height: 36px;
border-radius: 6px;
display: flex;
align-items: center;
justify-content: center;
font-size: 16px;
}
.download-item-info {
flex: 1;
}
.download-item-info h4 {
font-size: 13px;
font-weight: 600;
}
.download-item-info p {
font-size: 11px;
color: var(--text-muted);
}
.download-item-actions {
display: flex;
gap: 6px;
}
.btn-sm {
padding: 6px 12px;
font-size: 11px;
border-radius: 6px;
border: none;
cursor: pointer;
font-family: 'Cairo', sans-serif;
font-weight: 600;
transition: var(--transition);
}
.btn-sm.save {
background: var(--primary);
color: white;
}
.btn-sm.delete {
background: transparent;
border: 1px solid var(--danger);
color: var(--danger);
}
.btn-sm:hover {
opacity: 0.8;
}
/* Anti-Ban Info */
.anti-ban-info {
padding: 20px;
}
.anti-ban-item {
display: flex;
justify-content: space-between;
align-items: center;
padding: 10px 0;
border-bottom: 1px solid var(--border);
}
.anti-ban-item:last-child {
border: none;
}
.anti-ban-item label {
font-size: 13px;
color: var(--text-secondary);
}
.anti-ban-item span {
font-size: 13px;
font-weight: 700;
}
.status-active {
color: var(--success);
}
.status-warning {
color: var(--warning);
}
/* Cookies Section */
.cookies-section {
border-color: #444;
}
.cookies-section .section-header {
display: flex;
align-items: center;
gap: 10px;
flex-wrap: wrap;
}
.cookies-desc {
font-size: 13px;
color: var(--text-secondary);
margin-bottom: 16px;
line-height: 1.6;
}
.cookies-desc strong {
color: var(--primary);
}
.cookies-status {
display: flex;
justify-content: space-between;
align-items: center;
padding: 10px 14px;
background: rgba(0, 200, 83, 0.1);
border: 1px solid var(--success);
border-radius: var(--radius-sm);
margin-bottom: 14px;
font-size: 13px;
color: var(--success);
font-weight: 600;
}
.cookies-status.inactive {
background: rgba(255, 68, 68, 0.1);
border-color: var(--danger);
color: var(--danger);
}
.cookies-textarea-wrapper {
position: relative;
}
.btn-paste-icon {
position: absolute;
left: 8px;
top: 8px;
background: var(--bg-input);
border: 1px solid var(--border);
border-radius: 6px;
color: var(--text-muted);
cursor: pointer;
padding: 6px 10px;
font-size: 14px;
transition: var(--transition);
line-height: 1;
}
.btn-paste-icon:hover {
color: var(--primary);
border-color: var(--primary);
}
.cookies-detect {
padding: 8px 14px;
border-radius: var(--radius-sm);
font-size: 12px;
font-weight: 600;
}
.cookies-detect.success {
background: rgba(0, 200, 83, 0.1);
color: var(--success);
border: 1px solid var(--success);
}
.cookies-detect.error {
background: rgba(255, 68, 68, 0.1);
color: var(--danger);
border: 1px solid var(--danger);
}
.cookies-textarea {
width: 100%;
padding: 12px;
background: var(--bg-input);
border: 2px solid var(--border);
border-radius: var(--radius-sm);
color: var(--text-primary);
font-family: 'Courier New', monospace;
font-size: 12px;
direction: ltr;
text-align: left;
resize: vertical;
transition: var(--transition);
}
.cookies-textarea:focus {
outline: none;
border-color: var(--primary);
box-shadow: 0 0 0 3px rgba(255, 68, 68, 0.15);
}
.cookies-textarea::placeholder {
text-align: center;
font-family: 'Cairo', sans-serif;
color: var(--text-muted);
}
.cookies-input-group {
display: flex;
flex-direction: column;
gap: 10px;
margin-bottom: 8px;
}
.cookies-actions {
display: flex;
gap: 10px;
}
.cookies-actions .btn-sm {
padding: 10px 20px;
font-size: 13px;
font-family: 'Cairo', sans-serif;
font-weight: 700;
border: none;
border-radius: var(--radius-sm);
cursor: pointer;
display: flex;
align-items: center;
gap: 6px;
transition: var(--transition);
}
.cookies-or {
text-align: center;
color: var(--text-muted);
font-size: 12px;
margin: 12px 0;
position: relative;
}
.cookies-or::before,
.cookies-or::after {
content: '';
position: absolute;
top: 50%;
width: 40%;
height: 1px;
background: var(--border);
}
.cookies-or::before { left: 0; }
.cookies-or::after { right: 0; }
.cookies-or span {
background: var(--bg-card);
padding: 0 12px;
position: relative;
z-index: 1;
}
.cookies-upload-group {
display: flex;
align-items: center;
gap: 12px;
flex-wrap: wrap;
}
.cookies-filename {
font-size: 12px;
color: var(--text-muted);
max-width: 200px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.cookies-instructions {
margin-top: 16px;
font-size: 13px;
}
.cookies-instructions summary {
cursor: pointer;
color: var(--text-secondary);
font-weight: 600;
display: flex;
align-items: center;
gap: 6px;
padding: 8px 0;
}
.cookies-instructions summary:hover {
color: var(--primary);
}
.cookies-instructions ol {
margin-top: 10px;
padding-right: 24px;
color: var(--text-secondary);
line-height: 2;
}
.cookies-instructions li {
font-size: 13px;
}
.cookies-instructions a {
color: var(--info);
text-decoration: none;
}
.cookies-instructions a:hover {
text-decoration: underline;
}
.badge {
display: inline-flex;
align-items: center;
padding: 3px 12px;
border-radius: 20px;
font-size: 11px;
font-weight: 700;
letter-spacing: 0.5px;
}
.badge-active {
background: rgba(0, 200, 83, 0.15);
color: var(--success);
border: 1px solid var(--success);
}
.badge-inactive {
background: rgba(255, 68, 68, 0.1);
color: var(--danger);
border: 1px solid var(--danger);
}
/* Footer */
.app-footer {
text-align: center;
padding: 20px 0;
color: var(--text-muted);
font-size: 12px;
margin-top: auto;
}
/* Animations */
@keyframes fadeIn {
from { opacity: 0; transform: translateY(10px); }
to { opacity: 1; transform: translateY(0); }
}
.card {
animation: fadeIn 0.4s ease;
}
/* Toast */
.toast {
position: fixed;
bottom: 24px;
left: 50%;
transform: translateX(-50%) translateY(100px);
padding: 14px 24px;
background: var(--secondary);
border: 1px solid var(--border);
border-radius: var(--radius-sm);
color: var(--text-primary);
font-size: 14px;
font-weight: 600;
z-index: 2000;
transition: transform 0.3s ease;
display: flex;
align-items: center;
gap: 10px;
box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}
.toast.show {
transform: translateX(-50%) translateY(0);
}
.toast.success {
border-color: var(--success);
}
.toast.error {
border-color: var(--danger);
}
.toast.info {
border-color: var(--info);
}
/* Responsive */
@media (max-width: 768px) {
.app-container {
padding: 12px;
}
.video-info-grid {
grid-template-columns: 1fr;
}
.options-grid {
grid-template-columns: 1fr;
}
.url-input-group {
flex-direction: column;
}
.steps-container {
flex-wrap: wrap;
gap: 8px;
}
.step-connector {
width: 20px;
}
.download-actions {
flex-direction: column;
}
.btn-large {
width: 100%;
justify-content: center;
}
}