/* -----------------------------------
   General Styles
------------------------------------- */
body {
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f9f9f9;
    color: #333;
    scroll-behavior: smooth;
}

/* -----------------------------------
   Header & Navigation
------------------------------------- */
header {
    position: sticky;
    top: 0;
    z-index: 1000;
}

nav {
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
}

nav ul li a {
    transition: color 0.3s ease, background-color 0.3s ease;
}

nav ul li a:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

nav ul li.active a {
    background-color: rgba(255, 255, 255, 0.3);
    font-weight: 500;
}

/* -----------------------------------
   Hero Section
------------------------------------- */
#hero {
    padding: 5rem 1rem;
    background: linear-gradient(to right, #42a5f5, #64b5f6);
    color: #fff;
    text-align: center;
}

#hero h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

#hero p {
    font-size: 1.5rem;
    margin-bottom: 2rem;
}

#hero .btn-large {
    background-color: #1565c0;
    color: #fff;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

#hero .btn-large:hover {
    background-color: #0d47a1;
}

/* -----------------------------------
   Photos Section
------------------------------------- */
#photos {
    padding: 3rem 0;
    background-color: #f4f4f4;
}

#photos h2 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    color: #42a5f5;
}

.row {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.card {
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    width: 300px;
    height: 300px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background-color: #f0f0f0;
}

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

.card-image {
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.card:hover .card-image img {
    transform: scale(1.05);
}

.card-content {
    padding: 1rem;
    background-color: #fff;
    text-align: center;
}

.card-content p {
    font-size: 1.3rem;
    font-weight: 500;
    color: #333;
}

.glass-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.15);
    padding: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 40px 0 rgba(31, 38, 135, 0.25);
}

/* -----------------------------------
   Skills Section
------------------------------------- */
#skills {
    padding: 4rem 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 2rem;
    color: #42a5f5;
}

.skill-card {
    background-color: #fff;
    border-radius: 12px;
    overflow: hidden;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 2rem;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.skill-card:hover {
    transform: translateY(-12px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.2);
}

.skill-icon {
    padding: 1.5rem;
}

.skill-icon i {
    font-size: 3rem;
}

.skill-content {
    padding: 1rem;
    flex-grow: 1;
}

.skill-content h5 {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #424242;
}

.skill-content p {
    font-size: 0.9rem;
    color: #757575;
    margin: 0;
}

/* Update the Skills section container styling */
#skills .row, #gallery .row {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin: 0;
}

/* Fix column widths for better responsiveness */
#skills .col, #gallery .col {
    flex: 0 0 calc(25% - 20px);
    max-width: calc(25% - 20px);
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding: 0 !important;
    display: flex;
}

/* Fix the height of skill cards */
.skill-card {
    width: 100%;
    height: 100%;
    min-height: 220px; /* Consistent minimum height */
}

/* Gallery card fixes */
#gallery .card {
    width: 100%;
    height: 250px;
    margin: 0;
}

#gallery .card-image {
    height: 100%;
}

/* Better responsive adjustments */
@media only screen and (max-width: 992px) {
    #skills .col, #gallery .col {
        flex: 0 0 calc(50% - 20px);
        max-width: calc(50% - 20px);
    }
}

@media only screen and (max-width: 600px) {
    #skills .col, #gallery .col {
        flex: 0 0 calc(100% - 20px);
        max-width: calc(100% - 20px);
    }
    
    .skill-card {
        min-height: 180px;
    }
    
    #gallery .card {
        height: 220px;
    }
}

/* -----------------------------------
   Quote Section
------------------------------------- */
#quote {
    padding: 3rem 0;
}

.fancy-quote {
    font-style: italic;
    font-size: 1.5rem;
    position: relative;
    padding: 20px 40px;
    margin: 0;
}

.fancy-quote:before,
.fancy-quote:after {
    content: '"';
    font-size: 4rem;
    position: absolute;
    opacity: 0.3;
}

.fancy-quote:before {
    top: -20px;
    left: 0;
}

.fancy-quote:after {
    bottom: -60px;
    right: 0;
}

/* -----------------------------------
   Progress Bar
------------------------------------- */
.progress {
    background-color: #e0e0e0;
    height: 10px;
    border-radius: 5px;
    overflow: hidden;
}

.determinate {
    background-color: #42a5f5;
    height: 100%;
    transition: width 1s ease-in-out;
}

/* -----------------------------------
   Footer
------------------------------------- */
footer {
    padding: 1rem 0;
    text-align: center;
    color: #fff;
    background-color: #333;
}

/* -----------------------------------
   Back-to-Top Button
------------------------------------- */

#back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: none;
    z-index: 999;
    opacity: 0;
    transition: all 0.3s ease;
    width: 45px;
    height: 45px;
    background-color: #1565c0;
    color: white;
    border-radius: 50%;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
}

body.dark-mode #back-to-top {
    background-color: #64b5f6;
    color: #121212;
}

#back-to-top.visible {
    display: block;
    opacity: 1;
}

#back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

/* -----------------------------------
   Responsive Adjustments
------------------------------------- */
@media only screen and (max-width: 992px) {
    .skill-card {
        margin-bottom: 1.5rem;
    }
}

@media only screen and (max-width: 600px) {
    .section-title {
        font-size: 2rem;
    }
    .skill-card {
        margin-bottom: 1rem;
    }
}

/* Tech Stack Section */
.tech-icons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    margin: 40px 0;
}

.tech-icon {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f8f9fa;
    border-radius: 12px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.tech-icon:hover {
    transform: translateY(-10px) scale(1.05);
}

.tech-icon img {
    width: 50px;
    height: 50px;
}

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

body.dark-mode .card, 
body.dark-mode .skill-card,
body.dark-mode .glass-card {
    background-color: #1e1e1e;
    color: #e0e0e0;
}

body.dark-mode .section.white,
body.dark-mode .section.grey.lighten-4 {
    background-color: #121212 !important;
    color: #e0e0e0;
}

body.dark-mode .section-title {
    color: #64b5f6;
}

#dark-mode-toggle {
    margin-right: 15px;
    background-color: transparent;
    box-shadow: none;
}

#dark-mode-toggle i {
    color: #fff;
}

/* Dark mode toggle positioning */
#nav-mobile li:last-child {
    margin-left: 10px;
}