/* --- Base Styles & Reset --- */
:root {
    --primary-color: #3a5a40; /* Dark Green */
    --secondary-color: #588157; /* Medium Green */
    --accent-color: #a3b18a; /* Light Green/Accent */
    --light-bg: #f4f7f6;
    --dark-text: #333333;
    --light-text: #ffffff;
    --border-radius: 8px;
    --box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.7;
    color: var(--dark-text);
    background-color: var(--light-bg);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex-grow: 1;
}

h1, h2, h3 {
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.8em;
    display: flex; /* Align emoji with text */
    align-items: center; /* Align emoji vertically */
}

/* Add emojis using ::before */
h1::before, h2::before {
    margin-right: 0.4em; /* Space after emoji */
    font-size: 0.9em; /* Slightly smaller emoji */
    opacity: 0.8; /* Slightly less prominent */
}

/* Specific Emojis for Headings */
header h1::before {
    content: '😂'; /* Emoji for main title */
}
.tool-container h2::before {
    content: '⚙️'; /* Gear emoji for tool section */
}
.features h2::before {
     content: '💡'; /* Idea emoji for features */
}
.page-content h2::before {
     content: '📄'; /* Document emoji for static pages */
}


h1 { font-size: 2.2rem; }
h2 { font-size: 1.8rem; }
h3 { font-size: 1.4rem; color: var(--secondary-color); }

p {
    margin-bottom: 1em;
    color: #555;
}

a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

img {
    max-width: 100%;
    height: auto;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Header --- */
header {
    background-color: var(--primary-color);
    color: var(--light-text);
    padding: 1rem 0;
    box-shadow: var(--box-shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

header .header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header .logo h1 a {
    color: var(--light-text);
    font-size: 1.8rem;
    font-weight: 700;
    text-decoration: none;
    display: flex; /* Align logo text and emoji */
    align-items: center;
}

header nav ul {
    list-style: none;
    display: flex;
}

header nav ul li {
    margin-left: 25px;
}

header nav ul li a {
    color: var(--light-text);
    font-weight: 600;
    padding: 5px 0;
    border-bottom: 2px solid transparent;
    transition: border-color 0.3s ease, color 0.3s ease;
}

header nav ul li a:hover,
header nav ul li a.active {
    color: var(--accent-color);
    border-bottom-color: var(--accent-color);
    text-decoration: none;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--light-text);
    font-size: 1.8rem;
    cursor: pointer;
}

/* --- Hero Section --- */
.hero {
    /* Consider adding a subtle, funny background pattern or image */
    background: linear-gradient(rgba(58, 90, 64, 0.85), rgba(58, 90, 64, 0.85)), url('https://source.unsplash.com/random/1600x500/?funny,abstract') no-repeat center center/cover; /* Random image for fun */
    color: var(--light-text);
    text-align: center;
    padding: 4rem 1rem;
    margin-bottom: 2rem;
}

.hero h2 {
    color: var(--light-text);
    font-size: 2.5rem;
    margin-bottom: 0.5em;
}
.hero h2::before {
    content: '🎉'; /* Party emoji for hero */
    font-size: 1em; /* Normal size */
    opacity: 1;
}

.hero p {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.95);
    max-width: 700px;
    margin: 0 auto;
}

/* --- Tool Container --- */
.tool-container {
    background-color: #ffffff;
    padding: 2.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    text-align: center;
    margin-top: 2rem;
    margin-bottom: 3rem;
}

.tool-container .instructions {
    color: #666;
    margin-bottom: 1.5rem;
    font-size: 1rem;
}
.tool-container .instructions::before {
    content: '👇'; /* Pointing down emoji */
    margin-right: 0.5em;
}

.input-area {
    margin-bottom: 1.5rem;
}

.input-area label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--primary-color);
}

#situationInput {
    width: 80%;
    max-width: 500px;
    padding: 12px 15px;
    border: 1px solid #ccc;
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

#situationInput:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(88, 129, 87, 0.2);
}

/* --- Buttons --- */
.cta-button {
    background-color: var(--secondary-color);
    color: var(--light-text);
    padding: 12px 30px;
    border: none;
    border-radius: var(--border-radius);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-flex; /* Align text and emoji */
    align-items: center;
    justify-content: center;
}

.cta-button::after { /* Add emoji after button text */
    content: '✨'; /* Sparkles emoji */
    margin-left: 0.5em;
    font-size: 1em;
    display: inline-block;
    transition: transform 0.3s ease;
}

.cta-button:hover {
    background-color: var(--primary-color);
    transform: translateY(-2px);
}
.cta-button:hover::after {
    transform: rotate(15deg) scale(1.1); /* Slight rotation on hover */
}

.cta-button:active {
    transform: translateY(0);
}
.cta-button:active::after {
    transform: rotate(0deg) scale(1);
}


