/* Variables */

:root {
    --primary-color: rgb(30, 110, 255);
    --primary-color-text-contrast: rgb(255, 255, 255);

    --primary-background-color: rgb(255, 255, 255);
    --secondary-background-color: rgb(245, 245, 245);
    --tertiary-background-color: rgb(225, 225, 225);
    --quaternary-background-color: rgb(204, 204, 204);
    --background-overlay-color: rgba(0, 0, 0, 0.5);

    --font-family: Arial, Helvetica, sans-serif;
    --primary-font-color: rgb(0, 0, 0);
    --secondary-font-color: rgb(100, 100, 100);
    --tertiary-font-color: rgb(150, 150, 150);
    --font-link-color: rgb(30, 110, 255);
    --icon-colour-filter-invert: invert(0);
    --display-light-theme-icon: block;
    --display-dark-theme-icon: none;

    --side-gap: 15px;
    --border-radius: 30px;
    --page-content-max-width: 750px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --primary-color: rgb(8, 119, 255);
        --primary-color-text-contrast: rgb(255, 255, 255);

        --primary-background-color: rgb(24, 24, 24);
        --secondary-background-color: rgb(35, 35, 35);
        --tertiary-background-color: rgb(60, 60, 60);
        --quaternary-background-color: rgb(75, 75, 75);
        --background-overlay-color: rgba(255, 255, 255, 0.1);

        --font-family: Arial, Helvetica, sans-serif;
        --primary-font-color: rgb(255, 255, 255);
        --secondary-font-color: rgb(155, 155, 155);
        --tertiary-font-color: rgb(100, 100, 100);
        --font-link-color: rgb(81, 142, 255);
        --icon-colour-filter-invert: invert(1);
        --display-light-theme-icon: none;
        --display-dark-theme-icon: block;
    }
}

:root[data-theme="dark"] {
    --primary-color: rgb(8, 119, 255);
    --primary-color-text-contrast: rgb(255, 255, 255);

    --primary-background-color: rgb(24, 24, 24);
    --secondary-background-color: rgb(35, 35, 35);
    --tertiary-background-color: rgb(60, 60, 60);
    --quaternary-background-color: rgb(75, 75, 75);
    --background-overlay-color: rgba(255, 255, 255, 0.1);

    --font-family: Arial, Helvetica, sans-serif;
    --primary-font-color: rgb(255, 255, 255);
    --secondary-font-color: rgb(155, 155, 155);
    --tertiary-font-color: rgb(100, 100, 100);
    --font-link-color: rgb(81, 142, 255);
    --icon-colour-filter-invert: invert(1);
    --display-light-theme-icon: none;
    --display-dark-theme-icon: block;
}

:root[data-theme="light"] {
    --primary-color: rgb(30, 110, 255);

    --primary-background-color: rgb(255, 255, 255);
    --secondary-background-color: rgb(245, 245, 245);
    --tertiary-background-color: rgb(225, 225, 225);
    --quaternary-background-color: rgb(204, 204, 204);
    --background-overlay-color: rgba(0, 0, 0, 0.5);

    --font-family: Arial, Helvetica, sans-serif;
    --primary-font-color: rgb(0, 0, 0);
    --secondary-font-color: rgb(100, 100, 100);
    --tertiary-font-color: rgb(150, 150, 150);
    --font-link-color: rgb(30, 110, 255);
    --icon-colour-filter-invert: invert(0);
    --display-light-theme-icon: block;
    --display-dark-theme-icon: none;
}

/* Fonts */
/* resource/fonts/Saira Extra Condensed/SairaExtraCondensed-Medium.ttf for text logo */
@font-face {
    font-family: 'Saira Extra Condensed';
    src: url('/resource/fonts/Saira Extra Condensed/SairaExtraCondensed-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
}

/* Transitions */
* {
    transition: background-color 0.3s,
    color 0.3s, border-color 0.3s,
    box-shadow 0.3s, opacity 0.3s;
}

* {
    box-sizing: border-box;
}

html,
body {
    overscroll-behavior: none;
    -webkit-overflow-scrolling: auto;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--font-family);
    color: var(--primary-font-color);
    background-color: var(--secondary-background-color);
}

