/* ============================================================
   Co-Write shared styles
   ============================================================ */

/* Layout */
.container {
    max-width: 800px;
    width: 100%;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
}

    border: 1px solid #ccc;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
    width: 100%;
    box-sizing: border-box;
}

/* Typography */
h1 { color: #ff69b4; }

.cowrite-hero {
    position: relative;
    aspect-ratio: 1168 / 764;
    min-height: 261px;
    background-color: #1a0a12;
    background-size: cover;
    background-position: center top;
    background-repeat: no-repeat;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 20px 24px;
    box-sizing: border-box;
    margin-bottom: 24px;
    border-radius: 8px;
    overflow: hidden;
}

.cowrite-hero h1 {
    margin: 0;
    color: #fff;
    text-shadow: 0 2px 8px rgba(0,0,0,0.7);
}

.cowrite-hero__top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: absolute;
    top: 16px;
    left: 24px;
    right: 24px;
}

.cowrite-hero__hearts {
    color: #fff;
    font-size: 1em;
    font-weight: bold;
    text-shadow: 0 1px 4px rgba(0,0,0,0.8);
}

.cowrite-hero .back-link {
    margin-bottom: 0;
    color: #fff;
    text-shadow: 0 1px 4px rgba(0,0,0,0.8);
}

.back-link {
    display: inline-block;
    margin-bottom: 20px;
}

.meta {
    color: #888;
    font-style: italic;
    margin-bottom: 30px;
    font-size: 0.9em;
}

.error  { color: #ff1493; }
.success { color: green; font-weight: bold; }

/* Story text */
.story-text {
    line-height: 1.8;
    font-size: 1.05em;
}

/* Proposals */
.proposal {
    margin: 20px 0;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    white-space: pre-wrap;
    line-height: 1.6;
}

/* Buttons */
button {
    background-color: #ff69b4;
    color: #1a1a1a;
    padding: 12px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    width: 100%;
    margin: 8px 0;
}
button:hover { background-color: #ff1493; }

.join-btn {
    display: inline-block;
    background: #ff69b4;
    color: #fff !important;
    padding: 7px 16px;
    text-decoration: none !important;
    border-radius: 4px;
    font-weight: bold;
    margin-top: 8px;
}
.join-btn:hover { background: #ff1493; }

.create-btn {
    display: inline-block;
    background: #ff69b4;
    color: #fff !important;
    padding: 10px 20px;
    text-decoration: none !important;
    border-radius: 5px;
    font-weight: bold;
    margin-bottom: 16px;
}
.create-btn:hover { background: #ff1493; }

/* Forms */
input, textarea, select {
    width: 100%;
    padding: 10px;
    margin: 5px 0;
    border: 1px solid #ff69b4;
    border-radius: 5px;
    box-sizing: border-box;
}

/* Index tabs */
.tabs {
    display: flex;
    margin-bottom: 20px;
    gap: 4px;
}
.tab {
    padding: 10px 20px;
    background: #333;
    color: #ccc;
    border: 1px solid #555;
    border-radius: 4px 4px 0 0;
    cursor: pointer;
}
.tab.active { background: #ff69b4; color: #fff; border-color: #ff69b4; }
.tab:not(.active):hover { background: #444; color: #fff; }

/* Story cards */
.story-card {
    margin-bottom: 10px;
    padding: 15px;
    border: 1px solid #444;
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.05);
}

.bank-warning {
    color: #ff69b4;
    font-size: 0.85em;
    font-style: italic;
    margin-top: 6px;
}
