@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600&display=swap');

*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif, 'Arial';
}

body{
    height: 100%;
}

.logo{
    color: #e67e22;
    font-weight: 600;
    font-size: 25px;
}

.logo span{
    color: black;
}

.navbar-container{
    width: 100%;
    display: inline-flex;
    background-color: white;
    padding: 0 10px;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    padding: 20px 50px;
    position: fixed;
}

.hero{
    text-align: flex-start;
}

.nav-list{
    display: flex;
    list-style: none;
    padding: 0;
}

.nav-list button{
    color: white;
    background-color: red;
    border: none;
    padding: 10px 20px;
    font-size: 18px;
    font-weight: 500;
    text-decoration: none;
    border-radius: 10px;
    margin: 0 10px;
    transition: all 0.3s ease;
}

.nav-list a{
    color: gray;
    border-radius: 10px;
    padding: 10px 20px;
    font-size: 18px;
    font-weight: 500;
    text-decoration: none;
    border: 10px;
    margin: 0 10px;
    transition: all 0.3s ease;
}

.nav-list a:hover{
    color: #e67e22;
}


.nav-list button:hover{
    background-color: #fff;
    color: #000;
    border: 1px solid #000;
    transition: all 0.3s ease;
    cursor: pointer;
}

#roommate-form-section{
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    padding: 20px;
    background-color: rgba(255, 255, 255, 0.8);
}

#roommate-form-section h2{
    top: 0;
    font-size: 24px;
    font-weight: 300;
    margin-bottom: 20px;
    text-align: center;
}

#roommate-form-section form{
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

#roommate-form-section form textarea{
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 18px;
}

#roommate-form-section label{
    font-size: 18px;
    font-weight: 500;
    margin-bottom: 10px;
}

#roommate-form-section button{
    background-color: blue;
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 13px;
    font-weight: 350;
    text-decoration: none;
    border: none;
    margin-top: 10px;
    transition: all 0.3s ease;
}

#roommate-form-section button:hover{
    background-color: #fff;
    color: #000;
    border: 1px solid #000;
    transition: all 0.3s ease;
    cursor: pointer;
}

#roommate-form{
    box-shadow: #ccc 2px 2px 10px;
    border-radius: 10px;
    padding: 20px;
}


#listings-form-section{
    display: flex;
    flex-direction: column;
    padding: 20px;
    justify-content: center;
    align-items: center;
    height: 100%;
    margin-top: 20px;
}

#listings-form-section h2{
    font-size: 30px;
    font-weight: 300;
    margin-bottom: 20px;
    margin-top: 20px;
    text-align: center;
}

#listings-form-section form{
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 500px;
    box-shadow: #ccc 2px 2px 10px;
    border-radius: 10px;
    padding: 20px;
}

#listings-form-section form textarea{
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 18px;
}

#listings-form-section label{
    font-size: 18px;
    font-weight: 500;
    margin-bottom: 10px;
}

#listings-form-section button{
    background-color: #e67e22;
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 13px;
    font-weight: 350;
    text-decoration: none;
    border: none;
    margin-top: 10px;
    transition: all 0.3s ease;
}

#listings-form-section button:hover{
    background-color: #fff;
    color: #000;
    border: 1px solid #000;
    transition: all 0.3s ease;
    cursor: pointer;
}

.close{
    padding-left: 100%;
    top:0;
    transition: background-color 0.3s ease;
}

.close:hover{
    color: red;
    cursor: pointer;
}

#roommate-display{
    display: flex;
    flex-direction: column;
    padding: 20px;
    background-color: #fff;
    box-shadow: #ccc 2px 2px 10px;
    border-radius: 10px;
    width: fit-content;
    margin-left: 5px;
    transition: box-shadow 0.3s ease;
}

#landlord-message{
    margin-left: 40px;
    margin-bottom: 20px;
}

#student-message{
    margin-left: 40px;
}

.listings-display{
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
    padding: 20px;
    margin-bottom: 30px;
    margin-top: 30px;
}
#latest-listings{
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
    padding: 20px;
    min-height: 100vh;
    margin-bottom: 30px;
    margin-top: 30px;
}

.house-card{
    display: flex;
    justify-content: space-between;
    gap: 10px;
    flex-direction: column;
    align-items: flex-start;
    padding: 10px;
    margin: 10px;
    box-shadow: #ccc 2px 2px 10px;
    border-radius: 10px;
    width: 30%;
    height: auto;
    margin-bottom: 10px;
    transition: box shadow 0.3 ease;
}

.house-card img{
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 5px;
} */

.house-card:hover{
    box-shadow: #000 2px 2px 10px;
}

