﻿/* Consolidated styles */
* {
    box-sizing: border-box;
}

nav {
    position: relative;
    top: 0;
    left: 0;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    font-size: 0.7em; /* Already relative, keep */
    align-items: center;
    justify-content: space-evenly; /* Changed to space-evenly for equal spacing */
    padding: 1rem 1.5rem;
    box-shadow: 3px 3px 8px rgba(120, 105, 105, 0.427);
}

h1 {
    font-size: clamp(2.2rem, 6vw, 5rem); /* Changed from 500% */
    color: #00000096;
    font-weight: lighter;
    font-family: "Lucida Console", "Courier New", monospace;
    text-align: center;
    /* just small styles to make it look nice */
}

h2 {
    font-size: clamp(1.6rem, 4vw, 3rem); /* Changed from 300% */
    color: #00000096;
    font-weight: lighter;
    font-family: "Lucida Console", "Courier New", monospace;
    text-align: center;
}

h3 {
    font-size: clamp(1.2rem, 3vw, 2rem); /* Changed from 200% */
    font-weight: lighter;
    font-family: "Lucida Console", "Courier New", monospace;
    text-align: center;
}

img {
    width: min(100%, 600px);
    height: auto; /* Maintain aspect ratio */
    float: right; /* Position the image to the right of the text */
    margin: 2rem auto 2rem 10px; /* Combine spacing into a single margin property */
    padding: 1rem;
    max-width: 600px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(167, 137, 98, 0.836);
    font-family: "Lucida Console", "Courier New", monospace;
}

p {
    font-size: clamp(1rem, 2.2vw, 1.35rem); /* Changed from 160% */
    font-weight: lighter;
    font-family: "Lucida Console", "Courier New", monospace;
    text-align: center;
}

body {
    background-color: #fff7de;
    /* Existing body styles will be overridden by dynamic script, but good practice to have defaults */
    font-family: sans-serif;
    margin: 0;
    padding: 0 1rem;
    margin-bottom: 300px; /* Make sure there's space for the player at the bottom */
    overflow-x: hidden;
}

.page-shell {
    max-width: 1320px;
    margin: 0 auto;
}

.site-license-footer {
    margin: 2rem 0 1rem;
    text-align: center;
    font-size: 0.9rem;
    color: #6a5a3c;
    font-family: "Lucida Console", "Courier New", monospace;
}


.intro, .intropt2 {
    font-size: 0.8em; /* Changed from 80% */
    font-weight: lighter;
    color: #00000096;
    font-family: "Lucida Console", "Courier New", monospace;
    text-align: center;
}

.aboutMe {
    color: #525252;
    font-family: "Lucida Console", "Courier New", monospace;
    font-weight: lighter;
    font-size: clamp(1.4rem, 3.6vw, 2.5rem); /* Changed from 250% */
    flex: 1;
    text-align: center;
}

.things, .projects, .contact, .guest, .demo {
    font-family: "Lucida Console", "Courier New", monospace;
    font-weight: lighter;
    font-size: clamp(1rem, 2.6vw, 2.1rem); /* Changed from 240% */
    flex: 1;
    text-align: center;
}

.things {
    color: #d09b9b;
}

.projects {
    color: #f2a7a7;
}

.contact {
    color: #ffd56d;
}

.guest {
    color: #9fadff;
}

.demo {
    color: #7ea1ff;
}

a {
    color: inherit;
    text-decoration: none;
}

a:visited {
    color: inherit;
}

a:hover {
    color: inherit;
    text-decoration: underline;
}

a:active {
    color: inherit;
}

@media (max-width: 1024px) {
    body {
        padding: 0 0.75rem;
    }

    nav {
        justify-content: center;
    }
}

@media (max-width: 768px) {
    nav {
        padding: 0.8rem;
        gap: 0.5rem 0.75rem;
    }

    .things, .projects, .contact, .guest, .demo {
        flex: 1 1 calc(50% - 0.75rem);
    }

    img {
        float: none;
        display: block;
        margin: 1rem auto;
        padding: 0.5rem;
    }

    body {
        margin-bottom: 220px;
    }
}

@media (max-width: 480px) {
    .things, .projects, .contact, .guest, .demo {
        flex: 1 1 100%;
    }

    h1 {
        margin-top: 0.75rem;
        margin-bottom: 0.5rem;
    }

    .intro,
    .intropt2,
    .aboutMe {
        padding: 0 0.25rem;
    }
}

/* Color Settings Form */
#customization-form {
    margin: 2rem auto;
    padding: 1rem;
    width: min(92vw, 600px);
    max-width: 600px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(167, 137, 98, 0.836);
    font-family: "Lucida Console", "Courier New", monospace;
}

#customization-form label {
    font-weight: lighter;
    display: block;
    margin-bottom: 5px;
    font-size: 1.6em;
    font-family: "Lucida Console", "Courier New", monospace;
}

#customization-form input[type="color"],
#customization-form input[type="number"] {
    width: 100%;
    padding: 5px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-family: "Lucida Console", "Courier New", monospace;
}

#customization-form button {
    display: block;
    width: 100%;
    padding: 10px;
    background-color: #777777;
    color: #525252;
    border: none;
    border-radius: 5px;
    font-size: 1em;
    cursor: pointer;
    transition: none;
    font-family: "Lucida Console", "Courier New", monospace;
}

