UI chnage mobile view and desktop view apllyign css
This commit is contained in:
@@ -2,16 +2,24 @@
|
||||
body {
|
||||
background-color: #f4f6f9;
|
||||
font-family: "Segoe UI", Arial, sans-serif;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
overflow-x: hidden;
|
||||
/* prevent horizontal scroll for page */
|
||||
}
|
||||
|
||||
/* ================= MAIN CONTENT FIX ================= */
|
||||
/* base.html usually gives sidebar width ~250px */
|
||||
/* ================= MAIN CONTENT ================= */
|
||||
.main {
|
||||
margin-left: 260px;
|
||||
padding: 40px 30px;
|
||||
/* sidebar width */
|
||||
padding: 70px 30px 40px 30px;
|
||||
/* top padding for navbar */
|
||||
overflow-x: hidden;
|
||||
/* prevent horizontal scroll */
|
||||
transition: margin-left 0.3s ease;
|
||||
}
|
||||
|
||||
/* ================= CARD / CONTAINER ================= */
|
||||
/* ================= CONTAINER ================= */
|
||||
.container {
|
||||
max-width: 1100px;
|
||||
margin: 0 auto;
|
||||
@@ -19,6 +27,8 @@ body {
|
||||
padding: 35px 40px;
|
||||
border-radius: 12px;
|
||||
box-shadow: 0 8px 22px rgba(0, 0, 0, 0.08);
|
||||
overflow-x: hidden;
|
||||
/* prevent horizontal scroll */
|
||||
}
|
||||
|
||||
/* ================= HEADING ================= */
|
||||
@@ -52,7 +62,6 @@ form select {
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
/* APPLY BUTTON (GREEN) */
|
||||
form button {
|
||||
background-color: #28a745;
|
||||
color: #ffffff;
|
||||
@@ -62,19 +71,32 @@ form button {
|
||||
font-size: 15px;
|
||||
font-weight: 600;
|
||||
cursor: pointer;
|
||||
transition: background 0.3s ease;
|
||||
}
|
||||
|
||||
form button:hover {
|
||||
background-color: #218838;
|
||||
}
|
||||
|
||||
/* ================= TABLE RESPONSIVE ================= */
|
||||
.table-responsive {
|
||||
width: 100%;
|
||||
overflow-x: auto;
|
||||
/* only table scrolls */
|
||||
-webkit-overflow-scrolling: touch;
|
||||
/* smooth scroll on mobile */
|
||||
}
|
||||
|
||||
/* ================= TABLE ================= */
|
||||
table {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
font-size: 14px;
|
||||
min-width: 700px;
|
||||
/* ensures horizontal scroll on small screens */
|
||||
}
|
||||
|
||||
/* Table Head */
|
||||
thead {
|
||||
background-color: #0d6efd;
|
||||
color: #ffffff;
|
||||
@@ -86,6 +108,7 @@ thead th {
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
/* Table Body */
|
||||
tbody td {
|
||||
padding: 12px;
|
||||
text-align: center;
|
||||
@@ -100,7 +123,7 @@ tbody tr:hover {
|
||||
background-color: #eef4ff;
|
||||
}
|
||||
|
||||
/* ================= ACTION LINKS ================= */
|
||||
/* Table action buttons */
|
||||
table a {
|
||||
text-decoration: none;
|
||||
color: #ffffff;
|
||||
@@ -108,9 +131,9 @@ table a {
|
||||
border-radius: 6px;
|
||||
font-size: 13px;
|
||||
display: inline-block;
|
||||
transition: background 0.3s ease;
|
||||
}
|
||||
|
||||
/* Download button */
|
||||
table a[href*="download"] {
|
||||
background-color: #17a2b8;
|
||||
}
|
||||
@@ -119,7 +142,6 @@ table a[href*="download"]:hover {
|
||||
background-color: #138496;
|
||||
}
|
||||
|
||||
/* View button */
|
||||
table a[href*="view"] {
|
||||
background-color: #20c997;
|
||||
}
|
||||
@@ -129,10 +151,12 @@ table a[href*="view"]:hover {
|
||||
}
|
||||
|
||||
/* ================= RESPONSIVE ================= */
|
||||
|
||||
/* Medium screens: tablets */
|
||||
@media (max-width: 992px) {
|
||||
.main {
|
||||
margin-left: 0;
|
||||
padding: 20px;
|
||||
padding: 50px 20px 20px 20px;
|
||||
}
|
||||
|
||||
form {
|
||||
@@ -144,4 +168,40 @@ table a[href*="view"]:hover {
|
||||
form button {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
/* Small screens: mobile */
|
||||
@media (max-width: 576px) {
|
||||
.main {
|
||||
padding: 40px 15px 15px 15px;
|
||||
}
|
||||
|
||||
.container {
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
.container h2 {
|
||||
font-size: 22px;
|
||||
}
|
||||
|
||||
table {
|
||||
font-size: 12px;
|
||||
min-width: 100%;
|
||||
/* table scrolls only */
|
||||
}
|
||||
|
||||
table a {
|
||||
padding: 5px 10px;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
form label {
|
||||
font-size: 13px;
|
||||
}
|
||||
|
||||
form select,
|
||||
form button {
|
||||
font-size: 13px;
|
||||
padding: 8px;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user