.house-container{
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.house-container .p-4{
    margin-bottom: 4px;
}

.roommate-display{
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.roommate-card{
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 10px;
    align-items: flex-start;
    padding: 10px 10px;
    margin-left: 10px;
    box-shadow: #ccc 2px 2px 10px;
    border-radius: 10px;
    width: 600px;
    height: 300px;
    overflow: scroll;
    margin-left: 5px;
    margin-bottom: 10px;
    transition: box-shadow 0.3s ease;
}

.roommate-card .p-4 p {
    margin-bottom: 4px;
}


.roommate-card img{
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 50%;
}

.roommate-card:hover{
    box-shadow: #000 2px 2px 10px;
}

.roommate-card .p-4{
    font-size: medium;
    font-weight: 300;
}

.p-4 button{
    background-color: #e67e22;
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 13px;
    font-weight: 350;
    text-decoration: none;
    border: none;
    margin-top: 10px;
    transition: all 0.3s ease;
}

.p-4 button:hover{
    background-color: #fff;
    color: #000;
    border: 1px solid #000;
    transition: all 0.3s ease;
    cursor: pointer;
}

.Roommate-redirect{
    z-index: -1000;
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.Roommate-redirect a{
    padding: 5px 10px;
    font-size: 1rem;
}

.Roommate-redirect a:hover{
    background-color: #fff;
    color: #000;
    border: 1px solid #000;
    transition: all 0.3s ease;
    cursor: pointer;
}

#house-search,
#seach-box{
    width: 100%;
    max-width: 800px;
    align-items: center;
    text-align: center;
    margin-left: 25px; 
    margin-right: 25px; 
    margin-top: 5px;
    border-radius: 10px;
}

.roommate-search{
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    padding: 20px;
    margin-top: 20px;
}

.roommate-search input{
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1rem;
    width: 300px;
}

#details{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.back-btn{
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.back-btn a{
    background-color: #e67e22;
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 13px;
    font-weight: 350;
    text-decoration: none;
    border: none;
    margin-top: 10px;
    text-align: center;
    transition: all 0.3s ease;
}

.back-btn a:hover{
    background-color: #fff;
    color: #000;
    border: 1px solid #000;
    transition: all 0.3s ease;
    cursor: pointer;
}

#my-contact p{
    color: white;
    background-color: red;
    padding: 5px 10px;
    border-radius: 5px;
}

#house-details{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-shadow: #ccc 2px 2px 10px;
    border-radius: 10px;
    margin: 15px;
    padding: 20px;
}

#contact{
    color: white;
    background-color: green;
    padding: 5px;
    margin: 5px;
    border-radius: 4px;
}

.close-btn{
    position: absolute;
    top: 0px;
    right: 10px;
    font-size: 24px;
    color: #000;
    cursor: pointer;
    margin-bottom: 30px;
    padding: 10px;
    border: none;
    background-color: transparent;
    transition: color 0.3s ease;
}

.close-btn:hover{
    color: red;
    transition: color 0.3s ease;
}

.house-profile h2{
    text-align: center;
    padding: 10px;
}

.house-form{
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 2px;
    padding: 20px;
    padding-bottom: 30px;
}

.house-form form{
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    max-width: 500px;
    margin: 0 auto;
    box-shadow: #ccc 2px 2px 10px;
    border-radius: 10px;
    padding: 20px;
}

.house-form select{
    margin-bottom: 15px;
    margin-top: 5px;
}

.house-form textarea{
    border-radius: 4px;
    background-color: white;
    margin-bottom: 15px;
    margin-bottom: 5px;
    font-size: 1rem;
}

.house-form input{
    border-radius: 4px;
    background-color: white;
    margin-bottom: 15px;
    margin-bottom: 5px;
    font-size: 1rem;
}

.house-form button{
  color: white;  
  background-color: blue;
  padding: 5px;
  border-radius: 4px;
  border: none;
  margin-top: 20px;
}

.home-btn{
    display: flex;
    justify-content: center;
    text-decoration: none;
}

.home-btn a{
    text-decoration: none;
    margin-bottom: 30px;
}

.submitted{
    color: #000;
    display: block;
    text-align: center;
    margin-top: 100px;
    font-size: larger;
}

.submitted i{
    color: #e67e22;
    font-size: 4rem;
    margin-bottom: 10px;
}

.action-btn a{
    color: white;
    padding: 10px;
    border: none;
    background-color: #e67e22;
    border-radius: 5px;
    text-decoration: none;
}

.success-contact{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    margin-top: 20px;
}

