Details:
Content within this query (anything prior to 576px):
@media (max-width: 575.98px) {
.custom-txt-color {color: #000000;}
}
..will be displayed in black (#000000)
Upon reaching 576px:
@media (min-width: 576px) and (max-width: 767.98px) {
.custom-txt-color {color: #666000;}
}
..it will change to dark green (#666000)
In the absence of a max-width, it remains as follows:
@media (max-width: 575.98px) {
.custom-txt-color {color: #000000;}
}
.....text is black initially, then transforms to:
@media (min-width: 576px) {
.custom-txt-color {color: #666000;}
}
.....as it becomes dark green and retains that color due to no specified max width.
An efficient tool for testing screen sizes<<<<
Handy breakpoint code snippet: (sourced from Bootstrap 4.6 directly):
/* Extra small devices (portrait phones, less than 576px) */
@media (max-width: 575.98px) { ... }
/* Small devices (landscape phones, 576px and up) */
@media (min-width: 576px) and (max-width: 767.98px) { ... }
/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) and (max-width: 991.98px) { ... }
/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) and (max-width: 1199.98px) { ... }
/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) { ... }