/* --- Global Variables --- */
:root {
    --color-lavender: #E6E6FA;
    --color-charcoal: #333333;
    --color-teal: #008080;
    --color-rose: #FFB6C1;
    --bg-light: #F9F9FB;
}

/* --- Base Styles --- */
* {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--bg-light);
    color: var(--color-charcoal);
    line-height: 1.6;
}

/* --- Layout Structure --- */
/* The key fix: Flex-direction column forces the Bridge to the bottom */
.page-wrapper {
    display: flex;
    flex-direction: column; 
    min-height: 100vh; /* Keeps the page full height */
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
}

main {
    flex: 1; /* This pushes everything below it (the Etsy bridge) to the bottom */
    width: 100%;
}

/* --- Header & Nav (Handled by Web Component) --- */
/* We keep basic styles here in case the JS fails to load */
header h1 {
    font-size: 1.8rem;
    margin-bottom: 5px;
}

/* --- Tool Components --- */
.tool-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.tool-card {
    background: white;
    padding: 25px;
    border: 1px solid var(--color-lavender);
    border-radius: 15px;
    text-align: center;
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

/* --- Etsy Bridge Container --- */
/* Ensure this is full width and clears any side-floats */
#etsy-bridge {
    width: 100%;
    margin-top: 50px;
    clear: both;
}

/* --- Table Styles (For Hook Converter) --- */
table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    margin-top: 10px;
}

th, td {
    padding: 15px;
    border-bottom: 1px solid #eee;
}

/* --- Mobile Responsiveness --- */
@media (max-width: 600px) {
    .page-wrapper {
        padding: 10px;
    }
    
    header h1 {
        font-size: 1.5rem;
    }
}
