/* Base Variables */
:root {
    --primary: #ff7a00;      /* accent color (HubSpot orange) */
    --gray-bg: #f6f7f9;      /* dotted background fallback */
    --dark:    #111;         /* dark header background */
    --border:  #e5e7eb;      /* light gray border */
    --text-primary: #333;    /* primary text color */
    --text-secondary: #6b7280; /* secondary text color */
    --danger: #dc3545;       /* danger/error color */
    --success: #28a745;      /* success color */
    --info: #17a2b8;         /* info color */
    --warning: #ffc107;      /* warning color */
}

/* Base Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: Inter, system-ui, -apple-system, sans-serif;
}

body {
    background: var(--gray-bg)
                url("/static/img/bg-dots.png")
                repeat center;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    color: var(--text-primary);
    flex-direction: column;
}

/* Content Wrapper */
.content-wrapper {
    width: 100%;
    max-width: 1400px;
    border-radius: 12px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
    background: #fff;
    overflow: hidden;
    margin: 24px auto;
    display: flex;
    flex-direction: column;
}

/* Header Styling */
.content-header {
    background: var(--dark);
    color: #fff;
    padding: 20px 28px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-radius: 12px 12px 0 0;
}

.content-header h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 600;
    font-size: 1.2rem;
    line-height: 1;
}

.content-header img {
    width: 28px;
    height: 28px;
}

/* Content Body */
.content-body {
    padding: 32px 28px;
}

/* Footer */
.content-footer {
    padding: 16px 28px;
    border-top: 1px solid var(--border);
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Flash Messages */
.flash-messages {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    max-width: 400px;
}

.flash-message {
    padding: 12px 16px;
    margin-bottom: 10px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    animation: slide-in 0.3s ease-out;
}

.flash-message.success {
    background-color: #d4edda;
    border-color: #c3e6cb;
    color: #155724;
}

.flash-message.error {
    background-color: #f8d7da;
    border-color: #f5c6cb;
    color: #721c24;
}

.flash-message.warning {
    background-color: #fff3cd;
    border-color: #ffeeba;
    color: #856404;
}

.flash-message.info {
    background-color: #d1ecf1;
    border-color: #bee5eb;
    color: #0c5460;
}

@keyframes slide-in {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Form Elements */
.form-field {
    position: relative;
    margin-bottom: 18px;
}

.form-field input,
.form-field select,
.form-field textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 0.95rem;
    background: #f9fafb;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(255, 122, 0, 0.1);
}

.form-field label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 0.9rem;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 20px;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-primary {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.btn-primary:hover {
    opacity: 0.9;
}

.btn-outline {
    border-color: var(--border);
    color: var(--text-primary);
}

.btn-outline:hover {
    background-color: #f5f5f5;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.85rem;
}

.btn-lg {
    padding: 16px 24px;
    font-size: 1.1rem;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Space Grotesk', sans-serif;
    margin-bottom: 0.5em;
}

p {
    margin-bottom: 1em;
    line-height: 1.6;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: #e66e00;
}

.text-muted {
    color: var(--text-secondary);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .content-wrapper {
        max-width: 100%;
        margin: 0;
        border-radius: 0;
    }
    
    body {
        padding: 0;
    }
}

/* Utility classes */
.mb-0 { margin-bottom: 0 !important; }
.mt-0 { margin-top: 0 !important; }
.mb-1 { margin-bottom: 0.5rem !important; }
.mt-1 { margin-top: 0.5rem !important; }
.mb-2 { margin-bottom: 1rem !important; }
.mt-2 { margin-top: 1rem !important; }
.mb-3 { margin-bottom: 1.5rem !important; }
.mt-3 { margin-top: 1.5rem !important; }
.mb-4 { margin-bottom: 2rem !important; }
.mt-4 { margin-top: 2rem !important; }

.text-center { text-align: center !important; }
.text-right { text-align: right !important; }
.text-left { text-align: left !important; }

.d-flex { display: flex !important; }
.justify-between { justify-content: space-between !important; }
.align-center { align-items: center !important; }
.flex-column { flex-direction: column !important; }