/* -----------------------
   Global reset & layout
------------------------ */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    height: 100%;
    margin: 0;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Flex wrapper to push footer to bottom */
.page_wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Main content area between header and footer */
.page_content {
    flex: 1 0 1;
    margin-left:auto;
    margin-right:auto;
    margin-top: 80px;
    margin-bottom:5px;
    padding: 3rem;
    width: 90%;
    height:fit-content;
    background: #f8fffa;
    border-radius: 35px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(7.1px);
    -webkit-backdrop-filter: blur(7.1px);
    border: 1px solid rgba(150, 200, 170, 0.15);
    text-align:center;
    max-width:1200px;
}
/* Title on each page */
.title  {
    text-align:center;
    font-size:40px;
    margin:39px;
}
/* Body text (like on the main page) (paragraph elements) */
.body_text  {
    text-align:center;
    max-width:600px;
    margin-left:auto;
    margin-right:auto;
    letter-spacing:0.2px;
    line-height: 1.45;
}
.bodylink   {
    /* margin-left:-20px;
    margin-right:40px; */
    margin:0 12px;
    color: black;
    text-decoration: none;
    border-bottom: 3px solid transparent;
    border-radius: 3px;
    transition:
        color 0.2s ease,
        border-bottom-color 0.2s ease;
}
.bodylink:hover {
    border-bottom-color: rgb(156, 197, 161);
    color: rgb(46, 46, 46);
}

/* Columns for the skills page */
#skillsbody {
    display:flex;
    text-align:left;
    gap: 20px;
    justify-content:center;
    flex-wrap:wrap;
}
.skillscol  {
    margin-bottom:35px;
    flex: 0 0 calc(25%-60px);
    min-width: 250px;
    box-sizing: border-box;
    border: 1px solid rgba(150, 200, 170, 0.15);
    border-radius:30px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    padding:20px;
}
#skillsbody h2  {
    margin-bottom:12px;
    font-weight:600;
    justify-self:center;
    text-align:center;
}
#skillsbody ul  {
    margin:0;
    line-height:1.6;
}
ul li {
  margin-left: 1.2rem;
}

ul li ul li {
  margin-left: 1.4rem;
}

/* Header + footer should not shrink */
.hero-header,
.site_footer {
    flex-shrink: 0;
}

/* Wave + Header */

/* Wrapper for wave + header */
.hero-header {
    position: relative;
    width: 100%;
    padding-top: 20px;
}

/* Wave background */
.hero-wave {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 320px;    /* adjust to taste for how far it dips */
    display: block;
    z-index: 0;
    pointer-events: none;
}

/* Top menu bar */
.site_header {
    position: relative;
    z-index: 1;
    height: 100px;
    width: 100%;
    background: rgba(255, 255, 255, 0.23);
    border-radius: 16px;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(7.1px);
    -webkit-backdrop-filter: blur(7.1px);
    border: 1px solid rgba(255, 255, 255, 0.4);
}

/* Nav layout */
.nav {
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 2rem;
    padding: 0 15px;
}

/* Logo in nav */
.nav_logo {
    display: block;
    background-image: url('/assets/img/favicon.png');
    background-size: cover;
    background-position: center;
    height: 60px;
    width: 60px;
    text-indent: -9999px;
    overflow: hidden;
    transition:
        height 0.2s ease,
        width 0.2s ease;
}

.nav_logo:hover {
    height: 70px;
    width: 70px;
}

/* Nav links */
.nav_link {
    color: black;
    text-decoration: none;
    border-bottom: 3px solid transparent;
    border-radius: 3px;
    transition:
        color 0.2s ease,
        border-bottom-color 0.2s ease;
}

.nav_link:hover {
    border-bottom-color: rgb(156, 197, 161);
    color: rgb(46, 46, 46);
}

/* Footer */
.site_footer {
    width: 100%;
    background: rgba(255, 255, 255, 0.23);
    border-radius: 16px;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(7.1px);
    -webkit-backdrop-filter: blur(7.1px);
    border: 1px solid rgba(255, 255, 255, 0.4);

    padding: 8px 16px;      /* compact height */
    font-size: 0.9rem;
    position: relative;
    z-index: 1;
    overflow: hidden;

    /* in case it's inside .page_wrapper flex column */
    margin-top: auto;
}

/* Inner layout of footer */
.footer_content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
}

/* Footer links */
.footer_links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.footer_link {
    text-decoration: none;
    color: black;
    border-bottom: 3px solid transparent;
    border-radius: 3px;
    transition:
        border-bottom-color 0.2s ease,
        color 0.2s ease;
    white-space: nowrap;   /* keeps each link on one line */
}

.footer_link:hover {
    border-bottom-color: rgb(156, 197, 161);
    color: rgb(46, 46, 46);
}

/* Projects page JavaScript-generated styling */
.projectbody {
    width:100%;
    height:100%;
    display:flex;
    flex-wrap:wrap;
    gap:20px;
}
.projectbox {
    flex: 1 1 calc(50% - 20px);  /* two columns, minus the gap */
    min-width: 250px;
    box-sizing: border-box;
    border: 1px solid rgba(150, 200, 170, 0.15);
    border-radius:30px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    display:flex;
    flex-direction:column;
    align-items:center;
}
.projectbox img {
    height: auto;
    width:80%;
    display:block;
}
.projectbox a   {
    color: black;
    text-decoration: none;
    border-bottom: 3px solid transparent;
    border-radius: 3px;
    transition:
        color 0.2s ease,
        border-bottom-color 0.2s ease;
}
.projectbox a:hover {
    border-bottom-color: rgb(156, 197, 161);
    color: rgb(46, 46, 46);
}

/* Mobile adjustments */
@media (max-width: 600px) {

    /* Make nav items wrap or go to the next line */
    .nav {
        flex-wrap: wrap;         /* allows items to break to the next line */
        gap: 1rem;               /* less spacing on small screens */
        padding: 0 10px;         /* tighten padding */
        height: auto;            /* let nav grow vertically */
    }

    .nav_logo {
        height: 50px;            /* slightly smaller logo */
        width: 50px;
    }

    /* Make links smaller & prevent crowding */
    .nav_link {
        font-size: 0.9rem;
        padding-bottom: 2px;
    }

    /* Allow links to wrap neatly under or beside the logo */
    .nav_link {
        white-space: nowrap;
    }
}