#customization-form button:hover {
    background-color: #777777;
}

/* GuestBook Form */
.guestbookCONT {
    margin: 2rem auto;
    padding: 1rem;
    width: min(92vw, 600px);
    max-width: 600px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(167, 137, 98, 0.836);
    font-family: "Lucida Console", "Courier New", monospace;
}

#guestForm {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

#guestForm input,
#guestForm button {
    font-family: "Lucida Console", "Courier New", monospace;
    font-size: 1em;
    padding: 0.5rem;
    color: #525252;
    border: 1px solid #ccc;
    border-radius: 4px;
    transition: none;
}

#contactForm button {
    color: #525252;
}

#guestForm button:hover {
    background-color: inherit;
}

/* Contact Form */
#contactForm {
    margin: 2rem auto;
    padding: 1.5rem;
    width: min(94vw, 760px);
    max-width: 760px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(167, 137, 98, 0.836);
    font-family: "Lucida Console", "Courier New", monospace;
}

#contactForm input,
#contactForm textarea,
#contactForm button {
    font-size: 1.05rem;
}

#contactForm .contact-group {
    margin-bottom: 1rem;
}

#contactForm .reason-group {
    margin-bottom: 1.5rem;
}

#contactForm > .contact-group > label {
    display: block;
    margin-bottom: 0.4rem;
}

#contactForm .reason-options {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem;
}

#contactForm .reason-options label {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
}

#contactForm input[type="email"],
#contactForm textarea {
    display: block;
    width: 100%;
    padding: 0.4rem 0.55rem;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-family: "Lucida Console", "Courier New", monospace;
    color: #525252;
}

#contactForm textarea {
    min-height: 70px;
    resize: vertical;
}

#contactForm .contact-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
    margin-top: 1rem;
}

#contactForm button {
    width: 100%;
    min-height: 44px;
    padding: 0.65rem 0.9rem;
    border-radius: 6px;
    border: 1px solid #c9b99a;
    font-family: "Lucida Console", "Courier New", monospace;
    font-weight: 600;
    cursor: pointer;
    transition: none;
}

#submitBtn {
    background-color: #ffe3a8;
    color: #4c3c20;
}

#clearBtn {
    background-color: #fff;
    color: #6a5a3c;
}

#submitBtn:hover {
    background-color: #ffe3a8;
}

#clearBtn:hover {
    background-color: #fff;
}

#submitBtn:disabled {
    background-color: #e7dec9;
    color: #8a7f67;
    cursor: not-allowed;
}

/* Weather Widgets */
#time {
    margin: 2rem auto;
    padding: 0.75rem;
    width: min(92vw, 420px);
    max-width: 420px;
    min-height: 56px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(167, 137, 98, 0.836);
    font-family: "Lucida Console", "Courier New", monospace;
    font-size: 0.95rem;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

#weather {
    margin: 2rem auto;
    padding: 1rem;
    width: min(92vw, 600px);
    max-width: 600px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(167, 137, 98, 0.836);
    font-family: "Lucida Console", "Courier New", monospace;
}

/* YouTube Player */
#floating-player {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 320px;
    height: 240px;
    background-color: #000;
    border: 1px solid #ccc;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    cursor: grab;
    display: none;
    overflow: hidden;
    border-radius: 8px;
    resize: both;
    min-width: 200px;
    min-height: 150px;
}

#floating-player.is-dragging {
    cursor: grabbing;
}

#floating-player iframe {
    width: 100%;
    height: calc(100% - 20px);
    display: block;
}

#close-player {
    position: absolute;
    top: 5px;
    right: 5px;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1em;
    line-height: 1;
    text-align: center;
    cursor: pointer;
    z-index: 1001;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: none;
}

#close-player:hover {
    background-color: rgba(0, 0, 0, 0.5);
}

/* Skills Section Styles */
#skills {
    font-family: "Lucida Console", "Courier New", monospace;
}

#skills h2 {
    font-size: 2em;
    font-weight: bold;
    margin-bottom: 1rem;
}

/* Card Styles */
.card {
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(167, 137, 98, 0.2);
}

.demo-bubble {
    background-color: #fff;
    margin-bottom: 1.75rem;
}

.card-header {
    background-color: #f8f9fa;
    font-weight: bold;
    font-size: 1.2em;
    text-align: center;
    padding: 1rem;
}

.card-body {
    padding: 1rem;
}

.list-group-item {
    font-size: 1em;
    font-family: "Lucida Console", "Courier New", monospace;
    padding: 0.75rem 1rem;
    transition: none;
}

.list-group-item:hover {
    background-color: inherit;
}

@media (max-width: 768px) {
    #customization-form label {
        font-size: 1.2rem;
    }

    #floating-player {
        right: 12px;
        bottom: 12px;
        width: min(90vw, 320px);
        height: min(50vw, 220px);
    }

    #skills h2 {
        font-size: 1.6rem;
    }

    .card-header {
        font-size: 1.05rem;
        padding: 0.75rem;
    }

    .list-group-item {
        font-size: 0.95rem;
        padding: 0.65rem 0.8rem;
    }
}

@media (max-width: 480px) {
    #customization-form,
    .guestbookCONT,
    #contactForm,
    #weather,
    #time {
        width: 95vw;
    }

    #floating-player {
        width: 92vw;
        height: 52vw;
        min-width: 180px;
        min-height: 130px;
    }
}
