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

body {
    font-family: 'Roboto', sans-serif;
    background-color: #fcf9f2;
    color: #333;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
}

/* Header & Nav */
header {
    width: 100%;
    background-color: #2c3e50;
    padding: 15px 0;
    text-align: center;
}

nav a {
    color: white;
    text-decoration: none;
    margin: 0 15px;
    font-size: 1rem;
    font-weight: 400;
}

nav a:hover {
    text-decoration: underline;
}

.container {
    text-align: center;
    max-width: 1000px;
    padding: 30px 20px;
    flex: 1; /* 푸터를 하단에 밀어내기 위함 */
}

h1 {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 10px;
}

.subtitle {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 30px;
}

/* Ad Slots (광고 자리 임시 디자인) */
.ad-slot {
    width: 100%;
    max-width: 728px;
    height: 90px;
    background-color: #e0e0e0;
    margin: 20px auto;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #888;
    border: 1px dashed #ccc;
}

.cards-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    margin-bottom: 30px;
}

/* Card Styles */
.card-container {
    background-color: transparent;
    width: 180px;
    height: 270px;
    perspective: 1000px;
    cursor: pointer;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.6s;
    transform-style: preserve-3d;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    border-radius: 10px;
}

.card-container.flipped .card-inner {
    transform: rotateY(180deg);
}

.card-front, .card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 15px;
}

.card-front {
    background: linear-gradient(135deg, #d4af37 0%, #b8972c 100%);
    color: white;
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    border: 2px solid #e5c158;
}

.card-front::after {
    content: "Daily \A Blessing";
    white-space: pre-wrap;
    line-height: 1.4;
}

.card-back {
    background-color: #ffffff;
    color: #333;
    transform: rotateY(180deg);
    border: 1px solid #ddd;
}

.verse-text {
    font-family: 'Playfair Display', serif;
    font-size: 1rem;
    font-style: italic;
    margin-bottom: 15px;
    line-height: 1.4;
}

.verse-ref {
    font-size: 0.85rem;
    font-weight: bold;
    color: #d4af37;
}

#refresh-btn {
    padding: 12px 30px;
    font-size: 1.1rem;
    background-color: #2c3e50;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
    margin-bottom: 40px;
}

#refresh-btn:hover {
    background-color: #1a252f;
}

/* Devotion Area (애드센스를 위한 텍스트 영역) */
.devotion-section {
    background-color: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    margin: 20px auto 40px;
    max-width: 800px;
    text-align: left;
    transition: opacity 0.5s ease-in-out;
}

.devotion-section.hidden {
    display: none;
}

.devotion-section h2 {
    color: #d4af37;
    margin-bottom: 15px;
    font-family: 'Playfair Display', serif;
}

.devotion-section h3 {
    font-size: 1.2rem;
    color: #2c3e50;
    margin-bottom: 15px;
    font-style: italic;
}

.devotion-section p {
    font-size: 1.05rem;
    line-height: 1.6;
    color: #444;
}

/* Footer */
footer {
    width: 100%;
    background-color: #2c3e50;
    color: #ccc;
    text-align: center;
    padding: 20px 0;
    margin-top: auto;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .ad-slot { height: 50px; }
    .card-container { width: 140px; height: 210px; }
    .verse-text { font-size: 0.9rem; }
}
/* Header Layout Update */
.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}
.logo {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    font-weight: bold;
    color: #d4af37;
}

/* Content Feed for SEO */
.content-feed {
    text-align: left;
    margin-top: 50px;
    border-top: 2px solid #eaeaea;
    padding-top: 30px;
}
.content-feed h2 {
    font-family: 'Playfair Display', serif;
    color: #2c3e50;
    margin-bottom: 30px;
    font-size: 2rem;
}
.devotion-post {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    margin-bottom: 30px;
}
.devotion-post h3 {
    color: #2c3e50;
    font-size: 1.4rem;
    margin-bottom: 10px;
}
.verse-quote {
    display: block;
    font-style: italic;
    color: #d4af37;
    font-weight: bold;
    margin-bottom: 15px;
}
.devotion-post p {
    font-size: 1.05rem;
    line-height: 1.7;
    color: #444;
}