/* --- Personal Portfolio Site 2025 ---
   Theme: Signature Teal & Rose Palette
   Author: Adriana Padilla
   Update: Added refined hover effects and secondary buttons
*/

/* ===============================
   1. VARIABLES + BASE
=============================== */
:root {
    --primary: #4B6CA3;    /* Teal - main highlights */
    --accent: #E94E77;     /* Rich rose - vibrant accent */
    --secondary: #F7C6C7;  /* Soft blush - footer background, subtle accents */
    --text: #2D2D2D;       /* Charcoal - main body text */
    --bg: #F8F9F9;         /* Light neutral background */
    --alt-bg: #F8F9F9;     /* White for contrast sections */
    --btn-hover-primary: #FF5C85;  /* Brighter rose hover for main buttons */
    --btn-hover-secondary: #F2B9BB; /* Slightly deeper blush hover for secondary buttons */
}

/* ===============================
   2. BASE STYLES
=============================== */
body {
    font-family: 'Nunito Sans', sans-serif;
    margin: 0;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
}

h2 {
    font-family: 'Playfair Display', serif; /* Elegant headings */
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
    color: var(--accent); /* Accent color for headings */
}

h3 {
    font-family: 'Playfair Display', serif;
    margin: 0.5rem 0;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ===============================
   3. HEADER
=============================== */
header {
    background: var(--primary);
    color: white;
    text-align: center;
    padding: 3rem 1rem 2rem;
}

header h1 {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    margin: 0;
    letter-spacing: 1px;
}

header p {
    font-size: 1.2rem;
    margin-top: 0.5rem;
}

header nav ul {
    display: flex;
    justify-content: center; /* centers nav links */
    align-items: center;
    gap: 1.5rem;             /* space between items */
    padding: 1rem 0;          /* spacing above/below nav */
    list-style: none;
    margin: 0;
    margin-top: 1.2rem;       /* pulls nav closer to subtitle for visual connection */
}

header nav a {
    position: relative;
    color: white;
}
header nav a::after {
    content: '';
    position: absolute;
    left: 0; bottom: -3px;
    width: 0; height: 2px;
    background: linear-gradient(90deg, var(--accent), var(--btn-hover-primary));
    transition: width 0.3s;
}
header nav a:hover::after {
    width: 100%;
}

/* ===============================
   4. SECTIONS
=============================== */
.section {
    padding: 4rem 1rem;
    max-width: 1000px;
    margin: auto;
    text-align: center;
}

.alt-bg {
    background: var(--alt-bg);
    border-top: 2px solid rgba(0,0,0,0.05);
    border-bottom: 2px solid rgba(0,0,0,0.05);
}

.intro-text {
    max-width: 750px;
    margin: 0 auto 2rem;
    font-size: 1.05rem;
    color: #444;
}

/* ===============================
   5. BUTTONS
=============================== */
/* Primary Buttons */
.btn {
    display: inline-block;
    background: var(--accent);
    color: white;
    border-radius: 6px;
    font-size: 0.95rem;
    padding: 0.6rem 1.2rem;
    margin: 0.5rem;
    font-weight: 600;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1); /* subtle depth */
}

.btn:hover {
    background: var(--btn-hover-primary); /* brighter rose hover */
    transform: scale(1.05);               /* subtle lift */
    box-shadow: 0 4px 12px rgba(0,0,0,0.15); /* stronger shadow on hover */
}

/* Secondary Buttons - softer, less prominent actions */
.btn-secondary {
    background: var(--secondary); /* blush background */
    color: var(--accent);          /* rose text */
}

.btn-secondary:hover {
    background: var(--btn-hover-secondary); /* slightly deeper blush hover */
    color: white;                          /* invert text for clarity */
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* ===============================
   6. TECH PORTFOLIO GRID
=============================== */
.grid {
    display: grid;
    gap: 2rem;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    margin-top: 2.5rem;
}

.card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    text-align: center;
    min-height: 350px;
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.15);
}

.card img {
    width: 65%;
    height: auto;
    margin: 2rem auto 1rem;
    display: block;
    object-fit: contain;
    transition: transform 0.2s; /* subtle zoom on hover */
}

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

