/* General Styles */
body {
    font-family: 'Comfortaa', cursive;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
}

body.dark-mode {
    background-color: #2d2d2d;
    color: #e0e0e0;
}

h1, h2, h3 {
    font-family: 'Pacifico', cursive;
    color: #ff6f61;
}

a {
    color: #ff6f61;
    text-decoration: none;
}

a:hover {
    color: #ff3b2f;
}

/* Header and Navigation */
header {
    background-color: #ffffff;
    padding: 20px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: background-color 0.3s ease;
}

body.dark-mode header {
    background-color: #3d3d3d;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

nav .logo img {
    height: 50px;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

nav ul li a {
    font-weight: 700;
    font-size: 1.1rem;
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    background: linear-gradient(to bottom, #f5f5f5, #e0e0e0);
    position: relative;
    overflow: hidden;
}

body.dark-mode .hero {
    background: linear-gradient(to bottom, #2d2d2d, #1d1d1d);
}

.hero-content h1 {
    font-size: 4rem;
    margin-bottom: 20px;
    overflow: hidden; /* Untuk typewriter effect */
    white-space: nowrap;
    border-right: 2px solid #ff6f61; /* Kursor typewriter */
    animation: typing 3.5s steps(40, end), blink-caret 0.75s step-end infinite;
}

@keyframes typing {
    from { width: 0; }
    to { width: 100%; }
}

@keyframes blink-caret {
    from, to { border-color: transparent; }
    50% { border-color: #ff6f61; }
}

.hero-content p {
    font-size: 1.5rem;
    margin-bottom: 40px;
}

.btn {
    background-color: #ff6f61;
    color: #ffffff;
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: 700;
    transition: background-color 0.3s ease;
}

.btn:hover {
    background-color: #ff3b2f;
}

/* About Section */
.about {
    padding: 100px 20px;
    text-align: center;
    background-color: #ffffff;
}

body.dark-mode .about {
    background-color: #3d3d3d;
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.profile-img {
    width: 200px;
    border-radius: 50%;
    margin-bottom: 20px;
    border: 4px solid #ff6f61;
}

.social-links {
    margin-top: 20px;
}

.social-links a {
    font-size: 1.5rem;
    margin: 0 10px;
}

/* Skills Section */
.skills {
    padding: 100px 20px;
    background-color: #f5f5f5;
}

body.dark-mode .skills {
    background-color: #2d2d2d;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.skill-card {
    text-align: center;
    padding: 20px;
    background-color: #ffffff;
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

body.dark-mode .skill-card {
    background-color: #3d3d3d;
}

.skill-card:hover {
    transform: translateY(-10px);
}

.skill-card i {
    font-size: 2rem;
    color: #ff6f61;
    margin-bottom: 10px;
}

/* Projects Section */
.projects {
    padding: 100px 20px;
    background-color: #ffffff;
}

body.dark-mode .projects {
    background-color: #3d3d3d;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.project-card {
    background-color: #f5f5f5;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

body.dark-mode .project-card {
    background-color: #2d2d2d;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(255, 111, 97, 0.3);
}

.project-card img {
    width: 100%;
    border-radius: 10px;
}

.project-card h3 {
    margin-top: 15px;
}

.project-link {
    display: inline-block;
    margin-top: 10px;
    color: #ff6f61;
    font-weight: 700;
}

/* Contact Section */
.contact {
    padding: 100px 20px;
    background-color: #f5f5f5;
    text-align: center;
}

body.dark-mode .contact {
    background-color: #2d2d2d;
}

.contact form {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contact input, .contact textarea {
    padding: 10px;
    border-radius: 10px;
    border: 1px solid #ff6f61;
    background-color: #ffffff;
    color: #333;
    transition: border-color 0.3s ease;
}

body.dark-mode .contact input, body.dark-mode .contact textarea {
    background-color: #3d3d3d;
    color: #e0e0e0;
}

.contact input:focus, .contact textarea:focus {
    border-color: #ff3b2f;
    outline: none;
}

.contact button {
    background-color: #ff6f61;
    color: #ffffff;
    padding: 10px 20px;
    border: none;
    border-radius: 25px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.contact button:hover {
    background-color: #ff3b2f;
}

/* Footer */
footer {
    padding: 20px;
    background-color: #ffffff;
    text-align: center;
}

body.dark-mode footer {
    background-color: #3d3d3d;
}

.footer-links {
    margin-top: 10px;
}

.footer-links a {
    margin: 0 10px;
}

/* Animations */
.animate {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Dark Mode Toggle */
.dark-mode-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: #ff6f61;
    color: #ffffff;
    padding: 10px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 1000;
    box-shadow: 0 0 10px rgba(255, 111, 97, 0.5);
    transition: background-color 0.3s ease;
}

.dark-mode-toggle:hover {
    background-color: #ff3b2f;
}

.dark-mode-toggle i {
    font-size: 1.2rem;
}

/* Scroll to Top Button */
.scroll-to-top {
    position: fixed;
    bottom: 70px;
    right: 20px;
    background-color: #ff6f61;
    color: #ffffff;
    padding: 10px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    z-index: 1000;
    box-shadow: 0 0 10px rgba(255, 111, 97, 0.5);
    display: none;
    transition: background-color 0.3s ease;
}

.scroll-to-top:hover {
    background-color: #ff3b2f;
}

.scroll-to-top i {
    font-size: 1.2rem;
}

/* Load More Button */
.load-more {
    margin: 20px auto;
    display: block;
    background-color: #ff6f61;
    color: #ffffff;
    padding: 10px 20px;
    border: none;
    border-radius: 25px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.load-more:hover {
    background-color: #ff3b2f;
}