.spinner {
  border: 3px solid #f3f3f3;
  border-top: 3px solid #3498db;
  border-radius: 50%;
  width: 16px;
  height: 16px;
  animation: spin 0.8s linear infinite;
  margin-left: 8px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.hidden {
  display: none;
}

  #toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
  }

  .toast {
    background-color: #e67e22;
    color: #fff;
    padding: 12px 16px;
    margin-bottom: 10px;
    margin-left: 20px;
    border-radius: 8px;
    font-size: 14px;
    opacity: 0.95;
    display: flex;
    align-items: center;
    gap: 8px;
    animation: fadein 0.3s ease;
  }

  @keyframes fadein {
    from {
      opacity: 0;
      transform: translateY(-10px);
    }
    to {
      opacity: 0.95;
      transform: translateY(0);
    }
  }

  .newsletter {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    margin-top: 20px;
  }

    .newsletter h4 {
        font-size: 20px;
        margin-bottom: 10px;
    }

    .newsletter input[type="email"] {
        padding: 10px;
        width: 300px;
        border: 1px solid #ccc;
        border-radius: 5px;
        font-size: 16px;
        margin-bottom: 10px;
    }

    .newsletter button[type="submit"] {
        padding: 10px 20px;
        border: none;
        border-radius: 5px;
        background-color: #e67e22;
        color: white;
        font-size: 16px;
        cursor: pointer;
        transition: background-color 0.3s ease;
    }

    .newsletter button[type="submit"]:hover {
        background-color: #d35400;
    }

    .footer-2{
        background-color: #f8f8f8;
        padding: 20px;
        text-align: center;
        font-size: 14px;
        color: #555;
    }

    .more-listings {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    padding: 20px;
    margin-top: 30px;
    margin-bottom: 30px;
  }

  .more-listings a {
    text-decoration: none;
    color: #fff;
    background-color: #e67e22;
    padding: 10px 20px;
    border-radius: 5px;
    font-size: 18px;
    font-weight: 500;
    margin: 10px;
  }

  .category-bar {
      display: flex;
      overflow-x: auto;
      gap: 0.5rem;
      padding: 0.5rem;
      background: #f4f4f4;
      white-space: nowrap;
      margin: 2rem 0;
    }

    .category-btn{
      padding: 0.5rem 1rem;
      background: #ddd;
      border: none;
      border-radius: 20px;
      font-size: 14px;
      flex: 0 0 auto;
      cursor: pointer;
      transition: all 0.3s ease-in-out;
    }

    .category-btn:hover,
    .category-btn.active {
      background-color: #8B4513;
      color: #fff;
    }

    #pagination {
      display: flex;
      justify-content: center;
      align-items: center;
      margin-top: 20px;
    }

    .pagination {
      background-color: #e67e22;
      color: white;
      padding: 10px 20px;
      border: none;
      border-radius: 5px;
      font-size: 16px;
      cursor: pointer;
      margin: 0 5px;
      transition: background-color 0.3s ease;
    }

    .pagination:hover {
      background-color: #d35400;
    }

    .request-btn {
      background-color: #e67e22;
      color: white;
      padding: 10px 20px;
      border: none;
      border-radius: 5px;
      font-size: 16px;
      cursor: pointer;
      transition: background-color 0.3s ease;
    }

    .request-btn:hover {
      background-color: #d35400;
    }

    .distance-text{
        font-size: medium;
        color: blue;
    }

    .action-btn {
        padding: 5px 10px;
        border: none;
        color: white;
        border-radius: 3px;
        margin-bottom: 4px;
        cursor: pointer;
    }









/* Hamburger menu - sidebar */

@media (max-width:768px){
    *{
        margin: 0;
        padding: 0;
        box-sizing: border-box;
    }

    .navbar-container{
        margin-bottom: 20px;
    }

    body{
        min-height: 100vh;
    }

    .nav-list button{
        display: none;
    }

    .nav-list a{
        display: none;
        border-bottom: #000 1px solid;
        border-radius: none;
    }

    .bars{
        display: block;
    }

    .sidebar-nav span{
    position: absolute;
    top: 2px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    color: #000;
  }

  .hamburger-menu{
    display: block;
    position: absolute;
    top: 20px;
    right: 20px;
    cursor: pointer;
  }

    .sidebar-nav{
    position: fixed;
    top: 0;
    left: 0;
    width: 250px;
    height: 100%;
    background-color: #fff;
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
    z-index: 1000;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
  }

  .sidebar-nav button{
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 10px;
    margin: 10px;
    border: none;
    border-bottom: #000 1px solid;
    color: #000;
    background-color: white;
    font-size: 1.2rem;
  }

  .sidebar-nav button:first{
    margin-top: 50px;
  }

  .sidebar-nav button:hover{
    background-color: transparent;
  }


  .sidebar-nav a{
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 10px;
    margin: 10px;
    border-bottom: #000 1px solid;
    color: #000;
    background-color: white;
    font-size: 1.2rem;
    text-decoration: none;
  }

  .sidebar-nav.active{
    transform: translateX(0);
  }

  .roommate-card{
    margin: 0;
    width: 98vw;
    height: 100%;
    margin-bottom: 10px;
  }

  .house-card{
    margin-left: 0;
    margin-right: 0;
    width: 90vw;
  }

  .listings-display{
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    min-height: 100vh;
    margin-top: 3px;
  }

  .hide-on-mobile{
    display: none;
}

.house-form form{
    width: 100%;
    max-width: 98vw;
    padding: 20px;
    box-shadow: #ccc 2px 2px 10px;
    border-radius: 10px;
    margin: 0 auto;
}
} 

@media (min-width:768px){
    .bars{
        display: none;
    }
}