.card-content {
    padding: 1rem;
}

/* ===============================
   7. WEB DESIGN PROJECT GRID
=============================== */
.projects-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    margin-top: 2.5rem;
}

.project-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.1);
    max-width: 350px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
}

.project-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.15);
}

.project-card img {
    width: 100%;
    height: 220px;
    object-fit: contain;
    transition: transform 0.2s;
}

.project-card:hover img {
    transform: scale(1.02); /* subtle zoom for polish */
}

.project-info {
    padding: 1rem;
}

/* ===============================
   8. WAVE HAND ANIMATION
=============================== */
.wave-hand {
    display: inline-block;
    margin-left: 0.5rem;
    transform-origin: 70% 70%;
    animation: wave-bounce 2s infinite;
    font-size: 2.2rem;
}

@keyframes wave-bounce {
    0%,100% { transform: rotate(0deg) translateY(0); }
    10%,30%,50%,70%,90% { transform: rotate(15deg) translateY(-2px); }
    20%,40%,60%,80% { transform: rotate(-10deg) translateY(2px); }
}

/* ===============================
   9. FOOTER
=============================== */
footer {
    text-align: center;
    padding: 2rem 1rem;
    background: var(--secondary); /* blush background */
    color: var(--accent);          /* rose text */
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.5px;
    margin-top: 4rem;
}

/* ===============================
   10. RESPONSIVE
=============================== */
@media (max-width: 900px) {
    header h1 { font-size: 2.8rem; }
}

@media (max-width: 600px) {
    header h1 { font-size: 2rem; }
    .btn { padding: 0.5rem 1rem; font-size: 0.9rem; }
    .section { padding: 3rem 1rem; } /* reduce padding for small screens */
    footer { padding: 2rem 1rem 3rem; }
}

/* ===============================
   11. FLOW-OPTIMIZED SPACING
=============================== */

/* About Section: reduce bottom padding */
#about.section {
    padding-bottom: 2rem; /* tighter spacing after intro */
}

/* Tech Portfolio Section: reduce top and bottom padding */
#portfolio.section {
    padding-top: 2rem;      /* less space above heading */
    padding-bottom: 2rem;   /* tighter space below cards */
}

/* Tech Portfolio grid: reduce margins around cards */
#portfolio .grid {
    margin-top: 1rem;      /* less space above cards */
    margin-bottom: 1rem;   /* less space before Resume button */
}

/* Tech Portfolio Resume button: tighter spacing below cards */
#portfolio .btn {
    margin-top: 0.5rem;    /* slightly tighter than before */
}

/* Web Design Section: reduce top padding and intro text spacing */
#webdesign.section {
    padding-top: 2rem;       /* less space above heading */
    padding-bottom: 2rem;    /* optional: consistent padding below */
}

#webdesign .intro-text {
    margin-bottom: 1.5rem;   /* less gap before project cards */
}

/* Web Design Project grid: tighten spacing above grid */
#webdesign .projects-grid {
    margin-top: 1rem;
}

/* ===============================
   12. MOBILE-SPECIFIC FLOW TWEAKS
=============================== */
@media (max-width: 600px) {
    #about.section,
    #portfolio.section,
    #webdesign.section {
        padding-top: 1.5rem;
        padding-bottom: 2rem;
    }

    #portfolio .grid,
    #webdesign .projects-grid {
        margin-top: 0.5rem;
        margin-bottom: 0.5rem;
    }

    #portfolio .btn {
        margin-top: 0.5rem;
    }
}

@media (max-width: 768px) {
    header nav ul {
        flex-direction: row; /* keep buttons in a row */
        flex-wrap: wrap;     /* allow wrapping if they don't fit */
        gap: 1rem;
        padding: 1rem 0;
    }
}

/* ===============================
   13. CLICKABLE CARD HINT
=============================== */
.clickable-card { cursor:pointer;}
.clickable-card .click-hint { display:block; margin-top:0.8rem; font-size:0.85rem; font-weight:600; color:var(--accent); opacity:0.8; transition:opacity 0.2s;}
.clickable-card:hover .click-hint { opacity:1; text-decoration:underline;}