.clock-section {
    height: 93vh;
    background-color: var(--secondary-background-color);
}

header {
    margin: 0;
    padding: 0 var(--side-gap);
    background-color: var(--secondary-background-color);
    position: sticky;
    top: 0;
    bottom: calc(-1 * var(--border-radius));
    z-index: 10;
}

header * {
    margin: 0;
}

header .pseudo-div-radius {
    border-radius: var(--border-radius) var(--border-radius) 0px 0px;
    height: calc(var(--border-radius) / 2);
    background-color: var(--primary-background-color);
    margin: 0;
}

main {
    margin: 0;
    padding: 0;
    background-color: var(--secondary-background-color);
}

main .stylised-container {
    margin: 0px var(--side-gap);
    padding: 0 calc(var(--side-gap) * 1.5);
    background-color: var(--primary-background-color);
    min-height: 100vh;
}

main .pseudo-div-radius-container {
    width: 100%;
    background-color: var(--secondary-background-color);
    position: sticky;
    bottom: 0;
    padding-bottom: var(--side-gap);
}

main .pseudo-div-radius-container .pseudo-div-radius {
    border-radius: 0px 0px var(--border-radius) var(--border-radius);
    height: calc(var(--border-radius) / 2);
    background-color: var(--primary-background-color);
    margin: 0 var(--side-gap);
}

footer {
    margin: 0;
    background-color: var(--secondary-background-color);
}

button {
    cursor: pointer;
}

a {
    color: var(--font-link-color);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.noselect {
    user-select: none;
    /* Standard */
    -webkit-user-select: none;
    /* Safari */
    -moz-user-select: none;
    /* Firefox */
    -ms-user-select: none;
    /* Old IE/Edge */
    -webkit-user-drag: none;
    /* Safari/Chrome */
    pointer-events: auto;
    /* ensure clicks still register */
}

/* Header content */
header .header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 7vh;
}

/* Header Logo */
header .logo {
    display: flex;
    align-items: center;
    height: 100%;
    gap: 10px;
    font-family: 'Saira Extra Condensed', Arial, Helvetica, sans-serif;
}

header .logo img {
    width: 30px;
    height: auto;
}

header .logo .logo-image.light-mode {
    display: var(--display-light-theme-icon);
}

header .logo .logo-image.dark-mode {
    display: var(--display-dark-theme-icon);
}

/* Header nav */
header nav ul {
    list-style-type: none;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 15px;
    height: 100%;
}

header a {
    text-decoration: none;
    color: var(--secondary-font-color);
}

/* Settings section */
.settings-panel-section,
.shared-configuration-section {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 20;
    width: 100%;
    height: 100%;
    background-color: var(--background-overlay-color);
    backdrop-filter: blur(10px);
    margin: 0;
}

.settings-panel-section .settings-panel-overlay,
.shared-configuration-section .shared-configuration-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 600px;
    background-color: var(--primary-background-color);
    border-radius: var(--border-radius);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    padding: 10px 30px 30px;
    margin: 0 auto;
}

.settings-panel-section .settings-panel-overlay .settings-panel-header,
.shared-configuration-section .shared-configuration-overlay .shared-configuration-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.settings-panel-section .settings-panel-overlay .settings-panel-header button,
.shared-configuration-section .shared-configuration-overlay .shared-configuration-header button {
    border: none;
    background-color: var(--tertiary-background-color);
    opacity: 1;
    padding: 5px 15px;
    width: fit-content;
    height: fit-content;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 90px;
    color: var(--primary-font-color);
    gap: 3px;
}

