:root {
    --darkGrey: #7C7C7C;
    --lightGrey: #AFAFAF;
    --darkGreen: #166671;
    --lightGreen: #0fa276;
    --container: #E0E0E0;
    --transparent: #00000000;
    --background: #EDEDED;
}

body {
    background-color: var(--darkGreen);
    min-height: 100vh;
    height: 100%;
    overflow: scroll;
}

* {
    margin: auto;
    box-sizing: border-box;
    font-family: 'Montserrat', sans-serif;
    text-align: center;
}

html {
    background: var(--darkGreen);
}

a {
    width: 99%;
    max-width: 100%;
    text-decoration: none;
}

button {
    width: 100%;
    display: flex;
    place-items: center;
    border-radius: 2rem;
    border: 3px solid #00000000;
    font-size: 24px;
    font-weight: 500;
    color: white;
    padding: 0.4rem 1rem;
    display: flow;
    cursor: pointer;
}

h1 {
    color: white;
    font-size: 2rem;
    font-weight: 500;
}

h2 {
    color: var(--darkGrey);
    font-family: Montserrat;
    font-size: 1rem;
    font-weight: 700;
}

h3 {
    font-size: 1rem;
    font-weight: 500;
    font-style: normal;
}

h4 {
    text-align: center;
    font-size: 1.5rem;
    font-style: normal;
    font-weight: 600;
    line-height: 1.4rem;
}

h5 {
    font-size: 1.25rem;
    font-weight: 500;
}

span {
    font-weight: 600;
}

.page {
    height: 100%;
    max-width: 500px;
    background-color: var(--background);
    min-height: 100vh;
}

.container {
    max-width: 500px;
    margin: auto;
    background-color: white;
    flex-grow: 1;
}

.fitPage {
    position: fixed;
    bottom: 0;
    width: 100%;
    display: flex;
    flex-direction: column;
    max-width: 500px;
    background-color: var(--background);
}

.homeHeroSection {
    padding: 1rem;
    border-bottom-right-radius: 2rem;
    border-bottom-left-radius: 2rem;
    width: 100%;
    max-width: 100vw;
    margin: auto;
    background: var(--darkGreen);
    box-shadow: 4px 4px 4px 0px rgba(0, 0, 0, 0.25);
}

.heroSection {
    padding: 1.5rem 0.5rem 1rem;
    border-bottom-right-radius: 2rem;
    border-bottom-left-radius: 2rem;
    width: 100%;
    max-width: 100vw;
    margin: 0 auto auto;
    background: var(--darkGreen);
    box-shadow: 4px 4px 4px 0px rgba(0, 0, 0, 0.25);
}

.secondSection {
    background-color: var(--container);
    border-radius: 2rem;
    padding: 0.5rem 1rem;
    margin: 1rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
    max-width: 100%;
}

.sectionTitle {
    padding: 5px;
    margin: 0 auto 8px;
    border-bottom: 2px solid;
}

.button {
    text-align: center;
    color: white;
    width: 90%;
    border-radius: 2rem;
    display: grid;
    grid-template-columns: 1fr 15%;
    box-shadow: 2px 2px 4px 0px rgba(0, 0, 0, 0.25);
    position: relative;
    color: white;
    font-size: 24px;
    font-weight: 500;
    padding: 0.4rem 1rem;
    display: flow;
    background-color: var(--lightGreen);
    margin-bottom: 2rem;
}

button img {
    position: absolute;
    right: 30px;
}

.unready {
    background: var(--lightGrey);
}

.ready {
    background: var(--lightGreen);
}

.readyDark {
    background: var(--darkGreen);
}

.buttonIcon {
    height: 2rem;
    margin-right: 5px;
}

.noIcon {
    grid-template-columns: 100% 0;
}

.left {
    margin-left: 0;
}

.right {
    margin-right: 0;
}


/********** HEADER **********/

header {
    display: flex;
    flex-direction: row;
    width: 100%;
    max-width: 500px;
    position: fixed;
    top: 0;
    z-index: 2;
    justify-content: space-around;
    background-color: var(--darkGreen);
    border-radius: 0 0 1rem 1rem;
    left: 50%;
    transform: translateX(-50%);
}

.headerOther {
    box-shadow: 4px 4px 4px 0px rgba(0, 0, 0, 0.25);
}

.headerIcon {
    height: 35px;
    width: 35px;
    margin: 5px;
}

.headerLogo {
    height: 50px;
    margin: 5px;
}

