* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(135deg, #f5f1e8 0%, #e8dcc8 100%);
    background-attachment: fixed;
    font-family: 'Lora', serif;
    color: #2c2c2c;
    line-height: 1.8;
    padding: 40px 20px;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        repeating-linear-gradient(90deg, transparent, transparent 2px, rgba(0,0,0,.02) 2px, rgba(0,0,0,.02) 4px),
        repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0,0,0,.02) 2px, rgba(0,0,0,.02) 4px);
    pointer-events: none;
    z-index: -1;
}

.container {
    max-width: 700px;
    margin: 0 auto;
    background: #faf7f0;
    padding: 60px;
    box-shadow: 0 10px 40px rgba(0,0,0,.1);
    position: relative;
}

.container::before {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    background: inherit;
    z-index: -1;
    opacity: 0.3;
    filter: blur(2px);
}

header {
    margin-bottom: 50px;
    border-bottom: 3px dashed #8b7355;
    padding-bottom: 30px;
}

h1 {
    font-family: 'Caveat', cursive;
    font-size: 3.5rem;
    margin-bottom: 10px;
    transform: rotate(-2deg);
    color: #5a4a3a;
}

.subtitle {
    font-family: 'Caveat', cursive;
    font-size: 1.3rem;
    color: #8b7355;
    font-style: italic;
    transform: rotate(1deg);
}

.subtitle a {
    color: #8b7355;
}

article {
    margin-bottom: 50px;
}

article h2 {
    font-family: 'Caveat', cursive;
    font-size: 2.2rem;
    margin-bottom: 15px;
    color: #5a4a3a;
    transform: rotate(-1deg);
    position: relative;
}

article h2::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 80%;
    height: 2px;
    background: linear-gradient(90deg, #d4a574 0%, transparent 100%);
}

article p {
    margin-bottom: 20px;
    text-align: justify;
    font-size: 1.05rem;
}

.meta {
    font-family: 'Caveat', cursive;
    font-size: 1.1rem;
    color: #8b7355;
    margin-bottom: 25px;
    font-style: italic;
}

.highlight {
    background: linear-gradient(120deg, rgba(212, 165, 116, 0.2) 0%, transparent 100%);
    padding: 0 4px;
    font-style: italic;
}

blockquote {
    margin: 30px 0;
    padding: 20px 25px;
    border-left: 4px dashed #d4a574;
    background: rgba(212, 165, 116, 0.08);
    font-style: italic;
    transform: rotate(0.5deg);
    color: #5a4a3a;
}

blockquote::before {
    content: '"';
    font-family: 'Caveat', cursive;
    font-size: 3rem;
    color: #d4a574;
    line-height: 0;
    margin-right: 5px;
}

.footer-note {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px dashed #8b7355;
    text-align: center;
    font-family: 'Caveat', cursive;
    font-size: 1.2rem;
    color: #8b7355;
}

.loader {
    text-align: center;
    font-family: 'Caveat', cursive;
    font-size: 1.3rem;
    color: #8b7355;
    padding: 20px 0;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(44, 44, 44, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.modal-box {
    background: #faf7f0;
    padding: 40px;
    max-width: 90%;
    width: 340px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0,0,0,.2);
}

.modal-box p {
    font-family: 'Caveat', cursive;
    font-size: 1.6rem;
    color: #5a4a3a;
    margin-bottom: 20px;
}

.modal-box button {
    display: block;
    width: 100%;
    font-family: 'Caveat', cursive;
    font-size: 1.3rem;
    color: #faf7f0;
    background: #8b7355;
    border: none;
    padding: 12px 20px;
    margin-bottom: 12px;
    cursor: pointer;
    border-radius: 2px;
}

.modal-box button:last-child {
    margin-bottom: 0;
}

.modal-box button:hover {
    background: #5a4a3a;
}

/* Admin pages */

.admin-container {
    max-width: 600px;
}

.error-note {
    color: #a5432f;
    font-family: 'Caveat', cursive;
    font-size: 1.2rem;
    margin-bottom: 20px;
}

.notice-note {
    color: #5a4a3a;
    font-family: 'Caveat', cursive;
    font-size: 1.3rem;
    margin-bottom: 20px;
}

.admin-subheading {
    font-family: 'Caveat', cursive;
    font-size: 1.8rem;
    color: #5a4a3a;
    margin: 40px 0 15px;
    border-top: 3px dashed #8b7355;
    padding-top: 30px;
}

.admin-form {
    display: flex;
    flex-direction: column;
    margin-bottom: 20px;
}

.admin-form label {
    font-family: 'Caveat', cursive;
    font-size: 1.2rem;
    color: #8b7355;
    margin-top: 15px;
    margin-bottom: 5px;
}

.admin-form input,
.admin-form textarea {
    font-family: 'Lora', serif;
    font-size: 1rem;
    padding: 10px 12px;
    border: 2px dashed #d4a574;
    background: rgba(212, 165, 116, 0.06);
    color: #2c2c2c;
    border-radius: 2px;
}

.admin-form textarea {
    resize: vertical;
    font-family: 'Lora', serif;
}

.toolbar {
    display: flex;
    gap: 6px;
    margin-top: 5px;
}

.toolbar-btn {
    font-family: 'Lora', serif;
    font-size: 0.9rem;
    color: #5a4a3a;
    background: rgba(212, 165, 116, 0.15);
    border: 2px dashed #d4a574;
    border-radius: 2px;
    width: 34px;
    height: 34px;
    cursor: pointer;
}

.toolbar-btn:hover {
    background: rgba(212, 165, 116, 0.35);
}

.admin-form button {
    align-self: flex-start;
    margin-top: 20px;
    font-family: 'Caveat', cursive;
    font-size: 1.3rem;
    color: #faf7f0;
    background: #8b7355;
    border: none;
    padding: 10px 25px;
    cursor: pointer;
    border-radius: 2px;
}

.admin-form button:hover {
    background: #5a4a3a;
}

.admin-entry-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px dashed #d4a574;
    font-size: 0.95rem;
}

.admin-entry-row form {
    margin: 0;
}

.delete-btn {
    font-family: 'Caveat', cursive;
    font-size: 1.05rem;
    color: #a5432f;
    background: none;
    border: none;
    cursor: pointer;
    text-decoration: underline;
}

@media (max-width: 768px) {
    .container {
        padding: 30px;
    }

    h1 {
        font-size: 2.5rem;
    }

    article h2 {
        font-size: 1.8rem;
    }
}