.settings-panel-section .settings-panel-overlay .settings-panel-header button img,
.shared-configuration-section .shared-configuration-overlay .shared-configuration-header button img {
    filter: var(--icon-colour-filter-invert);
}

.settings-panel-section .settings-panel-overlay .settings-panel-header button:hover,
.shared-configuration-section .shared-configuration-overlay .shared-configuration-header button:hover {
    opacity: 1;
    background-color: var(--quaternary-background-color);
}

.settings-panel-section .settings-panel-overlay .settings-content,
.shared-configuration-section .shared-configuration-overlay .shared-configuration-content {
    margin: 30px 20px;
}

.shared-configuration-section .shared-configuration-overlay .shared-configuration-content .settings-review {
    background-color: var(--secondary-background-color);
    padding: 10px 18px;
    border-radius: 15px;
}

.shared-configuration-section .shared-configuration-overlay .shared-configuration-content .shared-configuration-actions {
    display: flex;
    flex-direction: column;
    gap: 7px;
    margin-top: 15px;
}


.shared-configuration-section .shared-configuration-overlay .shared-configuration-content .smaller-note {
    font-size: 0.85rem;
    color: var(--secondary-font-color);
}

/* clock section */
.clock-section .section-header {
    display: flex;
    justify-content: flex-end;
    align-items: right;
    height: 7vh;
    padding: var(--side-gap);
    gap: 12px;
}

.clock-section .section-header button {
    border: none;
    background-color: transparent;
    opacity: 0.6;
    padding: 10px;
    width: fit-content;
    height: fit-content;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 100%;
}

.clock-section .section-header button img {
    width: 25px;
    height: 25px;
    filter: var(--icon-colour-filter-invert);
}

.clock-section .section-header button:hover {
    opacity: 0.7;
    background-color: var(--tertiary-background-color);
}

.clock-section .clock-outer-circle {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 85vh;
}

.clock-section .clock-circle {
    width: min(600px, 80vw);
    height: min(600px, 80vw);
    border: 10px solid var(--primary-color);
    border-radius: 50%;
    background-color: var(--secondary-background-color);
}

.clock-circle .alarming {
    background-color: var(--primary-color);
}

.clock-circle .alarming .timer-label,
.clock-circle .alarming .timer-display {
    color: var(--primary-color-text-contrast);
}

