@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,400;0,500;0,700;1,400&display=swap&family=Sansita+Swashed&display=swap');

* {
    --primary: #62D8C2;
    --second: #62D8A7;
    --danger: #d34141;
    --dark: #37504B;
    --erased: #37504b73;
    --white: #FEFEFE;
    --dark-white: #FDFDFD;

    --weak-primary: #62D8C266;
    --weak-second: #62D8A766;
}

body {
    background-color: var(--dark-white);
}

.dark{
    background-color: black !important;
    color: white !important;
}

nav#navbar {
    position: fixed;
    
    top: 0;
    left: 0;
    
    background: linear-gradient(45deg, var(--primary), var(--second));
    background-color: var(--primary);
    color: var(--white);
    
    font-weight: bold;
    font-family: 'Roboto', monospace, Verdana, Tahoma, sans-serif;
    
    padding: 12px 20px;
    
    display: flex;
    justify-content: space-between;
    align-items: center;
    
    width: 100%;
    
    z-index: 1
}

#navbar-brand h1 {
    padding: 0;
    margin: 0;
    font-family: 'Sansita Swashed', cursive;
    
}

.theme-toggle-button{
    cursor: pointer;
    border: none;
    outline: none;
    background-color: #62D8C2 ;
    padding: 0;
    margin: 0;
}
.theme-toggle-button:focus{
    outline: none;
    border: none;
}

#navbar-links {
    display: flex;
    align-items: center;

    margin: 0;

    list-style-type: none;
}

#navbar-links li {
    margin-left: 16px;
}

#poems {
    margin: 5px;
    margin-top: 72px;
    padding: 10px;
    border: var(--primary) 2px solid;
    border-radius: 5px;
    background-color: var(--dark-white);
    z-index: -1
}

.edit-btn {
    cursor: pointer;
    font-size: 14px;
    text-align: center;
    color: var(--second);
}

@media only screen and (min-width: 700px) {
    #poems {
        margin: auto;
        margin-top: 72px;
        border: none;
        background: none;
    }
    .poem {
        background: var(--white);
        box-shadow: 3px 3px 4px #62D8A766;
    }
}

.poem {
    margin: 3em auto;
    padding: 5px;
    border: var(--primary) solid 1px;
    border-radius: 5px;
    flex-wrap: wrap;
    word-wrap: normal;
    width: 100%;
    background-color: var(--white);
}
.poem .body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 2em auto;
    font-size: 2em;
}
.poem .body .title {
    color: var(--dark);
    text-align: center;
    font-weight: 600;
    width: 100%;
    font-size: 1em;
    margin-bottom: 1em;
}
.poem .body .text {
    width: 100%;
    text-align: center;
    overflow: auto;
    resize: none;
    border: none;
    color: var(--dark);
    margin-top: 5px;
    background-color: #00000000;
}

@media screen and (max-width:700px) {
    .poem .body {
        font-size: 1.6em;
    }
    #poems {
        border: none;
    }
}

.poem .info {
    width: 100%;
    color: var(--erased);
    border-bottom: var(--second) solid 1px;
    padding: 5px;
    margin-bottom: 15px;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
}
.poem .info .author {
    grid-column: 1/2;
    text-align: center;
}
.poem .info .lastupdate {
    grid-column: 2/3;
    text-align: center;
}
.poem .info .edit-btn {
    grid-column: 3/4;
    text-align: center;
}

.red-alert {
    width: 100%;
    background: rgb(255, 143, 143);
    padding: 2px 8px;
    border-radius: 5px;
}

.container {
    color: var(--dark);
}

.input, .textarea {
    width: 100%;
    border-radius: 5px;
    border: 3px solid #00000005;
    border-bottom: 3px solid var(--primary);
    padding: .25em .5em;
    outline: none;
    color: var(--dark);
    font-weight: bold;
    font-size: 1.2em;
    margin-bottom: .5em;
}
.input:focus, .textarea:focus {
    border-bottom: 3px solid var(--dark);
}

textarea {
    max-width: 100%;
}

.label {
    font-size: 1.6em;
    color: var(--dark);
    font-weight: bold;
}

.form {
    width: 95%;
    margin: auto;
}

.no-decoration, .no-decoration:hover {
    text-decoration: none;
}

.primary-btn {
    background: var(--primary);
    background: linear-gradient(90deg, var(--primary), var(--second));
    outline: none;
    transition: none !important;
}
.primary-btn:hover {
    background: var(--dark);
    color: var(--white);
}

.flat-dark-btn {
    outline: none;
    background: none;
    transition: none !important;
    color: var(--dark);
    border: 2px solid var(--dark) !important;
}
.flat-dark-btn:hover {
    background: var(--dark);
    color: var(--white);
}

.flat-white-btn {
    outline: none;
    background: none;
    transition: none !important;
    color: var(--white);
    border: 2px solid var(--white) !important;
}
.flat-white-btn:hover {
    background: var(--white);
    color: var(--dark);
}

.flat-danger-btn {
    background: none;
    outline: none;
    transition: none !important;
    color: var(--danger);
    border: 2px solid var(--danger) !important;
}
.flat-danger-btn:hover {
    background: var(--danger);
    color: var(--white);
}

.box {
    padding: 1em 2em;
    background: var(--white);
    border: 1px solid var(--erased);
}

.text-second {
    color: var(--second);
}
.text-second:hover {
    color: var(--danger);
}

main {
    margin: 8em auto;
}

.trending-label {
    text-align: center;
    width: 100%;
    color: var(--erased);
    margin-top: 1em;
}

.divider {
    width: 60%;
    margin: 1.25em auto;
    height: 5px;
    background-color: var(--erased);
}

/* DARK MODE */
body.darkmode {
    background: #050505;
    color: var(--primary);
}
body.darkmode .label {
    color: var(--primary);
}

.container {
    color: var(--primary);
}

body.darkmode .input, body.darkmode .textarea {
    border: 3px solid #FFFFFF66;
    border-bottom: 3px solid var(--primary);
    background: #060606;
    color: var(--primary);
}
body.darkmode .input:focus, body.darkmode .textarea:focus {
    border-bottom: 3px solid var(--white);
}

body.darkmode .poem {
    border: var(--primary) solid 1px;
    background-color: #090909;
}
body.darkmode .poem .body .title {
    color: var(--second);
}
body.darkmode .poem .body .text {
    color: var(--primary);
}
body.darkmode .poem .info {
    color: var(--weak-second);
}
body.darkmode #poems {
    background: none;
}

body.darkmode .box {
    background: #060606;
    color: var(--primary);
    border: solid 1px var(--second);
}

body.darkmode #like {
    color: var(--white);
}

body.darkmode .trending-label {
    color: var(--white);
}

body.darkmode .divider {
    background-color: var(--white);
}

/* LOADING ANIMATION */
#overlay {
    position: fixed;
    height: 100%;
    width: 100%;
    top: 0;
    left: 0;
    float: left;
    text-align: center;
    padding-top: 25%;
}

.spinner {
    margin: 0 auto;
    height: 64px;
    width: 64px;
    animation: rotate 0.8s infinite linear;
    border: 5px solid var(--primary);
    border-right-color: transparent;
    border-radius: 50%;
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}