/********** OPERATIONS DASHBOARD **********/

#operationLanding,
#installerLanding {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding-top: 80px;
}

.largeHeroButton {
    background-color: var(--darkGreen);
    box-shadow: 2px 2px 4px 0px rgba(0, 0, 0, 0.25);
    border: 3px solid #ffffff50;
    cursor: pointer;
}

/********** UPCOMING APPOINTMENTS **********/

.upcomingAppSection {
    height: 100%;
    width: 100%;
    display: flex;
    justify-content: center;
}

.upcomingAppContainer {
    margin-top: 1rem;
    height: 100%;
    max-height: 50vh;
    width: 90%;
    display: flex;
    flex-direction: column;
    background: var(--container);
    padding: 0 1rem 1rem;
    border-radius: 2rem;
    overflow-x: hidden;
    overflow-y: auto;
    padding-bottom: constant(safe-area-inset-bottom);
    padding-bottom: env(safe-area-inset-bottom);
}

.sectionTitleContainer {
    height: fit-content;
    margin: 0;
}

.upcomingAppListContainer {
    margin: 0;
    max-height: 95%;
    overflow-x: scroll;
    border-radius: 1rem;
    width: 100%;
}

.upcomingAppBlock {
    display: grid;
    grid-template-areas:
        "name date"
        "postCode work"
    ;
    background-color: var(--lightGreen);
    border-radius: 2rem;
    padding: 0.5rem 1rem;
    margin-bottom: 0.25rem;
    width: 100%;
    color: white;
}

.uAppTitle {
    grid-area: name;
    margin-left: 0;
}

.uAppDate {
    grid-area: date;
    margin-right: 0;
}

.uAppPCode {
    grid-area: postCode;
    margin-left: 0;
}

.uAppWork {
    grid-area: work;
    margin-right: 0;
}

/********** CREATE WORK FORM PAGE **********/

form {
    margin: 0;
}

.formContainer {
    max-width: 100vw;
    width: 100%;
    display: flex;
    flex-direction: column;
}

form input[type="text"],
form input[type="email"],
form input[type="tel"],
form input[type="password"],
select {
    width: 100%;
    margin-bottom: 0.75rem;
    padding: 0.5rem 1rem;
    border: 2px solid var(--lightGreen);
    border-radius: 2rem;
    background: var(--container);
    color: var(--darkGrey);
    font-size: 1.5rem;
    font-weight: 500;
    text-align: left;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
select:focus {
    box-shadow: 0 0 10px rgba(26, 188, 56, 0.5);
    outline: none;
}

label {
    position: relative;
    top: 10px;
    margin-top: -12px;
    margin-left: 1.5rem;
    font-size: 0.75rem;
    padding: 5px;
    font-weight: 500;
    color: #00000000;
}

/* When the input or textarea is focused, change the label color to darkGrey */
.formContainer input:focus+label,
.formContainer textarea:focus+label,
.formContainer input:not(:placeholder-shown)+label,
.formContainer textarea:not(:placeholder-shown)+label {
    background-color: var(--container);
    color: var(--darkGrey);
}

/* Class to explicitly show the label for inputs with content */
.inputHasContent+label {
    background-color: var(--container);
    color: var(--darkGrey);
}

.installDateBox {
    display: flex;
    flex-direction: row;
    gap: 1rem;
}

.fakeLabel {
    color: var(--darkGrey);
    font-size: 1.5rem;
    font-weight: 500;
    text-align: left;
    margin: 0.5rem 0;
}

/********** ASSIGN WORK **********/

.appBlock {
    background: var(--lightGreen);
    border-radius: 2rem;
    padding: 0.5rem 1rem;
    margin-bottom: 0.25rem;
    width: 100%;
    color: white;
    cursor: pointer;
}

.shown {
    display: grid;
    grid-template-areas:
        "name date"
        "postCode work"
    ;
}

.hiddenButtons {
    padding: 0.25rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
}

.internalButton {
    color: white;
    background: var(--darkGreen);
}

.assign {
    border-radius: 1rem 1rem 0 0;
    height: 100%;
    position: relative;
    bottom: -1px;
}

.edit {
    max-width: 90%;
    margin: 0 0 5px 5px;
}

.assignDD {
    background: var(--container);
    border: 0.5rem solid var(--darkGreen);
    border-radius: 0 2rem 2rem 2rem;
    display: flex;
    flex-direction: column;
    grid-column-end: span 2;
    width: 100%;
}

.DDoption {
    display: flex;
    flex-direction: row;
    width: 90%;
    justify-content: space-between;
    padding: 5px;
    border-bottom: 2px solid var(--darkGrey);
    color: #282828;
}

/********** CHECK PAGE **********/

.sectionButton {
    text-align: center;
    color: white;
    width: 100%;
    border-radius: 2rem;
    display: grid;
    grid-template-columns: 1fr 15%;
    margin: 0 auto 0.75rem;
    padding: 0.25rem;
}

/********** INSTALLER LANDING **********/

#installerLanding {
    display: grid;
    grid-template-areas:
        "maps info"
        "call info"
        "plans complete"
    ;
    grid-template-columns: 40% 60%;
    grid-template-rows: 1fr 1fr 1fr;
    gap: 5px;
}

