/* Shared styles for the GitHub Post Creator PWA (index.html + share.html). */

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* ---------- Install / landing page (index.html) ---------- */

body.page-install {
    flex-direction: column;
    color: white;
}

.page-install .container {
    max-width: 500px;
    text-align: center;
}

.page-install h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 2rem;
}

.card {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    margin: 2rem 0;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    color: #333;
}

.install-btn {
    background: #2ea44f;
    color: white;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: transform 0.2s, background 0.2s;
    display: inline-block;
    text-decoration: none;
}

.install-btn:hover {
    background: #2c974b;
    transform: translateY(-2px);
}

.install-btn:active {
    transform: translateY(0);
}

.steps {
    text-align: left;
    margin-top: 1.5rem;
}

.step {
    margin: 1rem 0;
    padding-left: 2rem;
    position: relative;
}

.step::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #2ea44f;
    font-weight: bold;
    font-size: 1.2rem;
}

.emoji {
    font-size: 3rem;
    margin-bottom: 1rem;
}

#install-container {
    display: block;
}

#installed-container {
    display: none;
}

.success {
    color: #2ea44f;
    font-size: 1.2rem;
    font-weight: 600;
}

/* ---------- Share target page (share.html) ---------- */

.page-share .container {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    max-width: 400px;
    width: 100%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.page-share h1 {
    margin-bottom: 1.5rem;
    color: #333;
    font-size: 1.8rem;
}

.btn {
    display: block;
    width: 100%;
    padding: 1.2rem;
    margin: 1rem 0;
    border: 2px solid #e1e4e8;
    border-radius: 8px;
    background: white;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.2s;
    text-align: left;
    font-weight: 500;
}

.btn:hover {
    border-color: #2ea44f;
    background: #f6f8fa;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.btn:active {
    transform: translateY(0);
}

.icon {
    font-size: 1.5rem;
    margin-right: 0.5rem;
}

.info {
    background: #f6f8fa;
    padding: 1rem;
    border-radius: 8px;
    margin-top: 1.5rem;
    font-size: 0.9rem;
    color: #666;
    word-break: break-word;
}

/* Editable review fields (share.html) */

.fields {
    margin-bottom: 0.5rem;
}

.field {
    margin-bottom: 1rem;
    text-align: left;
}

.field label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: #444;
    margin-bottom: 0.35rem;
}

.field .hint {
    font-weight: 400;
    color: #888;
    font-size: 0.78rem;
}

.field input,
.field textarea,
.field select {
    width: 100%;
    padding: 0.7rem 0.75rem;
    border: 2px solid #e1e4e8;
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    color: #333;
    background: #fff;
    transition: border-color 0.2s;
}

.field input:focus,
.field textarea:focus,
.field select:focus {
    outline: none;
    border-color: #2ea44f;
}

.field textarea {
    resize: vertical;
    min-height: 4.5rem;
}

.field input.invalid {
    border-color: #d1242f;
}

.edit-note {
    font-size: 0.8rem;
    color: #555;
    background: #f0f6ff;
    border-left: 3px solid #2ea44f;
    padding: 0.6rem 0.75rem;
    border-radius: 6px;
    margin: 0.25rem 0 1.25rem;
    text-align: left;
}
