reposnsive design
Enhance responsive design and mobile usability Major CSS overhaul for improved responsiveness and accessibility: - Add .main-container for full viewport coverage - Refactor Home.razor.css with extensive media queries for tablet, desktop, mobile, and print - Improve input, button, and feature section layouts - Add word-break/overflow handling for long text - Support high-DPI, reduced motion, and print styles - Update app.css for better font rendering, touch targets, and mobile performance These changes ensure a more user-friendly experience across all devices.
This commit is contained in:
@@ -3,3 +3,11 @@
|
|||||||
<div class="main-container">
|
<div class="main-container">
|
||||||
@Body
|
@Body
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
.main-container {
|
||||||
|
width: 100%;
|
||||||
|
min-height: 100vh;
|
||||||
|
min-height: 100dvh;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|||||||
+317
-37
@@ -1,3 +1,29 @@
|
|||||||
|
/* Page Background and Container */
|
||||||
|
.page-background {
|
||||||
|
background: linear-gradient(135deg, #1e3c72 0%, #2a5298 50%, #1e88e5 100%);
|
||||||
|
min-height: 100vh;
|
||||||
|
min-height: 100dvh; /* Dynamic viewport height for mobile */
|
||||||
|
padding: 20px 10px 40px 10px; /* Add bottom padding for scroll space */
|
||||||
|
display: block; /* Changed from flex to block for better scroll behavior */
|
||||||
|
position: relative;
|
||||||
|
overflow-x: hidden;
|
||||||
|
overflow-y: auto;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Music notes positioning */
|
||||||
|
.music-notes {
|
||||||
|
position: fixed;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100vw;
|
||||||
|
height: 100vh;
|
||||||
|
height: 100dvh;
|
||||||
|
pointer-events: none;
|
||||||
|
z-index: 1;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
.hero-section {
|
.hero-section {
|
||||||
background: rgba(255, 255, 255, 0.95);
|
background: rgba(255, 255, 255, 0.95);
|
||||||
backdrop-filter: blur(10px);
|
backdrop-filter: blur(10px);
|
||||||
@@ -7,7 +33,12 @@
|
|||||||
text-align: center;
|
text-align: center;
|
||||||
max-width: 600px;
|
max-width: 600px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
margin: 0 auto;
|
margin: 20px auto; /* Center horizontally */
|
||||||
|
position: relative;
|
||||||
|
z-index: 10;
|
||||||
|
/* Ensure content can expand vertically */
|
||||||
|
min-height: auto;
|
||||||
|
max-height: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.logo-container {
|
.logo-container {
|
||||||
@@ -31,6 +62,7 @@
|
|||||||
-webkit-background-clip: text;
|
-webkit-background-clip: text;
|
||||||
-webkit-text-fill-color: transparent;
|
-webkit-text-fill-color: transparent;
|
||||||
background-clip: text;
|
background-clip: text;
|
||||||
|
line-height: 1.2;
|
||||||
}
|
}
|
||||||
|
|
||||||
.app-subtitle {
|
.app-subtitle {
|
||||||
@@ -38,6 +70,7 @@
|
|||||||
color: #718096;
|
color: #718096;
|
||||||
margin: 0 0 30px 0;
|
margin: 0 0 30px 0;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
|
line-height: 1.4;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Session info styling */
|
/* Session info styling */
|
||||||
@@ -53,6 +86,7 @@
|
|||||||
font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
|
font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
|
||||||
opacity: 0.8;
|
opacity: 0.8;
|
||||||
transition: opacity 0.2s ease;
|
transition: opacity 0.2s ease;
|
||||||
|
word-break: break-all;
|
||||||
}
|
}
|
||||||
|
|
||||||
.session-info:hover {
|
.session-info:hover {
|
||||||
@@ -79,6 +113,8 @@
|
|||||||
color: #2d3748;
|
color: #2d3748;
|
||||||
transition: all 0.3s ease;
|
transition: all 0.3s ease;
|
||||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
|
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
|
||||||
|
width: 100%;
|
||||||
|
box-sizing: border-box;
|
||||||
}
|
}
|
||||||
|
|
||||||
.url-input:focus {
|
.url-input:focus {
|
||||||
@@ -107,6 +143,8 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 10px;
|
gap: 10px;
|
||||||
|
width: 100%;
|
||||||
|
box-sizing: border-box;
|
||||||
}
|
}
|
||||||
|
|
||||||
.download-btn:hover:not(:disabled) {
|
.download-btn:hover:not(:disabled) {
|
||||||
@@ -216,6 +254,7 @@
|
|||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
color: #0369a1;
|
color: #0369a1;
|
||||||
|
word-wrap: break-word;
|
||||||
}
|
}
|
||||||
|
|
||||||
.output-message p {
|
.output-message p {
|
||||||
@@ -229,6 +268,7 @@
|
|||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 40px;
|
gap: 40px;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
|
margin-bottom: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.feature {
|
.feature {
|
||||||
@@ -237,6 +277,7 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 8px;
|
gap: 8px;
|
||||||
color: #6b7280;
|
color: #6b7280;
|
||||||
|
flex-shrink: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.feature-icon {
|
.feature-icon {
|
||||||
@@ -249,9 +290,10 @@
|
|||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-size: 0.9rem;
|
font-size: 0.9rem;
|
||||||
color: #4b5563;
|
color: #4b5563;
|
||||||
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Progress styles moved from Home.razor */
|
/* Progress styles */
|
||||||
.progress-container {
|
.progress-container {
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
@@ -292,6 +334,7 @@
|
|||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
color: #666;
|
color: #666;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
|
word-wrap: break-word;
|
||||||
}
|
}
|
||||||
|
|
||||||
.progress-container.with-video-details .progress-text {
|
.progress-container.with-video-details .progress-text {
|
||||||
@@ -312,6 +355,7 @@
|
|||||||
|
|
||||||
.download-links-section {
|
.download-links-section {
|
||||||
margin-top: 30px;
|
margin-top: 30px;
|
||||||
|
margin-bottom: 30px; /* Add bottom margin for scroll space */
|
||||||
width: 100%;
|
width: 100%;
|
||||||
max-width: 600px;
|
max-width: 600px;
|
||||||
}
|
}
|
||||||
@@ -328,6 +372,8 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: 12px;
|
gap: 12px;
|
||||||
|
/* Add bottom padding to ensure last item is fully visible */
|
||||||
|
padding-bottom: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.download-item {
|
.download-item {
|
||||||
@@ -352,12 +398,15 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
|
min-width: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.download-title {
|
.download-title {
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: #333;
|
color: #333;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
|
word-wrap: break-word;
|
||||||
|
overflow-wrap: break-word;
|
||||||
}
|
}
|
||||||
|
|
||||||
.download-date {
|
.download-date {
|
||||||
@@ -378,6 +427,7 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 6px;
|
gap: 6px;
|
||||||
|
flex-shrink: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.download-link-btn:hover {
|
.download-link-btn:hover {
|
||||||
@@ -465,6 +515,7 @@
|
|||||||
margin-bottom: 12px;
|
margin-bottom: 12px;
|
||||||
line-height: 1.4;
|
line-height: 1.4;
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
|
overflow-wrap: break-word;
|
||||||
}
|
}
|
||||||
|
|
||||||
.error-message {
|
.error-message {
|
||||||
@@ -475,6 +526,7 @@
|
|||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
color: #c62828;
|
color: #c62828;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
word-wrap: break-word;
|
||||||
}
|
}
|
||||||
|
|
||||||
.conversion-status {
|
.conversion-status {
|
||||||
@@ -508,7 +560,7 @@
|
|||||||
@keyframes pulse {
|
@keyframes pulse {
|
||||||
0%, 100% {
|
0%, 100% {
|
||||||
transform: scale(1);
|
transform: scale(1);
|
||||||
box-shadow: 0 0 0 0 rgba(30, 136, 229, 0.4);
|
box-shadow: 0 0 0 0 rgba(30, 136,229, 0.4);
|
||||||
}
|
}
|
||||||
50% {
|
50% {
|
||||||
transform: scale(1.02);
|
transform: scale(1.02);
|
||||||
@@ -527,86 +579,314 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (min-width: 640px) {
|
/* Responsive Design - Tablet */
|
||||||
|
@media (min-width: 640px) and (max-width: 1024px) {
|
||||||
|
.hero-section {
|
||||||
|
padding: 35px 25px;
|
||||||
|
margin: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
.input-container {
|
.input-container {
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
align-items: stretch;
|
align-items: stretch;
|
||||||
|
gap: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.url-input {
|
.url-input {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
|
font-size: 1rem;
|
||||||
|
padding: 16px 20px;
|
||||||
|
min-width: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.download-btn {
|
.download-btn {
|
||||||
min-width: 180px;
|
min-width: 140px;
|
||||||
}
|
max-width: 180px;
|
||||||
}
|
flex-shrink: 0;
|
||||||
|
font-size: 0.95rem;
|
||||||
@media (max-width: 639px) {
|
padding: 16px 20px;
|
||||||
.hero-section {
|
|
||||||
padding: 30px 20px;
|
|
||||||
margin: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.app-title {
|
|
||||||
font-size: 2rem;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.features {
|
.features {
|
||||||
gap: 30px;
|
gap: 35px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Responsive Design - Large Desktop */
|
||||||
|
@media (min-width: 640px) {
|
||||||
|
.input-container {
|
||||||
|
flex-direction: row;
|
||||||
|
align-items: stretch;
|
||||||
|
gap: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.url-input {
|
||||||
|
flex: 1;
|
||||||
|
min-width: 0; /* Allows flex item to shrink below its content size */
|
||||||
|
}
|
||||||
|
|
||||||
|
.download-btn {
|
||||||
|
min-width: 160px;
|
||||||
|
max-width: 200px;
|
||||||
|
flex-shrink: 0;
|
||||||
|
padding: 18px 24px;
|
||||||
|
font-size: 1rem;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Responsive Design - Mobile */
|
||||||
|
@media (max-width: 639px) {
|
||||||
|
.page-background {
|
||||||
|
padding: 10px 5px 40px 5px; /* Ensure bottom padding for scroll */
|
||||||
|
min-height: 100vh;
|
||||||
|
min-height: 100dvh;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hero-section {
|
||||||
|
padding: 25px 15px;
|
||||||
|
margin: 5px auto; /* Ensure centering */
|
||||||
|
border-radius: 16px;
|
||||||
|
min-width: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.logo {
|
||||||
|
width: 100px;
|
||||||
|
height: 100px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.app-title {
|
||||||
|
font-size: 1.8rem;
|
||||||
|
line-height: 1.1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.app-subtitle {
|
||||||
|
font-size: 1rem;
|
||||||
|
line-height: 1.3;
|
||||||
|
}
|
||||||
|
|
||||||
|
.url-input {
|
||||||
|
font-size: 16px; /* Prevent zoom on iOS */
|
||||||
|
padding: 16px 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.download-btn {
|
||||||
|
font-size: 1rem;
|
||||||
|
padding: 16px 24px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.features {
|
||||||
|
gap: 25px;
|
||||||
|
justify-content: space-around;
|
||||||
}
|
}
|
||||||
|
|
||||||
.feature {
|
.feature {
|
||||||
min-width: 100px;
|
min-width: auto;
|
||||||
|
flex: 1;
|
||||||
|
max-width: 80px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature-icon {
|
||||||
|
font-size: 1.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature span:last-child {
|
||||||
|
font-size: 0.8rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.session-info {
|
.session-info {
|
||||||
font-size: 0.8rem;
|
font-size: 0.75rem;
|
||||||
padding: 6px 12px;
|
padding: 6px 12px;
|
||||||
|
max-width: 100%;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
}
|
}
|
||||||
|
|
||||||
.download-all-btn {
|
.download-all-btn {
|
||||||
min-width: 180px;
|
min-width: 160px;
|
||||||
padding: 14px 20px;
|
padding: 12px 16px;
|
||||||
font-size: 0.9rem;
|
font-size: 0.9rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.zip-info {
|
.zip-info {
|
||||||
font-size: 0.8rem;
|
font-size: 0.75rem;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
.download-item {
|
||||||
/* Responsive Design */
|
flex-direction: column;
|
||||||
@media (max-width: 768px) {
|
align-items: stretch;
|
||||||
|
gap: 12px;
|
||||||
|
padding: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.download-info {
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.download-link-btn {
|
||||||
|
align-self: stretch;
|
||||||
|
justify-content: center;
|
||||||
|
padding: 10px 16px;
|
||||||
|
}
|
||||||
|
|
||||||
.video-info-card {
|
.video-info-card {
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
padding: 15px;
|
||||||
|
gap: 15px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.thumbnail-img {
|
.thumbnail-img {
|
||||||
width: 200px;
|
width: 200px;
|
||||||
height: 112px;
|
height: 112px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.video-meta {
|
.progress-text {
|
||||||
justify-content: center;
|
font-size: 13px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.video-title {
|
||||||
|
font-size: 15px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (max-width: 480px) {
|
/* Extra Small Mobile Devices */
|
||||||
.video-info-card {
|
@media (max-width: 360px) {
|
||||||
padding: 15px;
|
.hero-section {
|
||||||
|
padding: 20px 12px;
|
||||||
|
margin: 3px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.app-title {
|
||||||
|
font-size: 1.6rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.app-subtitle {
|
||||||
|
font-size: 0.9rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.logo {
|
||||||
|
width: 80px;
|
||||||
|
height: 80px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.url-input {
|
||||||
|
padding: 14px 16px;
|
||||||
|
font-size: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.download-btn {
|
||||||
|
padding: 14px 20px;
|
||||||
|
font-size: 0.9rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.features {
|
||||||
|
gap: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature {
|
||||||
|
max-width: 70px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature-icon {
|
||||||
|
font-size: 1.3rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature span:last-child {
|
||||||
|
font-size: 0.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
.thumbnail-img {
|
.thumbnail-img {
|
||||||
width: 160px;
|
width: 160px;
|
||||||
height: 90px;
|
height: 90px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.download-all-btn {
|
||||||
|
min-width: 140px;
|
||||||
|
padding: 10px 14px;
|
||||||
|
font-size: 0.85rem;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.video-meta {
|
/* Landscape Mobile Orientation */
|
||||||
flex-direction: column;
|
@media (max-width: 844px) and (orientation: landscape) {
|
||||||
align-items: center;
|
.page-background {
|
||||||
gap: 8px;
|
padding: 15px 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hero-section {
|
||||||
|
padding: 25px 20px;
|
||||||
|
margin: 10px auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.logo-container {
|
||||||
|
margin-bottom: 25px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.logo {
|
||||||
|
width: 80px;
|
||||||
|
height: 80px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.app-title {
|
||||||
|
font-size: 2rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.download-form {
|
||||||
|
margin-bottom: 25px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.features {
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* High DPI Displays */
|
||||||
|
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
|
||||||
|
.hero-section {
|
||||||
|
backdrop-filter: blur(20px);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Reduced Motion Preference */
|
||||||
|
@media (prefers-reduced-motion: reduce) {
|
||||||
|
.hero-section,
|
||||||
|
.download-btn,
|
||||||
|
.download-item,
|
||||||
|
.video-info-section,
|
||||||
|
.progress-fill,
|
||||||
|
.btn-icon,
|
||||||
|
.download-all-btn,
|
||||||
|
.download-link-btn {
|
||||||
|
animation: none !important;
|
||||||
|
transition: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.processing-spinner {
|
||||||
|
animation: none !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Print Styles */
|
||||||
|
@media print {
|
||||||
|
.page-background {
|
||||||
|
background: white !important;
|
||||||
|
padding: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hero-section {
|
||||||
|
background: white !important;
|
||||||
|
box-shadow: none !important;
|
||||||
|
border: 1px solid #ccc;
|
||||||
|
}
|
||||||
|
|
||||||
|
.music-notes {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.download-btn,
|
||||||
|
.download-link-btn,
|
||||||
|
.download-all-btn {
|
||||||
|
display: none !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user