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

        html, body {
            width: 100%;
            margin: 0;
            padding: 0;
        }

        body {
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            background-attachment: fixed;
            padding: 20px;
            box-sizing: border-box;
            min-height: 100vh;
        }

        .page-wrapper {
            padding-bottom: 20px;
        }

        .container {
            background: white;
            border-radius: 16px;
            width: 100%;
            max-width: 500px;
            box-shadow: 0 20px 40px rgba(0,0,0,0.1);
            display: flex;
            flex-direction: column;
            position: relative;
            margin: 0 auto;
        }

        .logo {
            text-align: center;
            margin-bottom: 24px;
            padding: 20px 32px 0;
            cursor: pointer;
            transition: opacity 0.2s ease;
        }

        .logo:hover {
            opacity: 0.8;
        }

        .logo img {
            width: 120px;
            height: auto;
            margin-bottom: 8px;
        }

        .logo h1 {
            background: linear-gradient(45deg, #22c55e, #8b5cf6, #06b6d4, #f97316, #ef4444);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
            font-size: 24px;
            font-weight: 700;
            margin-bottom: 4px;
            margin-top: 0;
        }

        .logo p {
            color: #666;
            font-size: 14px;
        }

        .connection-status {
            padding: 8px 12px;
            border-radius: 6px;
            text-align: center;
            margin: 0 32px 16px;
            font-size: 12px;
            font-weight: 600;
        }

        .online {
            background: #10b981;
            color: white;
        }

        .offline {
            background: #f59e0b;
            color: white;
        }

        .form-group {
            margin-bottom: 20px;
        }

        label {
            display: block;
            margin-bottom: 8px;
            font-weight: 600;
            color: #333;
            font-size: 14px;
        }

        input[type="text"],
        input[type="email"],
        select,
        textarea {
            width: 100%;
            padding: 16px;
            border: 2px solid #e1e5e9;
            border-radius: 8px;
            font-size: 16px;
            transition: border-color 0.3s ease;
            background: #fafafa;
            font-family: inherit;
        }

        input[type="text"]:focus,
        input[type="email"]:focus,
        select:focus,
        textarea:focus {
            outline: none;
            border-color: #667eea;
            background: white;
        }

        textarea {
            min-height: 80px;
            resize: vertical;
        }

        /* Hierarchical Creator Type Selector */
        .creator-type-selector {
            border: 2px solid #e1e5e9;
            border-radius: 8px;
            background: #fafafa;
            overflow: hidden;
            margin-top: 8px;
        }

        .creator-type-header {
            padding: 12px 16px;
            background: #f8fafc;
            border-bottom: 1px solid #e1e5e9;
            font-weight: 600;
            color: #374151;
            display: flex;
            align-items: center;
            justify-content: space-between;
        }

        .creator-type-nav {
            padding: 8px 16px;
            background: #f1f5f9;
            border-bottom: 1px solid #e1e5e9;
            display: none;
        }

        .creator-type-nav.visible {
            display: flex;
            align-items: center;
        }

        .nav-back {
            background: none;
            border: none;
            color: #667eea;
            cursor: pointer;
            display: flex;
            align-items: center;
            font-size: 14px;
            padding: 4px 8px;
            border-radius: 4px;
        }

        .nav-back:hover {
            background: #e2e8f0;
        }

        .nav-path {
            margin-left: 12px;
            font-size: 12px;
            color: #64748b;
        }

        .creator-type-list {
            max-height: 300px;
        }

        .creator-type-option {
            padding: 12px 16px;
            border-bottom: 1px solid #f1f5f9;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: space-between;
            transition: background 0.2s ease;
        }

        .creator-type-option:hover {
            background: #f8fafc;
        }

        .creator-type-option:last-child {
            border-bottom: none;
        }

        .creator-type-option.selected {
            background: #f0f9ff;
            border-left: 4px solid #667eea;
        }

        .option-content {
            display: flex;
            align-items: center;
            flex: 1;
        }

        .option-icon {
            width: 16px;
            height: 16px;
            margin-right: 8px;
            color: #64748b;
        }

        .check-icon {
            color: #10b981;
        }

        .chevron-icon {
            color: #94a3b8;
        }

        .other-input {
            padding: 12px 16px;
            border-top: 1px solid #e1e5e9;
            background: #fafafa;
            display: none;
        }

        .other-input.visible {
            display: block;
        }

        .other-input input {
            padding: 8px 12px;
            font-size: 14px;
            margin: 0;
        }

        .selected-types {
            margin-top: 12px;
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
        }

        .selected-type-tag {
            background: #e2e8f0;
            color: #475569;
            padding: 4px 8px;
            border-radius: 16px;
            font-size: 12px;
            display: flex;
            align-items: center;
        }

        .remove-type {
            margin-left: 6px;
            background: none;
            border: none;
            color: #64748b;
            cursor: pointer;
            font-size: 14px;
            line-height: 1;
        }

        /* Privacy Controls */
        .privacy-section {
            background: #f8fafc;
            border: 1px solid #e2e8f0;
            border-radius: 8px;
            padding: 16px;
            margin-top: 20px;
        }

        .privacy-section h3 {
            color: #374151;
            font-size: 16px;
            margin-bottom: 12px;
        }

        .privacy-option {
            display: flex;
            align-items: flex-start;
            margin-bottom: 12px;
            gap: 12px;
        }

        .privacy-option:last-child {
            margin-bottom: 0;
        }

        .privacy-option input[type="checkbox"] {
            width: auto;
            margin: 0;
            margin-top: 2px;
        }

        .privacy-option label {
            margin: 0;
            font-weight: 500;
            font-size: 14px;
            line-height: 1.4;
            cursor: pointer;
        }

        .privacy-description {
            font-size: 12px;
            color: #64748b;
            margin-top: 4px;
        }

        /* Member showcase section */
        .member-showcase {
            background: #f0fdf4;
            border: 1px solid #bbf7d0;
            border-radius: 8px;
            padding: 16px;
            margin-top: 16px;
            display: block; /* Always visible for now */
        }

        .member-showcase.visible {
            display: block;
        }

        .member-showcase h4 {
            color: #065f46;
            font-size: 14px;
            margin-bottom: 8px;
        }

        .member-showcase textarea {
            background: white;
            border-color: #bbf7d0;
            font-size: 14px;
            min-height: 60px;
        }

        .member-showcase .char-count {
            text-align: right;
            font-size: 12px;
            color: #059669;
            margin-top: 4px;
        }

        .submit-btn {
            width: 100%;
            padding: 16px;
            background: #667eea;
            color: white;
            border: none;
            border-radius: 8px;
            font-size: 16px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.3s ease;
            margin-top: 24px;
        }

        .submit-btn:hover {
            background: #5a6fd8;
            transform: translateY(-2px);
        }

        .submit-btn:disabled {
            background: #ccc;
            cursor: not-allowed;
            transform: none;
        }

        .success {
            background: #10b981;
            color: white;
            padding: 12px;
            border-radius: 8px;
            text-align: center;
            margin: 0 32px 16px;
            display: none;
        }

        .error {
            background: #ef4444;
            color: white;
            padding: 12px;
            border-radius: 8px;
            text-align: center;
            margin: 0 32px 16px;
            display: none;
        }

        /* Content Area */
        .scrollable-content {
            padding: 0 32px;
        }

        /* Fixed Bottom Button */
        .fixed-bottom {
            padding: 16px 32px 32px;
            background: white;
        }

        /* Creator Type Modal */
        .modal-overlay {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(0, 0, 0, 0.5);
            display: flex;
            align-items: center;
            justify-content: center;
            z-index: 1000;
        }

        .modal-content {
            background: white;
            border-radius: 12px;
            width: 90%;
            max-width: 500px;
            max-height: 90vh;
            overflow: hidden;
            display: flex;
            flex-direction: column;
        }

        .modal-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 24px 24px 16px;
            border-bottom: 1px solid #e2e8f0;
        }

        .modal-scrollable-content {
            flex: 1;
            overflow-y: auto;
            padding: 20px 24px;
        }

        .modal-fixed-bottom {
            padding: 16px 24px 24px;
            background: white;
            border-top: 1px solid #e2e8f0;
        }

        .modal-title {
            font-size: 18px;
            font-weight: 600;
            color: #1f2937;
        }

        .modal-close {
            background: none;
            border: none;
            font-size: 24px;
            cursor: pointer;
            color: #9ca3af;
        }

        .creator-type-categories {
            display: flex;
            flex-direction: column;
            gap: 16px;
        }

        .creator-category {
            border: 1px solid #e5e7eb;
            border-radius: 12px;
            overflow: hidden;
        }

        .category-header {
            background: #f8fafc;
            padding: 12px 16px;
            border-bottom: 1px solid #e5e7eb;
            cursor: pointer;
            display: flex;
            justify-content: space-between;
            align-items: center;
            transition: all 0.2s;
        }

        .category-header:hover {
            background: #f1f5f9;
        }

        .category-header.selected {
            background: #e0e7ff;
            border-bottom-color: #667eea;
        }

        .category-title {
            font-size: 15px;
            font-weight: 600;
            color: #374151;
        }

        .category-description {
            font-size: 12px;
            color: #6b7280;
            margin-top: 2px;
        }

        .category-check {
            width: 18px;
            height: 18px;
            border: 2px solid #d1d5db;
            border-radius: 4px;
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-size: 12px;
        }

        .category-check.selected {
            background: #667eea;
            border-color: #667eea;
        }

        .subcategories {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 12px;
            padding: 16px;
            background: #fafbfc;
            border-top: 1px solid #e5e7eb;
        }

        .subcategory-card {
            border: 2px solid #e5e7eb;
            border-radius: 8px;
            padding: 12px;
            cursor: pointer;
            transition: all 0.2s;
            background: white;
            box-shadow: 0 1px 3px rgba(0,0,0,0.1);
            position: relative;
        }

        .subcategory-card:hover {
            border-color: #667eea;
            background: #f8fafc;
            transform: translateY(-1px);
            box-shadow: 0 2px 6px rgba(0,0,0,0.15);
        }

        .subcategory-card.selected {
            border-color: #667eea;
            background: #f0f9ff;
            box-shadow: 0 2px 6px rgba(102, 126, 234, 0.2);
        }

        .subcategory-card.selected::after {
            content: '✓';
            position: absolute;
            top: 8px;
            right: 8px;
            color: #667eea;
            font-weight: bold;
            font-size: 14px;
        }

        .subcategory-title {
            font-size: 14px;
            font-weight: 600;
            color: #374151;
            margin-bottom: 4px;
            padding-right: 20px;
        }

        .subcategory-description {
            font-size: 12px;
            color: #6b7280;
            line-height: 1.3;
        }


        .simple-creator-input {
            border: 2px solid #e1e5e9;
            border-radius: 8px;
            padding: 12px;
            background: #fafafa;
            cursor: pointer;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .simple-creator-input:hover {
            border-color: #667eea;
            background: white;
        }

        /* Confirmation Step Styles - Now matches main container */
        #confirmationStep {
            display: none; /* Hidden by default */
            padding: 20px 0;
            box-sizing: border-box;
        }

        #confirmationStep .confirmation-container {
            background: white;
            border-radius: 16px;
            width: 100%;
            max-width: 500px;
            box-shadow: 0 20px 40px rgba(0,0,0,0.1);
            display: flex;
            flex-direction: column;
            position: relative;
            margin: 0 auto;
            margin-bottom: 40px;
        }

        .confirmation-header {
            background: white;
            padding: 16px 32px 12px;
            text-align: center;
            border-bottom: 1px solid #f1f5f9;
            border-radius: 16px 16px 0 0;
        }

        .confirmation-header h2 {
            color: #333;
            font-size: 20px;
            margin-bottom: 4px;
        }

        .confirmation-header p {
            color: #666;
            font-size: 14px;
            margin: 0;
        }

        #confirmationStep .scrollable-content {
            padding: 16px 32px;
        }

        #confirmationStep .fixed-bottom {
            padding: 16px 32px 32px;
            background: white;
            border-top: 1px solid #f1f5f9;
            border-radius: 0 0 16px 16px;
        }

        .confirmation-details {
            background: #f8fafc;
            border-radius: 12px;
            padding: 20px;
            margin: 20px 0;
        }

        .confirmation-item {
            display: flex;
            justify-content: space-between;
            align-items: flex-start;
            padding: 12px 0;
            border-bottom: 1px solid #e2e8f0;
        }

        .confirmation-item:last-child {
            border-bottom: none;
        }

        .confirmation-label {
            font-weight: 600;
            color: #374151;
            min-width: 120px;
            margin-right: 16px;
        }

        .confirmation-value {
            color: #1f2937;
            flex: 1;
            text-align: right;
        }

        .creator-types-list {
            display: flex;
            flex-wrap: wrap;
            gap: 6px;
            justify-content: flex-end;
        }

        .creator-type-chip {
            background: #e0e7ff;
            color: #3730a3;
            padding: 4px 8px;
            border-radius: 12px;
            font-size: 12px;
            font-weight: 500;
        }

        /* Mobile/iPad specific styles for confirmation step */
        @media screen and (max-width: 768px) {
            #confirmationStep {
                padding: 10px 0;
            }
            
            #confirmationStep .confirmation-container {
                margin: 10px auto;
                max-width: none;
            }
            
            #confirmationStep .confirmation-header {
                padding: 12px 20px 8px;
            }
            
            #confirmationStep .scrollable-content {
                padding: 12px 20px;
            }
            
            #confirmationStep .fixed-bottom {
                padding: 12px 20px 20px;
            }
        }

        /* Mobile centering for confirmation step */
        @media (max-width: 480px) {
            #confirmationStep .confirmation-container {
                margin: 10px auto;
                padding: 24px;
            }
        }

        /* Offline Viewer Styles - Same pattern as confirmation step */
        #offlineViewer {
            background: rgba(0, 0, 0, 0.1);
            padding: 20px;
            box-sizing: border-box;
            padding-top: 40px;
        }

        #offlineViewer .offline-container {
            background: white;
            border-radius: 16px;
            width: 100%;
            max-width: 500px;
            box-shadow: 0 20px 40px rgba(0,0,0,0.1);
            display: flex;
            flex-direction: column;
            position: relative;
            margin: 0 auto;
            margin-bottom: 40px;
        }

        #offlineViewer .logo {
            background: white;
            text-align: center;
            padding: 16px 32px 12px;
            border-bottom: 1px solid #f1f5f9;
            border-radius: 16px 16px 0 0;
            margin-bottom: 0;
        }

        #offlineViewer .scrollable-content {
            padding: 16px 32px;
        }

        #offlineViewer .fixed-bottom {
            padding: 16px 32px 32px;
            background: white;
            border-top: 1px solid #f1f5f9;
            border-radius: 0 0 16px 16px;
        }

        /* Mobile/iPad specific styles for offline viewer */
        @media screen and (max-width: 768px) {
            #offlineViewer {
                padding: 10px;
            }
            
            #offlineViewer .logo {
                padding: 12px 20px 8px;
            }
            
            #offlineViewer .scrollable-content {
                padding: 12px 20px;
            }
            
            #offlineViewer .fixed-bottom {
                padding: 12px 20px 20px;
            }
        }

        /* Ensure offline viewer works on short screens */
        @media screen and (max-height: 600px) {
            #offlineViewer {
                padding: 5px;
            }
            
            #offlineViewer .logo {
                padding: 8px 20px 6px;
            }
            
            #offlineViewer .fixed-bottom {
                padding: 8px 20px 16px;
            }
        }

        /* Offline Submissions Styles */
        .offline-submission {
            background: #fef3c7;
            border: 1px solid #f59e0b;
            border-radius: 8px;
            padding: 16px;
            margin-bottom: 12px;
        }

        .offline-submission-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 8px;
        }

        .offline-submission-name {
            font-weight: 600;
            color: #92400e;
        }

        .offline-submission-time {
            font-size: 12px;
            color: #78350f;
        }

        .offline-submission-details {
            font-size: 14px;
            color: #92400e;
        }

        .no-offline-submissions {
            text-align: center;
            color: #64748b;
            padding: 40px 20px;
            font-style: italic;
        }

        /* View Toggle */
        .view-toggle {
            text-align: center;
            margin: 0 32px 16px;
        }

        .view-toggle button {
            background: none;
            border: 1px solid #d1d5db;
            color: #374151;
            padding: 8px 16px;
            margin: 0 4px;
            border-radius: 6px;
            cursor: pointer;
            font-size: 14px;
        }

        .view-toggle button.active {
            background: #667eea;
            color: white;
            border-color: #667eea;
        }

        /* Simplified container centering */
        body {
            display: flex;
            flex-direction: column;
            align-items: center;
        }

        @media (max-width: 480px) {
            body {
                padding: 10px;
            }
            
            .container {
                margin: 10px auto;
                max-width: none;
                width: 100%;
            }
        }
