@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --primary: #860038;
    --primary-hover: #6d002e;
    --bg-main: #f8fafc;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --card-bg: #ffffff;
    --border-color: #e2e8f0;
}

[data-theme="dark"] {
    --bg-main: #020617;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --card-bg: #0f172a;
    --border-color: #1e293b;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    margin: 0;
    transition: background-color 0.3s, color 0.3s;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Header */
header {
    padding: 1.5rem 0;
    border-bottom: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 100;
}

[data-theme="dark"] header {
    background: rgba(15, 23, 42, 0.8);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 500;
    transition: color 0.2s;
}

.nav-links a:hover {
    color: var(--primary);
}

.btn-admin {
    background-color: var(--primary);
    color: white !important;
    padding: 0.6rem 1.2rem;
    border-radius: 0.5rem;
    transition: background-color 0.2s;
}

.btn-admin:hover {
    background-color: var(--primary-hover);
}

/* Hero Section */
.hero {
    padding: 6rem 0;
    text-align: center;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    background: linear-gradient(135deg, #860038 0%, #6d002e 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 2rem;
}

/* Featured Licitaciones */
.section-title {
    margin-bottom: 3rem;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
}

.card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 2rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
}

.card-tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    background: rgba(134, 0, 56, 0.1);
    color: var(--primary);
    margin-bottom: 1rem;
}

.card h3 {
    margin: 0 0 1rem;
    font-size: 1.25rem;
}

.card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-color);
    padding-top: 1rem;
    font-size: 0.875rem;
}

.price {
    font-weight: 700;
    color: var(--primary);
}

/* Footer */
footer {
    margin-top: 6rem;
    padding: 4rem 0;
    background: var(--card-bg);
    border-top: 1px solid var(--border-color);
    text-align: center;
    color: var(--text-muted);
}

/* Forms */
.form-section {
    max-width: 800px;
    margin: 4rem auto;
}

.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-main);
}

input[type="text"],
input[type="email"],
input[type="number"],
input[type="date"],
input[type="datetime-local"],
input[type="file"],
select,
textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    border: 1px solid var(--border-color);
    background: var(--card-bg);
    color: var(--text-main);
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(134, 0, 56, 0.1);
}

.help-text {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

@media (max-width: 768px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
}

.form-header {
    text-align: center;
    margin-bottom: 3rem;
}

.form-header h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.section-divider {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 2.5rem 0 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--border-color);
    color: var(--primary);
}

.alert {
    padding: 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.alert-danger {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fee2e2;
}

/* Estados de Licitación */
.status-open { background: rgba(34, 197, 94, 0.1) !important; color: #15803d !important; }
.status-closed { background: rgba(245, 158, 11, 0.1) !important; color: #b45309 !important; }
.status-awarded { background: rgba(59, 130, 246, 0.1) !important; color: #1d4ed8 !important; }

