/* style.css */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@300;400;500;600;700&display=swap');

body {
    font-family: 'Montserrat', sans-serif;
    margin: 0;
    padding: 0;
    background: url('images/putih.jpeg') no-repeat center center fixed;
    background-size:100%;
    color: #333;
    line-height: 1.6;
}

header {
    background: #fff;
    padding: 1rem 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.theme-toggle {
    background: none;
    border: none;
    color: #555;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-toggle:hover {
    background: rgba(76, 175, 80, 0.1);
    color: #4CAF50;
}

nav .logo {
    font-size: 1.8rem;
    font-weight: bold;
    text-decoration: none;
    color: #4CAF50;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
}

nav .logo img {
    height: 6rem;
    width: auto;
    margin-right: 50px;
}

nav .logo:hover {
    color: #388E3C;
}

nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 0.5rem;
}

nav ul li {
    margin-left: 20px;
}

nav ul li a {
    text-decoration: none;
    color: #555;
    font-weight: 500;
    transition: color 0.3s ease;
    padding: 0.5rem 0;
}

nav ul li a:hover {
    color: #4CAF50;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: #333;
    margin: 3px 0;
    transition: 0.3s;
}

main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.hero {
    text-align: center;
    background: url('images/Nature.jpg') no-repeat center center;
    background-size: cover;
    color: white;
    padding: 4rem 2rem;
    border-radius: 15px;
    margin-bottom: 3rem;
    margin-top: -40px;
    box-shadow: 0 10px 30px rgba(76, 175, 80, 0.3);
}

.hero img {
    width: 100%;
    max-width: 600px;
    height: auto;
    display: block;
    margin: 0 auto 1rem;
}

.hero h1 {
    font-size: 2.7rem;
    margin-bottom: 1rem;
    font-weight: 700;
    text-shadow: 2px 2px 7px rgba(255, 255, 255, 0.7);
    animation: fadeIn 2s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero p {
    font-size: 23px;
    margin: 1rem 0;
    padding-bottom: 60px;
    margin-top: -12px;
}

.homestay {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 4rem;
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.homestay:nth-child(even) {
    flex-direction: row-reverse;
}

.gallery {
    flex: 1;
    min-width: 300px;
    position: relative;
    overflow: hidden;
}

.gallery img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    display: none;
    transition: opacity 0.5s ease;
}

.gallery img.active {
    display: block;
}

/* Desktop grid layout for galleries */
@media (min-width: 769px) {
    .gallery {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        position: relative;
        overflow: visible;
    }

    .gallery img {
        display: block;
        height: auto;
        object-fit: contain;
        /*max-height: 300px;*/
        width: 100%;
    }

    .gallery-nav {
        display: none;
    }
}

/* Gallery Navigation Buttons */
.gallery {
    position: relative;
}

.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 10px;
    cursor: pointer;
    font-size: 18px;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
}

.gallery-nav:hover {
    background: rgba(0, 0, 0, 0.8);
}

.gallery-nav.prev {
    left: 10px;
}

.gallery-nav.next {
    right: 10px;
}

.details {
    flex: 1;
    min-width: 300px;
    padding: 2rem;
}

.details h2 {
    color: #4CAF50;
    margin-bottom: 1rem;
    font-size: 2rem;
}

.details h3 {
    color: #555;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    font-size: 1.3rem;
}

.details ul {
    padding-left: 1.5rem;
}

.details li {
    margin-bottom: 0.5rem;
}

.details p {
    margin-top: 1.5rem;
    font-weight: 500;
}

.location {
    text-align: center;
    margin-bottom: 3rem;
}

.location h2 {
    color: #388E3C;
    margin-bottom: 1rem;
}