/* --- Excuse Output Area --- */
.excuse-output {
    margin-top: 2rem;
    padding: 1.5rem;
    background-color: #e9f5e9;
    border-left: 5px solid var(--secondary-color);
    border-radius: var(--border-radius);
    min-height: 60px;
    text-align: left;
    transition: background-color 0.3s ease;
}

.excuse-output p {
    color: var(--dark-text);
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0;
    line-height: 1.5;
}

.excuse-output p:first-child:empty::before {
    content: '⏳ Waiting for your command...'; /* Placeholder text */
    color: #777;
    font-style: italic;
}

.excuse-output.loading p {
    font-style: italic;
    color: #888;
}


/* --- Features Section --- */
.features {
    padding: 3rem 0;
    text-align: center;
}
.features h2 {
    margin-bottom: 2rem;
}
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}
.feature-item {
    background: #fff;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.feature-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.1);
}

/* Using emojis directly as icons */
.feature-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    margin-bottom: 1rem;
    display: inline-flex; /* Use flex to center emoji */
    align-items: center;
    justify-content: center;
    font-size: 2.5rem; /* Larger emoji size */
    background-color: var(--accent-color); /* Background circle */
    color: var(--primary-color); /* Emoji color */
    margin-left: auto;
    margin-right: auto;
}

/* Set content for feature icons */
.feature-item:nth-child(1) .feature-icon::before { content: '⚡️'; } /* Zap */
.feature-item:nth-child(2) .feature-icon::before { content: '🤣'; } /* Rolling Laughing */
.feature-item:nth-child(3) .feature-icon::before { content: '📱'; } /* Mobile */

.feature-item h3 {
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* --- Static Page Content --- */
.page-content {
    background-color: #ffffff;
    padding: 2rem 2.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    margin-top: 2rem;
    margin-bottom: 3rem;
}

.page-content h2 {
    border-bottom: 2px solid var(--accent-color);
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
}

.page-content ul {
    margin-left: 20px;
    margin-bottom: 1em;
}
.page-content li {
    margin-bottom: 0.5em;
}
.page-content li::marker { /* Style list bullets if desired */
    color: var(--secondary-color);
}


/* --- Contact Form Specific Styles --- */
.form-group { margin-bottom: 1.5rem; }
.form-group label { display: block; margin-bottom: 0.5rem; font-weight: 600; }
.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%; padding: 10px; border: 1px solid #ccc;
    border-radius: var(--border-radius); font-size: 1rem;
}
.form-group textarea { resize: vertical; }

/* --- Footer --- */
footer {
    background-color: #333;
    color: #ccc;
    text-align: center;
    padding: 1.5rem 0;
    margin-top: auto;
    font-size: 0.9rem;
}

footer .container {
     display: flex;
     flex-direction: column;
     align-items: center;
}

footer p {
    margin-bottom: 0.5rem;
     color: #ccc;
}
/* Add emoji to copyright */
footer p::after {
    content: ' 🤪'; /* Silly face emoji */
    display: inline;
    margin-left: 5px;
}

footer .footer-nav ul {
    list-style: none;
    padding: 0;
    display: flex;
    gap: 15px;
     margin-top: 0.5rem;
}
footer .footer-nav ul li a { color: #ccc; text-decoration: none; }
footer .footer-nav ul li a:hover { color: var(--light-text); text-decoration: underline; }

/* --- Responsive Design --- */
@media (max-width: 768px) {
    h1 { font-size: 1.8rem; }
    h2 { font-size: 1.5rem; }
    .hero h2 { font-size: 2rem; }
    .hero p { font-size: 1rem; }

    /* Adjust emoji size/spacing on smaller screens if needed */
    h1::before, h2::before { font-size: 0.8em; margin-right: 0.3em; }


    header .header-content {
        flex-direction: column;
        text-align: center;
    }
    header .logo { margin-bottom: 0.5rem; }
     header nav {
        width: 100%;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
    header nav ul {
        display: none; flex-direction: column; width: 100%;
        background-color: var(--primary-color); position: absolute;
        top: 100%; left: 0; padding: 1rem 0; box-shadow: 0 5px 10px rgba(0,0,0,0.1);
    }
     header nav ul.active { display: flex; }
    header nav ul li { margin: 10px 0; text-align: center; }
    .menu-toggle { display: block; margin-left: auto; }

    #situationInput { width: 95%; }
    .tool-container, .page-content { padding: 1.5rem; }
     footer .container { flex-direction: column; }
    footer .footer-nav ul { margin-top: 1rem; }
}

@media (max-width: 480px) {
     h1 { font-size: 1.6rem; }
     header .logo h1 a { font-size: 1.4rem; }
     .hero h2 { font-size: 1.8rem; }
     .hero p { font-size: 0.9rem; }
     .cta-button { font-size: 1rem; padding: 10px 20px; }
     .excuse-output p { font-size: 1.1rem; }
     .feature-grid { grid-template-columns: 1fr; }
     .feature-icon { font-size: 2rem; width: 50px; height: 50px; }
}