.clock-circle .clock-content-display {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.clock-circle .clock-content-display .timer-label {
    font-size: 1.5rem;
    color: var(--secondary-font-color);
    margin: 3% 0 0;
    padding: 0 11%;
    width: 100%;
    text-align: center;
}

.clock-circle .clock-content-display .timer-display {
    font-size: 9rem;
    color: var(--primary-color);
    font-weight: bold;
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

.clock-circle .clock-content-display .timer-controls {
    width: 60%;
}

.clock-circle .timer-controls .primary-button-group {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
}

.clock-circle .timer-controls .primary-button-group button {
    border: 1px solid var(--primary-background-color);
    background-color: var(--tertiary-background-color);
    border-radius: 15px;
    padding: 10px 20px;
    margin: 0 2px;
    width: 100%;
}

.clock-circle .timer-controls .primary-button-group button:hover,
.clock-circle .timer-controls .secondary-button-group button:hover {
    background-color: var(--quaternary-background-color);
}

.clock-circle .timer-controls .secondary-button-group {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
}

.clock-circle .timer-controls .secondary-button-group button {
    border: 1px solid var(--primary-background-color);
    background-color: var(--tertiary-background-color);
    border-radius: 15px;
    padding: 5px 20px;
    margin: 0 2px 0;
    width: 100%;
    height: 55px;
    text-align: left;
}

.clock-circle .timer-controls .primary-button-group button:disabled,
.clock-circle .timer-controls .primary-button-group button:hover:disabled,
.clock-circle .timer-controls .secondary-button-group button:disabled,
.clock-circle .timer-controls .secondary-button-group button:hover:disabled {
    opacity: 0.7;
    color: var(--secondary-font-color);
    background-color: var(--tertiary-background-color);
    cursor: not-allowed;
}

.clock-circle .timer-controls .primary-button-group button:disabled img,
.clock-circle .timer-controls .primary-button-group button:hover:disabled img,
.clock-circle .timer-controls .secondary-button-group button:disabled img,
.clock-circle .timer-controls .secondary-button-group button:hover:disabled img {
    opacity: 0.6;
}

.clock-circle button {
    font-size: 0.9rem;
    font-weight: bold;
    color: var(--primary-font-color);
}

.clock-circle button img {
    filter: var(--icon-colour-filter-invert);
    width: 25px;
    height: 25px;

}

.clock-circle .timer-controls .secondary-button-group .flex {
    display: flex;
    align-items: center;
    gap: 5px;
    justify-content: center;
}

.scroll-indicator {
    position: absolute;
    bottom: 1.9vh;
    left: 50%;
    transform: translateX(-50%);
    z-index: 15;
    color: var(--tertiary-font-color);
    font-size: 0.8rem;
}

.scroll-indicator .arrow-down img {
    position: absolute;
    bottom: -100%;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: auto;
    opacity: 0.3;
    filter: var(--icon-colour-filter-invert);
}

/* Main content */
main .page-content {
    width: 100%;
    max-width: var(--page-content-max-width);
    margin: 0 auto;
    padding: 30px 10px;
}

main .page-content ol li {
    margin: 10px 0;
}

.page-content .content-text-section {
    margin-bottom: 35px;
    line-height: 1.4;
}

.page-content .youtube-video {
    width: 80%;
    max-width: 650px;
    height: auto;
    aspect-ratio: 16 / 9;
    margin: 10px auto;
    display: block;
    align-items: center;
    
    border-radius: 15px;
}

.break-schedule-options {}

.break-schedule-option {
    display: flex;
    align-items: center;
    gap: 30px;
    margin-bottom: 25px;
    background-color: var(--secondary-background-color);
    padding: 20px 20px;
    border-radius: 15px;
}

.break-schedule-option .icon .break-schedule-icon {
    width: 80px;
    height: auto;
    filter: var(--icon-colour-filter-invert);
    opacity: 0.4;
}

.break-schedule-option h4 {
    margin: 0 0 10px;
}

.break-schedule-option p {
    margin: 0;
    line-height: 1.1;
    font-size: 0.95rem;
}

.break-schedule-option .break-schedule-footer {
    margin-top: 10px;
    font-size: 0.95rem;
}

footer .footer-content {
    width: 100%;
    padding: 0 calc(var(--side-gap) * 1.5) calc(var(--side-gap) * 1);
    margin: 0 auto;
}

footer .footer-content p {
    font-size: 0.85rem;
    color: var(--secondary-font-color);
    line-height: 1.4;
}

/* Screen sizes:
2560px - UltraWide monitors
1920px - monitors
1440px - large laptops
1024px - laptops / large tablets (landscape)
795px - tablets (portrait)
550px - small tablets (portrait) / large phones (landscape)
440px - large phones
380px - medium phones
370px - small phones
*/

/* Displays smaller than 795px */
@media (max-width: 795px) {
    .clock-section {
        height: 91vh;
    }

    /* Header content */
    header .header-content {
        display: flex;
        flex-direction: column;
        justify-content: normal;
        align-items: normal;
        min-height: 9vh;
    }

    /* Header nav */
    header nav ul {
        justify-content: left;
        margin-top: 0px;
        padding: 0;
    }

    /* clock section */
    .clock-section .clock-outer-circle {
        height: 80vh;
    }

    .clock-section .clock-circle {
        width: 500px;
        height: 500px;
        border-width: 8.33px;
    }

    .clock-circle .clock-content-display .timer-label {
        font-size: 1.25rem;
    }

    .clock-circle .clock-content-display .timer-display {
        font-size: 7.49rem;
    }

    .clock-circle .clock-content-display .timer-controls {
        width: 65%;
    }

    .clock-circle .timer-controls .primary-button-group {
        gap: 3.33px;
    }

    .clock-circle .timer-controls .primary-button-group button {
        padding: 8.33px 16.66px;
        margin: 0 1.5px;
    }

    .clock-circle .timer-controls .secondary-button-group {
        gap: 3.33px;
        margin-top: 6.66px;
    }

    .clock-circle .timer-controls .secondary-button-group button {
        padding: 8.33px 16.66px;
        margin: 0 1.5px;
        height: 45.83px;
    }

    .clock-circle button {
        font-size: 0.8rem;
        /* Abnormal: Does not follow rest of the scalling factors by 16.67% */
    }

    .clock-circle button img {
        filter: var(--icon-colour-filter-invert);
        width: 20.83px;
        height: 20.83px;

    }

    .clock-circle .timer-controls .secondary-button-group .flex {
        gap: 4.16px;
    }

    .scroll-indicator {
        display: none;
    }

    /* Main content */
    main .page-content {
        padding: 10px;
    }
}

/* Displays smaller than 575px */
@media (max-width: 575px) {

    :root {
        --side-gap: 8px;
    }

    .clock-section {
        height: 93vh;
    }

    /* clock section */
    .clock-section .clock-outer-circle {
        /* height: 80vh; */
    }

    .clock-section .clock-circle {
        width: 400px;
        height: 400px;
        border-width: 6.66px;
    }

    .clock-circle .clock-content-display .timer-label {
        font-size: 1rem;
    }

    .clock-circle .clock-content-display .timer-display {
        font-size: 5.99rem;
    }

    .clock-circle .clock-content-display .timer-controls {
        width: 72%;
    }

    .clock-circle .timer-controls .primary-button-group {
        gap: 2.66px;
    }

    .clock-circle .timer-controls .primary-button-group button {
        padding: 6.66px 13.33px;
        margin: 0 1.2px;
    }

    .clock-circle .timer-controls .secondary-button-group {
        gap: 2.66px;
        margin-top: 5.33px;
    }

    .clock-circle .timer-controls .secondary-button-group button {
        padding: 6.66px 13.33px;
        margin: 0 1.2px;
        height: 36.66px;
    }

    .clock-circle button {
        font-size: 0.7rem;
        /* Abnormal: Does not follow rest of the scalling factors by 16.67% */
    }

    .clock-circle button img {
        filter: var(--icon-colour-filter-invert);
        width: 16.66px;
        height: 16.66px;

    }

    .clock-circle .timer-controls .secondary-button-group .flex {
        gap: 3.33px;
    }

    /* Header content */
    header .header-content {
        min-height: 7vh;
    }

    header .main-nav {
        display: none;
    }

    /* Main content */
    main .page-content {
        padding: 7px 10px;
    }
}

/* Displays smaller than 440px */
@media (max-width: 440px) {

    :root {
        --side-gap: 6px;
    }

    .clock-section .clock-circle {
        width: 350px;
        height: 350px;
        border-width: 5.83px;
    }

    .clock-circle .clock-content-display .timer-label {
        font-size: 0.87rem;
    }

    .clock-circle .clock-content-display .timer-display {
        font-size: 5.24rem;
    }

    main .stylised-container {
        padding: 0;
    }

    /* Main content */
    main .page-content {
        padding: 10px 17px;
        /* Abnormal: Does not follow rest of the scalling factors by 12.50% */
    }
}

/* Displays smaller than 370px */
@media (max-width: 370px) {

    :root {
        --side-gap: 7px;
    }

    .clock-section .clock-circle {
        width: 330px;
        height: 330px;
        border-width: 5px;
    }
}

/* Displays smaller than 370px */
@media (max-width: 360px) {
    .clock-section .clock-circle {
        transform: scale(0.9);
    }
}