.location iframe {
    width: 100%;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

footer {
    background: linear-gradient(135deg, #C8E6C9 0%, #A8DADC 100%);
    color: #333;
    padding: 3rem 2rem 1rem;
    /*position: relative;*/
    overflow: hidden;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #4CAF50, #388E3C, #4CAF50);
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    gap: 2rem;
}

.footer-logo {
    flex: 1;
    text-align: center;
}

.logo-footer {
    width: 120px;
    height: auto;
    transition: transform 0.3s ease;
}

.logo-footer:hover {
    transform: scale(1.05);
}

.footer-info {
    flex: 2;
    text-align: center;
}

.footer-info p {
    margin: 0.5rem 0;
    font-size: 0.9rem;
    opacity: 0.7;
}

.footer-links {
    flex: 2;
    text-align: center;
}

.footer-link {
    color: #4CAF50;
    text-decoration: none;
    margin: 0 1rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: #81C784;
    text-decoration: underline;
}

.footer-social {
    flex: 1;
    text-align: center;
}

.social-link {
    display: inline-block;
    color: #4CAF50;
    font-size: 1.5rem;
    margin: 0 0.5rem;
    transition: all 0.3s ease;
    text-decoration: none;
}

.social-link:hover {
    color: #81C784;
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.footer-bottom p {
    font-size: 0.9rem;
    opacity: 0.8;
    margin: 0;
}

/* Contact Page Styles */
.contact-container {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 4rem;
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

.contact-info, .contact-form {
    flex: 1;
    min-width: 300px;
}

.contact-info h2, .contact-form h2 {
    color: #4CAF50;
    margin-bottom: 1.5rem;
    font-size: 2rem;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: #f9f9f9;
    border-radius: 10px;
    transition: transform 0.3s ease;
}

.contact-item:hover {
    transform: translateY(-5px);
}

.contact-item i {
    font-size: 1.5rem;
    color: #4CAF50;
    margin-right: 1rem;
    margin-top: 0.2rem;
}

.contact-item strong {
    color: #333;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #555;
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus, .form-group textarea:focus {
    outline: none;
    border-color: #4CAF50;
    box-shadow: 0 0 5px rgba(76, 175, 80, 0.3);
}

.btn {
    background: linear-gradient(135deg, #4CAF50 0%, #388E3C 100%);
    color: white;
    border: none;
    padding: 0.75rem 2rem;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(76, 175, 80, 0.4);
}

/* Dark Mode Styles */
body.dark-mode {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    color: #e0e0e0;
}

body.dark-mode header {
    background: #2d2d2d;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

body.dark-mode nav .logo {
    color: #81C784;
}

body.dark-mode nav .logo:hover {
    color: #A5D6A7;
}

body.dark-mode nav ul li a {
    color: #e0e0e0;
}

body.dark-mode nav ul li a:hover {
    color: #81C784;
}

body.dark-mode .theme-toggle {
    color: #e0e0e0;
}

body.dark-mode .theme-toggle:hover {
    background: rgba(129, 199, 132, 0.1);
    color: #81C784;
}

body.dark-mode .homestay {
    background: #2d2d2d;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

body.dark-mode .details h2 {
    color: #81C784;
}

body.dark-mode .details h3 {
    color: #e0e0e0;
}

body.dark-mode .details li {
    color: #e0e0e0;
}

body.dark-mode .details p {
    color: #e0e0e0;
}

body.dark-mode .contact-container {
    background: #2d2d2d;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

body.dark-mode .contact-item {
    background: #3d3d3d;
}

body.dark-mode .contact-item strong {
    color: #e0e0e0;
}

body.dark-mode .form-group label {
    color: #e0e0e0;
}

body.dark-mode .form-group input,
body.dark-mode .form-group textarea {
    background: #3d3d3d;
    border-color: #555;
    color: #e0e0e0;
}

body.dark-mode .form-group input:focus,
body.dark-mode .form-group textarea:focus {
    border-color: #81C784;
    box-shadow: 0 0 5px rgba(129, 199, 132, 0.3);
}

body.dark-mode footer {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    color: #e0e0e0;
}

body.dark-mode .hamburger span {
    background: #e0e0e0;
}

/* Responsive Design */
@media (max-width: 768px) {
    body {
        background-size: cover;
    }

    header {
        padding: 0.5rem 1rem;
    }

    nav .logo {
        font-size: 1.2rem;
    }

    nav .logo img {
        height: 3rem;
        margin-right: 10px;
    }

    nav ul {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: #fff;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
        padding: 1rem 0;
    }

    body.dark-mode nav ul {
        background: #2d2d2d;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
    }

    nav ul.active {
        display: flex;
    }

    nav ul li {
        margin: 0.5rem 0;
        text-align: center;
    }

    .hamburger {
        display: flex;
    }

    .hero img {
        max-width: 400px;
    }

    .hero h1 {
        font-size: 1.5rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .homestay {
        flex-direction: column;
    }

    .details {
        padding: 1rem;
    }

    main {
        padding: 1rem;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
    }

    .footer-links {
        order: 2;
    }

    .footer-social {
        order: 3;
    }

    .footer-info {
        order: 4;
    }

    .footer-link {
        display: block;
        margin: 0.5rem 0;
    }

    .social-link {
        margin: 0 0.25rem;
    }

    .contact-container {
        flex-direction: column;
        padding: 1rem;
    }

    .contact-info h2, .contact-form h2 {
        font-size: 1.5rem;
    }

    .contact-item {
        padding: 0.75rem;
    }
}

@media (max-width: 480px) {
    header {
        padding: 0.25rem 0.5rem;
    }

    nav .logo {
        font-size: 1rem;
    }

    nav .logo img {
        height: 2rem;
        margin-right: 5px;
    }

    .nav-right {
        gap: 0.5rem;
    }

    .theme-toggle {
        width: 30px;
        height: 30px;
        font-size: 1rem;
    }

    .hamburger span {
        width: 20px;
    }

    .hero {
        padding: 2rem 1rem;
    }

    .hero img {
        max-width: 270px;
        margin-top: -20px;
    }

    .hero h1 {
        font-size: 1.1rem;
        text-align: center;
    }

    .hero p {
        font-size: 13px;
        margin-top: -10px;
        margin-bottom: -10px;
    }

    .details h2 {
        font-size: 1.5rem;
    }

    .contact-item i {
        font-size: 1.2rem;
    }
}