.maps {
    grid-area: maps;
}

.customerInfoBlock {
    grid-area: info;
    display: flex;
    flex-direction: column;
}

.call {
    grid-area: call;
}

.plans {
    grid-area: plans;
}

.complete {
    grid-area: complete;
}

.rightColumn {
    margin-left: 0;
}

.leftColumn {
    margin-right: 0;
}

.smallHeroButton {
    border: 2px solid #ffffff50;
    background-color: var(--darkGreen);
    color: white;
    font-size: 1.15rem;
    line-height: 1rem;
    font-weight: 500;
    padding: 0.6rem 0;
    height: 100%;
    width: 95%;
    box-shadow: 2px 2px 4px 0px rgba(0, 0, 0, 0.25);
}

.smallHeroButtonIcon {
    width: 30px;
    height: 30px;
    margin-right: 0;
}

.customerInfoBlock {
    border: 2px solid #ffffff50;
    background-color: var(--darkGreen);
    color: white;
    font-weight: 400;
    width: 95%;
    padding: 2px 15px 5px;
    box-shadow: 2px 2px 4px 0px rgba(0, 0, 0, 0.25);
}

.smallTitle {
    width: 90%;
    padding: 2px;
    margin-bottom: 2px;
    border-bottom: 1px solid white;
    font-size: 0.8rem;
    color: white;
}

.title {
    margin-bottom: 2px;
}

.infoBlockText {
    margin-left: 0px;
    font-size: 20px;
}

/********** INSTALLER DOCUMENTATION **********/
.docBlock {
    display: flex;
    background: var(--lightGrey);
    border-radius: 2rem;
    padding: 0.75rem 1.25rem;
    margin-bottom: 0.5rem;
    width: 100%;
    cursor: pointer;
}

.filled {
    background: var(--darkGreen);
}

.docTitle {
    font-size: 1.25rem;
    font-weight: 600;
    color: white;
    margin-left: 0;
    width: 100%;
    text-align: left;
}

.checkBoxRow {
    display: flex;
    margin: 0.25rem 0;
}

.checkBoxTitle {
    margin: 0;
    font-size: 1rem;
    top: 0;
    text-align: left;
}

.checkBoxBox {
    min-height: 30px;
    min-width: 30px;
    margin-right: 0;
}

/********** SIGNATURE PAGES **********/
.termsAgreementContainer {
    margin: 1rem;
}

.termsAgreementTickBox {
    display: flex;
    gap: 1rem;
    width: max-content;
}

.termsAgreement {
    text-align: left;
}

#termsLabel {
    background-color: transparent !important;
    font-size: 1rem;
    color: #000000;
}

canvas {
    width: 90%;
    border-radius: 2rem;
    border: solid white 4px;
    box-shadow: 4px 4px 4px 0px rgba(0, 0, 0, 0.35);
}

/********** PV ARRAY LAYOUT **********/
#pvLayoutContainer {
    width: 100%;
    height: 300px;
    /* Adjust height as needed */
    display: flex;
    overflow-x: scroll;
    background-color: #f0f0f0;
}

.portrait {
    width: 100px;
    height: 200px;
    background-color: lightblue;
    margin-right: 10px;
}

.landscape {
    width: 200px;
    height: 100px;
    background-color: lightgreen;
    margin-right: 10px;
}

.emptySpace {
    width: 200px;
    height: 200px;
    background-color: rebeccapurple;
    margin-right: 10px;
}

.buttonRow {
    display: flex;
    flex-direction: row;
}

/********** HIDDEN **********/

.hidden {
    display: none;
}

.pageContainer {
    display: flex;
    flex-direction: column;
    height: 100%;
}