/* General Styles */
body {
    font-family: sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f4f4f4;
    margin: 0;
    padding: 20px;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background: #fff;
    padding: 20px 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    text-align: center;
}

header h1 {
    margin-bottom: 0.5rem;
    font-size: 2.5rem;
    height: 100px; /* Match SVG height */
    display: flex;
    justify-content: center;
    align-items: center;
}

header h1 object {
    height: 100px; /* Match SVG height */
    width: 400px; /* Match SVG width */
}

.tagline {
    color: #666;
    margin-bottom: 2rem;
}

main p {
    text-align: left;
    margin-bottom: 1rem;
}

.cta-button {
    display: inline-block;
    background-color: #007bff;
    color: #fff;
    padding: 15px 30px;
    text-decoration: none;
    border-radius: 5px;
    font-size: 1.2rem;
    margin-top: 1rem;
    transition: background-color 0.3s ease;
}

.cta-button:hover {
    background-color: #0056b3;
}

.week-info {
    text-align: center;
    font-size: 0.9rem;
    color: #666;
    margin-top: 0.75rem;
}

/* Print Page Styles */
#grid-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(13, 1fr);
    width: 180mm; /* Approx A4/Letter width with margins */
    height: 260mm; /* Approx A4/Letter height with margins */
    margin: auto;
    border: 1px solid #ccc; /* Visible on screen only */
}

.grid-cell {
    border: 1px dotted #eee; /* Faint border for visibility on screen */
    position: relative;
}

#test-pattern {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
    padding: 5px;
}

.color-boxes {
    display: flex;
    gap: 5px;
    margin-bottom: 5px;
}

.color-box {
    width: 1cm;
    height: 1cm;
    print-color-adjust: exact;
    -webkit-print-color-adjust: exact;
}

.cyan { background-color: cyan; }
.magenta { background-color: magenta; }
.yellow { background-color: yellow; }
.black { background-color: black; }

.week-text {
    font-size: 8pt;
    color: black;
}

/* Print-specific Styles */
@media print {
    body {
        margin: 0;
        padding: 0;
        background-color: #fff;
    }

    #grid-container {
        width: 100%;
        height: 100vh; /* Fill the page */
        border: none;
    }

    .grid-cell {
        border: none;
    }

    /* Ensure only the test pattern is visible */
    body > *:not(#grid-container) {
        display: none;
    }
}

/* Reminder Section Styles */
.reminder-section {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #eee;
}

.reminder-note {
    font-size: 0.9rem;
    color: #666;
    margin-top: -1rem;
    margin-bottom: 1.5rem;
}

.reminder-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin: 1.5rem 0;
}

.reminder-controls label {
    font-weight: bold;
}

.reminder-controls select,
.reminder-controls input[type="time"] {
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1rem;
}

.refresh-button {
    background: none;
    border: 1px solid #ccc;
    border-radius: 4px;
    padding: 6px 10px;
    cursor: pointer;
    font-size: 1.2rem;
    line-height: 1;
    color: #333;
}

.refresh-button:hover {
    background-color: #f0f0f0;
}

.calendar-links {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.calendar-button {
    display: inline-block;
    background-color: #28a745;
    color: #fff;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
    font-size: 1rem;
    transition: background-color 0.3s ease;
}

.calendar-button:hover {
    background-color: #218838;
}

#outlook-link {
    background-color: #0078d4;
}
#outlook-link:hover {
    background-color: #005a9e;
}

#ical-link {
    background-color: #6c757d;
}
#ical-link:hover {
    background-color: #5a6268;
}

.calendar-footnote {
    font-size: 0.8rem;
    color: #6c757d;
    margin-top: 1.5rem;
}

/* Footer and Share Section */
.site-footer {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #eee;
    text-align: center;
}

.share-section h3 {
    margin-bottom: 1rem;
    font-size: 1.5rem;
    color: #333;
}

.share-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.share-button {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 5px;
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    transition: opacity 0.3s ease;
    border: none;
    cursor: pointer;
    font-family: sans-serif;
    font-size: 1rem;
}

.share-button:hover {
    opacity: 0.85;
}

.share-button.bluesky { background-color: #0085FF; }
.share-button.facebook { background-color: #1877F2; }
.share-button.linkedin { background-color: #0A66C2; }
.share-button.copy-link { background-color: #6c757d; }
