-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
4383 lines (4089 loc) · 223 KB
/
Copy pathindex.html
File metadata and controls
4383 lines (4089 loc) · 223 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Azure Cloud Adoption Helper</title>
<style>
:root {
--bg: #0d1117;
--surface: #161b22;
--surface2: #21262d;
--border: #30363d;
--azure: #0078d4;
--azure-light: #50e6ff;
--accent: #58a6ff;
--green: #3fb950;
--yellow: #d29922;
--red: #f85149;
--text: #e6edf3;
--text2: #8b949e;
--text3: #6e7681;
--radius: 8px;
--font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
--mono: "Cascadia Code", "Fira Code", Consolas, monospace;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; }
body { background: var(--bg); color: var(--text); font-family: var(--font); min-height: 100vh; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
input, select, textarea {
background: var(--surface2); border: 1px solid var(--border); border-radius: 6px;
color: var(--text); font-family: var(--font); font-size: 13px; padding: 7px 10px;
outline: none; width: 100%; transition: border-color .15s;
}
input:focus, select:focus, textarea:focus { border-color: var(--azure); }
input.valid { border-color: var(--green); }
input.invalid { border-color: var(--red); }
label { color: var(--text2); font-size: 12px; font-weight: 500; display: block; margin-bottom: 4px; text-transform: uppercase; letter-spacing: .4px; }
button {
cursor: pointer; font-family: var(--font); font-size: 13px; font-weight: 500;
border-radius: 6px; border: 1px solid transparent; padding: 7px 14px; transition: all .15s;
}
.btn-primary { background: var(--azure); color: #fff; border-color: var(--azure); }
.btn-primary:hover { background: #106ebe; }
.btn-secondary { background: var(--surface2); color: var(--text); border-color: var(--border); }
.btn-secondary:hover { background: var(--surface); border-color: var(--accent); color: var(--accent); }
.btn-ghost { background: transparent; color: var(--text2); border-color: transparent; }
.btn-ghost:hover { color: var(--text); background: var(--surface2); }
.btn-danger { background: transparent; color: var(--red); border-color: var(--red); }
.btn-danger:hover { background: var(--red); color: #fff; }
.btn-sm { padding: 4px 10px; font-size: 12px; }
.btn-xs { padding: 2px 8px; font-size: 11px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; }
.card-title { font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
.grid-4 { display: grid; grid-template-columns: 1fr 1fr 1fr 1fr; gap: 12px; }
.flex { display: flex; gap: 8px; }
.flex-col { display: flex; flex-direction: column; gap: 8px; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.gap-4 { gap: 4px; }
.gap-16 { gap: 16px; }
.mt-8 { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mb-4 { margin-bottom: 4px; }
.mb-8 { margin-bottom: 8px; }
.w-full { width: 100%; }
.text-sm { font-size: 12px; }
.text-xs { font-size: 11px; }
.text-mono { font-family: var(--mono); }
.text-azure { color: var(--azure-light); }
.text-green { color: var(--green); }
.text-yellow { color: var(--yellow); }
.text-red { color: var(--red); }
.text-muted { color: var(--text2); }
.text-right { text-align: right; }
.text-center { text-align: center; }
.bold { font-weight: 600; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Header */
#header {
background: var(--surface); border-bottom: 1px solid var(--border);
padding: 0 24px; position: sticky; top: 0; z-index: 100;
}
.header-inner { max-width: 1400px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; height: 56px; }
.logo { display: flex; align-items: center; gap: 10px; }
.logo-icon { width: 32px; height: 32px; background: var(--azure); border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 16px; }
.logo-text { font-size: 15px; font-weight: 700; color: var(--text); }
.logo-sub { font-size: 11px; color: var(--text2); margin-top: 1px; }
.header-badges { display: flex; gap: 6px; }
.badge {
font-size: 10px; font-weight: 600; padding: 2px 8px; border-radius: 20px;
letter-spacing: .3px; text-transform: uppercase;
}
.badge-blue { background: rgba(0,120,212,.15); color: var(--azure-light); border: 1px solid rgba(0,120,212,.3); }
.badge-green { background: rgba(63,185,80,.1); color: var(--green); border: 1px solid rgba(63,185,80,.2); }
/* Tabs */
#tab-nav {
background: var(--surface); border-bottom: 1px solid var(--border);
padding: 0 24px; overflow-x: auto; scrollbar-width: none;
}
#tab-nav::-webkit-scrollbar { display: none; }
.tab-inner { max-width: 1400px; margin: 0 auto; display: flex; gap: 2px; }
.tab-btn {
padding: 12px 16px; font-size: 13px; font-weight: 500; color: var(--text2);
background: transparent; border: none; border-bottom: 2px solid transparent;
cursor: pointer; white-space: nowrap; display: flex; align-items: center; gap: 6px;
transition: color .15s, border-color .15s; position: relative; top: 1px;
}
.tab-btn:hover { color: var(--text); }
.tab-btn.active { color: var(--azure-light); border-bottom-color: var(--azure); }
.tab-icon { font-size: 14px; }
/* Main */
#main { max-width: 1400px; margin: 0 auto; padding: 24px; }
.tab-panel { display: none; }
.tab-panel.active { display: block; }
/* Section headers */
.section-header { margin-bottom: 20px; }
.section-title { font-size: 18px; font-weight: 700; color: var(--text); }
.section-desc { font-size: 13px; color: var(--text2); margin-top: 4px; }
.section-actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
/* Tables */
table { width: 100%; border-collapse: collapse; font-size: 13px; }
thead tr { background: var(--surface2); }
th { padding: 8px 12px; text-align: left; font-weight: 600; color: var(--text2); font-size: 11px; text-transform: uppercase; letter-spacing: .4px; border-bottom: 1px solid var(--border); }
td { padding: 8px 12px; border-bottom: 1px solid rgba(48,54,61,.5); vertical-align: middle; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: rgba(255,255,255,.02); }
.table-wrap { overflow-x: auto; border-radius: var(--radius); border: 1px solid var(--border); }
/* Form group */
.form-group { margin-bottom: 12px; }
.form-row { display: grid; gap: 12px; }
.form-row-2 { grid-template-columns: 1fr 1fr; }
.form-row-3 { grid-template-columns: 1fr 1fr 1fr; }
.form-row-4 { grid-template-columns: 1fr 1fr 1fr 1fr; }
.field-hint { font-size: 11px; color: var(--text3); margin-top: 3px; }
.field-error { font-size: 11px; color: var(--red); margin-top: 3px; display: none; }
.field-error.show { display: block; }
/* Generated name display */
.name-display {
background: var(--surface2); border: 1px solid var(--border); border-radius: 6px;
padding: 12px 14px; font-family: var(--mono); font-size: 14px; color: var(--azure-light);
letter-spacing: .5px; display: flex; align-items: center; justify-content: space-between;
min-height: 44px; word-break: break-all;
}
.name-display.valid-name { border-color: var(--green); }
.name-display.invalid-name { border-color: var(--red); color: var(--red); }
/* Validation badge */
.val-badge {
display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 600;
padding: 3px 8px; border-radius: 20px;
}
.val-ok { background: rgba(63,185,80,.1); color: var(--green); border: 1px solid rgba(63,185,80,.2); }
.val-warn { background: rgba(210,153,34,.1); color: var(--yellow); border: 1px solid rgba(210,153,34,.2); }
.val-err { background: rgba(248,81,73,.1); color: var(--red); border: 1px solid rgba(248,81,73,.2); }
/* CIDR visual */
.cidr-bar-wrap { margin-top: 8px; background: var(--surface2); border-radius: 4px; height: 8px; overflow: hidden; }
.cidr-bar { height: 100%; background: var(--azure); border-radius: 4px; transition: width .3s; }
/* WAF radar */
#waf-radar-wrap { display: flex; justify-content: center; margin: 20px 0; }
/* Progress ring */
.pillar-score { font-size: 28px; font-weight: 700; color: var(--azure-light); }
.pillar-label { font-size: 11px; color: var(--text2); text-transform: uppercase; letter-spacing: .4px; }
/* Checklist */
.check-item {
display: flex; align-items: flex-start; gap: 10px; padding: 8px 0;
border-bottom: 1px solid rgba(48,54,61,.4);
}
.check-item:last-child { border-bottom: none; }
.check-item input[type=checkbox] { width: 16px; height: 16px; min-width: 16px; margin-top: 1px; accent-color: var(--azure); cursor: pointer; }
.check-text { flex: 1; }
.check-q { font-size: 13px; color: var(--text); }
.check-rec { font-size: 11px; color: var(--text2); margin-top: 3px; display: none; }
.check-item.unchecked .check-rec { display: block; }
/* Tag chips */
.tag-chip {
display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px;
background: rgba(0,120,212,.1); border: 1px solid rgba(0,120,212,.25);
border-radius: 20px; font-size: 11px; color: var(--azure-light); cursor: default;
}
.tag-chip .remove { cursor: pointer; color: var(--text3); font-size: 13px; line-height: 1; }
.tag-chip .remove:hover { color: var(--red); }
/* Policy cards */
.policy-card {
background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
padding: 12px; cursor: pointer; transition: border-color .15s;
}
.policy-card:hover { border-color: var(--azure); }
.policy-card.selected { border-color: var(--azure); background: rgba(0,120,212,.05); }
.policy-card .policy-effect {
font-size: 10px; font-weight: 700; padding: 2px 6px; border-radius: 4px;
text-transform: uppercase; letter-spacing: .3px;
}
.effect-deny { background: rgba(248,81,73,.15); color: var(--red); }
.effect-audit { background: rgba(210,153,34,.15); color: var(--yellow); }
.effect-modify { background: rgba(63,185,80,.15); color: var(--green); }
.effect-dine { background: rgba(88,166,255,.15); color: var(--accent); }
/* Landing zone tree */
.mg-tree { padding-left: 0; }
.mg-node { list-style: none; margin: 4px 0; }
.mg-node-content {
display: flex; align-items: center; gap: 8px; padding: 6px 10px;
background: var(--surface); border: 1px solid var(--border); border-radius: 6px;
font-size: 13px; cursor: pointer; transition: border-color .15s;
}
.mg-node-content:hover { border-color: var(--azure); }
.mg-children { padding-left: 24px; border-left: 1px solid var(--border); margin-left: 12px; }
.mg-icon { font-size: 14px; }
.sub-pill {
font-size: 10px; padding: 1px 6px; border-radius: 10px;
background: rgba(88,166,255,.1); color: var(--accent); border: 1px solid rgba(88,166,255,.2);
}
/* Cost bar chart */
.cost-bar-item { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.cost-bar-label { width: 130px; font-size: 12px; color: var(--text2); flex-shrink: 0; text-align: right; }
.cost-bar-track { flex: 1; background: var(--surface2); border-radius: 4px; height: 14px; overflow: hidden; }
.cost-bar-fill { height: 100%; border-radius: 4px; transition: width .4s; }
.cost-bar-val { width: 70px; font-size: 12px; font-family: var(--mono); color: var(--text); flex-shrink: 0; }
/* Toast */
#toast-container { position: fixed; bottom: 24px; right: 24px; display: flex; flex-direction: column; gap: 8px; z-index: 9999; }
.toast {
background: var(--surface2); border: 1px solid var(--border); border-radius: 8px;
padding: 10px 16px; font-size: 13px; display: flex; align-items: center; gap: 8px;
box-shadow: 0 4px 20px rgba(0,0,0,.4); animation: slideIn .2s ease; min-width: 200px;
}
.toast.success { border-color: var(--green); color: var(--green); }
.toast.error { border-color: var(--red); color: var(--red); }
.toast.info { border-color: var(--azure); color: var(--azure-light); }
@keyframes slideIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
/* Code block */
.code-block {
background: #010409; border: 1px solid var(--border); border-radius: 6px;
padding: 12px; font-family: var(--mono); font-size: 12px; color: #e6edf3;
overflow-x: auto; white-space: pre; line-height: 1.6;
}
/* Collapsible */
.collapsible-header {
display: flex; align-items: center; justify-content: space-between;
cursor: pointer; padding: 10px 0; user-select: none;
}
.collapsible-header:hover .coll-title { color: var(--accent); }
.coll-title { font-size: 13px; font-weight: 600; color: var(--text); }
.coll-arrow { color: var(--text3); transition: transform .2s; font-size: 12px; }
.collapsible-header.open .coll-arrow { transform: rotate(90deg); }
.collapsible-body { display: none; padding-bottom: 8px; }
.collapsible-body.open { display: block; }
/* Divider */
.divider { border: none; border-top: 1px solid var(--border); margin: 16px 0; }
/* Tooltip */
[data-tip] { position: relative; }
[data-tip]:hover::after {
content: attr(data-tip); position: absolute; bottom: calc(100% + 4px); left: 50%;
transform: translateX(-50%); background: #1c2128; border: 1px solid var(--border);
color: var(--text); font-size: 11px; padding: 4px 8px; border-radius: 4px;
white-space: nowrap; z-index: 1000; pointer-events: none;
}
/* Scrollable container */
.scroll-y { overflow-y: auto; }
.max-h-400 { max-height: 400px; }
.max-h-600 { max-height: 600px; }
/* Sidebar layout */
.sidebar-layout { display: grid; grid-template-columns: 300px 1fr; gap: 16px; }
.sidebar-layout-wide { display: grid; grid-template-columns: 380px 1fr; gap: 16px; }
/* Number input */
input[type=number] { -moz-appearance: textfield; }
input[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer-spin-button { -webkit-appearance: none; }
/* Range */
input[type=range] { width: 100%; accent-color: var(--azure); }
/* Toggle */
.toggle { display: flex; align-items: center; gap: 8px; cursor: pointer; }
.toggle input[type=checkbox] { width: 36px; height: 20px; appearance: none; background: var(--surface2); border: 1px solid var(--border); border-radius: 10px; position: relative; cursor: pointer; transition: background .2s; }
.toggle input[type=checkbox]:checked { background: var(--azure); border-color: var(--azure); }
.toggle input[type=checkbox]::after { content: ""; position: absolute; width: 14px; height: 14px; background: #fff; border-radius: 50%; top: 2px; left: 2px; transition: left .2s; }
.toggle input[type=checkbox]:checked::after { left: 18px; }
.toggle-label { font-size: 13px; color: var(--text); }
/* Print styles */
@media print {
#header, #tab-nav, .section-actions, button, .tab-panel:not(.active) { display: none !important; }
body { background: #fff; color: #000; }
.card { background: #f9f9f9; border: 1px solid #ddd; }
.code-block { background: #f5f5f5; color: #000; }
* { color: inherit !important; }
}
@media (max-width: 900px) {
.sidebar-layout, .sidebar-layout-wide { grid-template-columns: 1fr; }
.form-row-3, .form-row-4 { grid-template-columns: 1fr 1fr; }
.grid-3, .grid-4 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
#main { padding: 16px; }
.form-row-2, .form-row-3, .form-row-4 { grid-template-columns: 1fr; }
.grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
.header-badges { display: none; }
}
/* ===================== DIAGRAM STYLES ===================== */
#dgm-canvas-wrap {
position: relative; background: #0a0e14;
border: 1px solid var(--border); border-radius: var(--radius);
overflow: hidden; flex: 1; min-height: 600px; cursor: default;
background-image: radial-gradient(circle, #1e2630 1px, transparent 1px);
background-size: 24px 24px;
}
#dgm-canvas { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
.dgm-node {
position: absolute; display: flex; flex-direction: column; align-items: center;
gap: 5px; cursor: grab; user-select: none; z-index: 10;
padding: 10px 12px; border-radius: 10px; min-width: 90px; max-width: 120px;
background: var(--surface); border: 1.5px solid var(--border);
box-shadow: 0 2px 12px rgba(0,0,0,.5); transition: border-color .15s, box-shadow .15s;
text-align: center;
}
.dgm-node:active { cursor: grabbing; }
.dgm-node.selected { border-color: var(--azure); box-shadow: 0 0 0 2px rgba(0,120,212,.3), 0 2px 12px rgba(0,0,0,.5); z-index: 20; }
.dgm-node.connecting { border-color: var(--azure-light); }
.dgm-node-icon { font-size: 26px; line-height: 1; }
.dgm-node-label {
font-size: 11px; font-weight: 600; color: var(--text); line-height: 1.2;
word-break: break-word; text-align: center; max-width: 100%;
}
.dgm-node-sub { font-size: 10px; color: var(--text2); line-height: 1.2; }
.dgm-node-badge {
font-size: 9px; padding: 1px 5px; border-radius: 8px; font-weight: 700;
background: rgba(0,120,212,.15); color: var(--azure-light); border: 1px solid rgba(0,120,212,.2);
}
.dgm-conn-port {
position: absolute; width: 10px; height: 10px; border-radius: 50%;
background: var(--azure); border: 2px solid var(--bg); cursor: crosshair;
opacity: 0; transition: opacity .15s; z-index: 30;
}
.dgm-node:hover .dgm-conn-port { opacity: 1; }
.dgm-conn-port.top { top: -5px; left: 50%; transform: translateX(-50%); }
.dgm-conn-port.bottom { bottom: -5px; left: 50%; transform: translateX(-50%); }
.dgm-conn-port.left { left: -5px; top: 50%; transform: translateY(-50%); }
.dgm-conn-port.right { right: -5px; top: 50%; transform: translateY(-50%); }
/* Toolbar */
#dgm-toolbar {
display: flex; align-items: center; gap: 6px; padding: 8px 12px;
background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
flex-wrap: wrap;
}
.dgm-tool-sep { width: 1px; height: 20px; background: var(--border); margin: 0 4px; }
.dgm-tool-btn {
padding: 5px 10px; border-radius: 6px; font-size: 12px; font-weight: 500;
background: var(--surface2); border: 1px solid var(--border); color: var(--text2);
cursor: pointer; display: flex; align-items: center; gap: 5px; transition: all .15s;
white-space: nowrap;
}
.dgm-tool-btn:hover { border-color: var(--azure); color: var(--text); }
.dgm-tool-btn.active { background: rgba(0,120,212,.15); border-color: var(--azure); color: var(--azure-light); }
.dgm-mode-label { font-size: 11px; color: var(--text3); padding: 0 4px; }
/* Component palette */
#dgm-palette {
width: 220px; flex-shrink: 0; display: flex; flex-direction: column; gap: 4px;
max-height: 700px; overflow-y: auto;
}
.dgm-palette-section { font-size: 10px; font-weight: 700; color: var(--text3); text-transform: uppercase; letter-spacing: .5px; padding: 6px 0 2px; }
.dgm-palette-item {
display: flex; align-items: center; gap: 8px; padding: 7px 10px;
background: var(--surface); border: 1px solid var(--border); border-radius: 6px;
cursor: grab; font-size: 12px; color: var(--text); transition: border-color .15s;
user-select: none;
}
.dgm-palette-item:hover { border-color: var(--azure); color: var(--azure-light); }
.dgm-palette-item .icon { font-size: 18px; flex-shrink: 0; }
/* Sidebar properties */
#dgm-props {
width: 220px; flex-shrink: 0; display: flex; flex-direction: column; gap: 8px;
}
/* Connection label on SVG */
.dgm-conn-label { font-size: 10px; fill: var(--text2); font-family: var(--font); }
/* Upload zone */
#dgm-upload-zone {
border: 2px dashed var(--border); border-radius: var(--radius); padding: 20px;
text-align: center; cursor: pointer; transition: border-color .15s, background .15s;
color: var(--text2); font-size: 13px;
}
#dgm-upload-zone:hover, #dgm-upload-zone.drag-over { border-color: var(--azure); background: rgba(0,120,212,.05); color: var(--azure-light); }
/* Mini-map */
#dgm-minimap {
position: absolute; bottom: 12px; right: 12px; width: 140px; height: 90px;
background: rgba(13,17,23,.85); border: 1px solid var(--border); border-radius: 6px;
overflow: hidden; z-index: 50; backdrop-filter: blur(4px);
}
#dgm-minimap-canvas { width: 100%; height: 100%; }
/* Zone/group node */
.dgm-zone {
position: absolute; border: 2px dashed; border-radius: 12px;
z-index: 1; pointer-events: none; display: flex; align-items: flex-start; padding: 8px 12px;
}
.dgm-zone-label { font-size: 11px; font-weight: 700; opacity: .7; }
</style>
</head>
<body>
<div id="header">
<div class="header-inner">
<div class="logo">
<div class="logo-icon">☁️</div>
<div>
<div class="logo-text">Azure Cloud Adoption Helper</div>
<div class="logo-sub">Naming · IP Planning · Governance · Well-Architected</div>
</div>
</div>
<div class="header-badges">
<span class="badge badge-blue">CAF Aligned</span>
<span class="badge badge-green">WAF v2</span>
<span class="badge badge-blue">Offline Ready</span>
</div>
</div>
</div>
<div id="tab-nav">
<div class="tab-inner">
<button class="tab-btn active" onclick="switchTab('naming')" id="tab-btn-naming">
<span class="tab-icon">🏷️</span> Naming Convention
</button>
<button class="tab-btn" onclick="switchTab('cidr')" id="tab-btn-cidr">
<span class="tab-icon">🌐</span> IP / CIDR Planner
</button>
<button class="tab-btn" onclick="switchTab('tagging')" id="tab-btn-tagging">
<span class="tab-icon">🔖</span> Tagging Strategy
</button>
<button class="tab-btn" onclick="switchTab('landingzone')" id="tab-btn-landingzone">
<span class="tab-icon">🏗️</span> Landing Zone
</button>
<button class="tab-btn" onclick="switchTab('waf')" id="tab-btn-waf">
<span class="tab-icon">✅</span> WAF Checklist
</button>
<button class="tab-btn" onclick="switchTab('cost')" id="tab-btn-cost">
<span class="tab-icon">💰</span> Cost Estimator
</button>
<button class="tab-btn" onclick="switchTab('policy')" id="tab-btn-policy">
<span class="tab-icon">🛡️</span> Policy Catalog
</button>
<button class="tab-btn" onclick="switchTab('diagram')" id="tab-btn-diagram">
<span class="tab-icon">🗺️</span> Architecture Diagram
</button>
</div>
</div>
<div id="main">
<div class="tab-panel active" id="tab-naming">
<div class="section-header">
<div class="section-title">🏷️ Naming Convention Generator</div>
<div class="section-desc">Generate Azure resource names following the Cloud Adoption Framework (CAF) naming pattern: <span class="text-mono text-azure">{prefix}-{workload}-{env}-{region}-{instance}</span>. Enforces per-resource rules for length, characters, and scope.</div>
<div class="section-actions">
<button class="btn-secondary btn-sm" onclick="exportNaming('csv')">⬇ Export CSV</button>
<button class="btn-secondary btn-sm" onclick="exportNaming('json')">⬇ Export JSON</button>
<button class="btn-secondary btn-sm" onclick="printPage()">🖨 Print View</button>
<button class="btn-ghost btn-sm" onclick="clearNaming()">🗑 Clear</button>
</div>
</div>
<div class="sidebar-layout">
<!-- LEFT: Form -->
<div class="flex-col">
<div class="card">
<div class="card-title">⚙️ Configuration</div>
<div class="form-group">
<label>Organisation / Company Prefix</label>
<input type="text" id="n-prefix" maxlength="6" placeholder="e.g. unify" oninput="generateName()" />
<div class="field-hint">2–6 chars, lowercase letters only</div>
</div>
<div class="form-group">
<label>Workload / Application Name</label>
<input type="text" id="n-workload" maxlength="20" placeholder="e.g. financeapp" oninput="generateName()" />
<div class="field-hint">Short, lowercase, no spaces</div>
</div>
<div class="form-row form-row-2">
<div class="form-group">
<label>Environment</label>
<select id="n-env" onchange="generateName()">
<option value="prod">prod</option>
<option value="stg">stg (Staging)</option>
<option value="test">test</option>
<option value="dev">dev</option>
<option value="sbx">sbx (Sandbox)</option>
</select>
</div>
<div class="form-group">
<label>Azure Region</label>
<select id="n-region" onchange="generateName()">
<option value="uan">UAE North (uan)</option>
<option value="uac">UAE Central (uac)</option>
<option value="eus">East US (eus)</option>
<option value="eus2">East US 2 (eus2)</option>
<option value="wus">West US (wus)</option>
<option value="wus2">West US 2 (wus2)</option>
<option value="cus">Central US (cus)</option>
<option value="neu">North Europe (neu)</option>
<option value="weu">West Europe (weu)</option>
<option value="uks">UK South (uks)</option>
<option value="ukw">UK West (ukw)</option>
<option value="frc">France Central (frc)</option>
<option value="gwc">Germany WC (gwc)</option>
<option value="swn">Switzerland N (swn)</option>
<option value="noe">Norway East (noe)</option>
<option value="swc">Sweden Central (swc)</option>
<option value="san">South Africa N (san)</option>
<option value="ea">East Asia (ea)</option>
<option value="sea">SE Asia (sea)</option>
<option value="aue">Australia East (aue)</option>
<option value="jpe">Japan East (jpe)</option>
<option value="krc">Korea Central (krc)</option>
<option value="inc">India Central (inc)</option>
<option value="cac">Canada Central (cac)</option>
<option value="brs">Brazil South (brs)</option>
</select>
</div>
</div>
<div class="form-row form-row-2">
<div class="form-group">
<label>Instance / Sequence</label>
<input type="text" id="n-instance" value="001" maxlength="5" placeholder="001" oninput="generateName()" />
</div>
<div class="form-group">
<label>Resource Type</label>
<select id="n-restype" onchange="generateName()" style="font-size:12px">
<optgroup id="n-restype-opts"></optgroup>
</select>
</div>
</div>
</div>
<div class="card">
<div class="card-title">📋 Generated Name</div>
<div class="name-display" id="n-output">—</div>
<div class="flex items-center justify-between mt-8">
<div id="n-validation" class="text-sm text-muted"></div>
<button class="btn-secondary btn-sm" onclick="copyName()" id="n-copy-btn">📋 Copy</button>
</div>
<div id="n-info" class="mt-8 text-sm text-muted"></div>
</div>
<div class="card">
<div class="card-title">📏 Resource Rules</div>
<div id="n-rules" class="text-sm"></div>
</div>
</div>
<!-- RIGHT: Bulk generator + saved names -->
<div class="flex-col">
<div class="card">
<div class="card-title">🗂 Bulk Landing Zone Name Generator</div>
<div class="text-sm text-muted mb-8">Select multiple resource types to generate a complete naming sheet for a landing zone deployment.</div>
<div id="n-bulk-list" class="flex-col gap-4 max-h-400 scroll-y mb-8"></div>
<div class="flex gap-4 flex-wrap">
<button class="btn-primary btn-sm" onclick="generateBulk()">⚡ Generate All</button>
<button class="btn-ghost btn-sm" onclick="selectAllBulk()">☑ Select All</button>
<button class="btn-ghost btn-sm" onclick="deselectAllBulk()">☐ Deselect All</button>
</div>
</div>
<div class="card">
<div class="card-title">💾 Saved Names <span class="text-muted text-xs" id="saved-count">(0)</span></div>
<div id="saved-names-list" class="flex-col gap-4 max-h-400 scroll-y"></div>
<div class="mt-8 flex gap-4">
<button class="btn-secondary btn-sm" onclick="saveCurrentName()">+ Save Current</button>
<button class="btn-ghost btn-sm" onclick="clearSavedNames()">🗑 Clear All</button>
</div>
</div>
<div class="card">
<div class="card-title">📖 CAF Abbreviation Reference</div>
<input type="text" placeholder="Search resource types..." oninput="filterRefTable(this.value)" style="margin-bottom:10px" />
<div class="table-wrap max-h-400 scroll-y">
<table id="ref-table">
<thead><tr><th>Resource Type</th><th>Abbrev.</th><th>Max Length</th><th>Scope</th></tr></thead>
<tbody id="ref-tbody"></tbody>
</table>
</div>
</div>
</div>
</div>
</div>
<div class="tab-panel" id="tab-cidr">
<div class="section-header">
<div class="section-title">🌐 IP Address & CIDR Planner</div>
<div class="section-desc">Design your Azure VNet address spaces with subnet planning, overlap detection, and hub-spoke topology presets. Based on CAF IP addressing guidelines.</div>
<div class="section-actions">
<button class="btn-secondary btn-sm" onclick="exportCIDR('json')">⬇ Export JSON</button>
<button class="btn-secondary btn-sm" onclick="exportCIDR('csv')">⬇ Export CSV</button>
<button class="btn-ghost btn-sm" onclick="clearCIDR()">🗑 Clear All</button>
</div>
</div>
<div class="grid-2 mb-8" style="gap:8px">
<button class="btn-secondary btn-sm" onclick="loadPreset('small')">🔹 Small Hub-Spoke Preset</button>
<button class="btn-secondary btn-sm" onclick="loadPreset('medium')">🔸 Medium Hub-Spoke Preset</button>
<button class="btn-secondary btn-sm" onclick="loadPreset('large')">🔶 Large Enterprise Preset</button>
<button class="btn-secondary btn-sm" onclick="loadPreset('sandbox')">🧪 Sandbox Preset</button>
</div>
<div class="sidebar-layout-wide">
<!-- LEFT: VNet + Subnet form -->
<div class="flex-col">
<div class="card">
<div class="card-title">➕ Add Virtual Network</div>
<div class="form-group">
<label>VNet Name</label>
<input type="text" id="cidr-vnet-name" placeholder="e.g. vnet-hub-prod-uan-001" />
</div>
<div class="form-row form-row-2">
<div class="form-group">
<label>Address Space (CIDR)</label>
<input type="text" id="cidr-vnet-cidr" placeholder="10.0.0.0/16" oninput="validateCIDRInput(this)" />
</div>
<div class="form-group">
<label>Role</label>
<select id="cidr-vnet-role">
<option value="hub">Hub</option>
<option value="spoke">Spoke</option>
<option value="standalone">Standalone</option>
<option value="onprem">On-Premises</option>
</select>
</div>
</div>
<div class="form-group">
<label>Azure Region</label>
<select id="cidr-vnet-region">
<option value="UAE North">UAE North</option>
<option value="UAE Central">UAE Central</option>
<option value="East US">East US</option>
<option value="West Europe">West Europe</option>
<option value="UK South">UK South</option>
<option value="Australia East">Australia East</option>
<option value="Southeast Asia">Southeast Asia</option>
</select>
</div>
<button class="btn-primary btn-sm w-full" onclick="addVNet()">+ Add VNet</button>
</div>
<div class="card" id="cidr-subnet-form-card" style="display:none">
<div class="card-title">🔀 Add Subnet to: <span id="cidr-active-vnet-label" class="text-azure"></span></div>
<div class="form-group">
<label>Subnet Name</label>
<input type="text" id="cidr-snet-name" placeholder="e.g. snet-app-001" />
</div>
<div class="form-row form-row-2">
<div class="form-group">
<label>Subnet CIDR</label>
<input type="text" id="cidr-snet-cidr" placeholder="10.0.1.0/24" oninput="validateCIDRInput(this)" />
</div>
<div class="form-group">
<label>Purpose</label>
<select id="cidr-snet-purpose">
<option value="GatewaySubnet">GatewaySubnet (VPN/ER)</option>
<option value="AzureFirewallSubnet">AzureFirewallSubnet</option>
<option value="AzureBastionSubnet">AzureBastionSubnet</option>
<option value="Workload">Workload</option>
<option value="Management">Management</option>
<option value="SharedServices">Shared Services</option>
<option value="Database">Database</option>
<option value="Web">Web / Frontend</option>
<option value="App">Application Layer</option>
<option value="PrivateEndpoints">Private Endpoints</option>
</select>
</div>
</div>
<div class="form-row form-row-2">
<div class="toggle form-group" style="margin-top:4px">
<input type="checkbox" id="cidr-snet-nsg" checked />
<span class="toggle-label">NSG Required</span>
</div>
<div class="toggle form-group" style="margin-top:4px">
<input type="checkbox" id="cidr-snet-rt" />
<span class="toggle-label">Route Table</span>
</div>
</div>
<div id="cidr-snet-preview" class="mt-8"></div>
<button class="btn-primary btn-sm w-full mt-8" onclick="addSubnet()">+ Add Subnet</button>
</div>
<!-- Overlap checker -->
<div class="card">
<div class="card-title">⚠️ Overlap Detector</div>
<div id="cidr-overlap-result" class="text-sm text-muted">Add VNets to check for overlapping address spaces.</div>
</div>
<!-- Quick calculator -->
<div class="card">
<div class="card-title">🧮 Quick CIDR Calculator</div>
<div class="form-group">
<label>CIDR Block</label>
<input type="text" id="cidr-calc-input" placeholder="10.0.0.0/24" oninput="calcCIDR()" />
</div>
<div id="cidr-calc-result" class="text-sm flex-col gap-4"></div>
</div>
</div>
<!-- RIGHT: VNet list and visualization -->
<div class="flex-col">
<div class="card">
<div class="card-title">🗺 Network Topology</div>
<div id="cidr-vnet-list" class="flex-col gap-4">
<div class="text-sm text-muted text-center" style="padding:24px">No VNets added yet. Use the form on the left or load a preset.</div>
</div>
</div>
<div class="card">
<div class="card-title">📊 Address Space Summary</div>
<div class="table-wrap">
<table id="cidr-summary-table">
<thead><tr><th>VNet</th><th>CIDR</th><th>Role</th><th>Total IPs</th><th>Subnets</th><th>Used IPs</th><th>Free IPs</th></tr></thead>
<tbody id="cidr-summary-tbody"><tr><td colspan="7" class="text-muted text-center">No data</td></tr></tbody>
</table>
</div>
</div>
<div class="card">
<div class="card-title">📋 All Subnets</div>
<div class="table-wrap">
<table id="cidr-subnet-table">
<thead><tr><th>VNet</th><th>Subnet Name</th><th>CIDR</th><th>Purpose</th><th>Usable IPs</th><th>First IP</th><th>Last IP</th><th>NSG</th><th>RT</th></tr></thead>
<tbody id="cidr-subnet-tbody"><tr><td colspan="9" class="text-muted text-center">No subnets</td></tr></tbody>
</table>
</div>
</div>
<div class="card">
<div class="card-title">💡 CAF IP Planning Best Practices</div>
<div class="flex-col gap-4 text-sm">
<div>🔹 <strong>Hub VNet:</strong> Allocate at least /16 (65,536 IPs) to accommodate future growth.</div>
<div>🔹 <strong>Spoke VNets:</strong> Use /20–/22 for typical workloads. Avoid over-allocating.</div>
<div>🔹 <strong>GatewaySubnet:</strong> Minimum /27 for VPN. Use /26 or /25 for ExpressRoute with redundancy.</div>
<div>🔹 <strong>AzureFirewallSubnet:</strong> Must be exactly named "AzureFirewallSubnet", minimum /26.</div>
<div>🔹 <strong>AzureBastionSubnet:</strong> Must be exactly "AzureBastionSubnet", minimum /26.</div>
<div>🔹 <strong>Reserved IPs:</strong> Azure reserves 5 IPs per subnet (first 4 + last). A /24 gives 251 usable IPs.</div>
<div>🔹 <strong>Avoid:</strong> 172.16.0.0/12 and 192.168.0.0/16 if using ExpressRoute to avoid BGP conflicts.</div>
<div>🔹 <strong>Non-overlapping:</strong> Ensure no address overlap between on-premises, VNets, and peered networks.</div>
</div>
</div>
</div>
</div>
</div>
<div class="tab-panel" id="tab-tagging">
<div class="section-header">
<div class="section-title">🔖 Resource Tagging Strategy Builder</div>
<div class="section-desc">Design your Azure tagging taxonomy following CAF guidelines. Define required tags, allowed values, and generate Azure Policy enforcement snippets.</div>
<div class="section-actions">
<button class="btn-secondary btn-sm" onclick="exportTags('json')">⬇ Export JSON</button>
<button class="btn-secondary btn-sm" onclick="exportTags('csv')">⬇ Export CSV</button>
<button class="btn-secondary btn-sm" onclick="exportTags('policy')">⬇ Azure Policy JSON</button>
<button class="btn-secondary btn-sm" onclick="exportTags('markdown')">⬇ Markdown Table</button>
</div>
</div>
<div class="grid-2 mb-8" style="gap:8px">
<button class="btn-secondary btn-sm" onclick="loadTagTemplate('caf')">📋 Load CAF Minimum Tags</button>
<button class="btn-secondary btn-sm" onclick="loadTagTemplate('extended')">📋 Load Extended Enterprise Tags</button>
<button class="btn-secondary btn-sm" onclick="loadTagTemplate('finops')">💰 Load FinOps Tags</button>
<button class="btn-secondary btn-sm" onclick="loadTagTemplate('security')">🔒 Load Security Tags</button>
</div>
<div class="sidebar-layout">
<!-- LEFT: Add tag form -->
<div class="flex-col">
<div class="card">
<div class="card-title">➕ Add Tag</div>
<div class="form-group">
<label>Tag Key</label>
<input type="text" id="tag-key" placeholder="e.g. Environment" />
</div>
<div class="form-group">
<label>Category</label>
<select id="tag-category">
<option value="Governance">Governance</option>
<option value="Cost">Cost Management</option>
<option value="Security">Security & Compliance</option>
<option value="Operations">Operations</option>
<option value="Custom">Custom</option>
</select>
</div>
<div class="form-group">
<label>Description</label>
<input type="text" id="tag-desc" placeholder="What this tag is for" />
</div>
<div class="form-group">
<label>Allowed Values (comma-separated, blank for free-text)</label>
<input type="text" id="tag-values" placeholder="dev, test, stg, prod" />
</div>
<div class="form-group">
<label>Default Value (optional)</label>
<input type="text" id="tag-default" placeholder="e.g. dev" />
</div>
<div class="form-group">
<label>Applied At</label>
<select id="tag-scope">
<option value="Resource">Resource level</option>
<option value="ResourceGroup">Resource Group</option>
<option value="Subscription">Subscription</option>
<option value="All">All levels</option>
</select>
</div>
<div class="form-group">
<label>Enforcement</label>
<select id="tag-effect">
<option value="Deny">Deny (block deployment if missing)</option>
<option value="Audit">Audit (flag but allow)</option>
<option value="Modify">Modify (auto-add default value)</option>
</select>
</div>
<div class="toggle form-group">
<input type="checkbox" id="tag-required" checked />
<span class="toggle-label">Required Tag</span>
</div>
<button class="btn-primary btn-sm w-full mt-8" onclick="addTag()">+ Add Tag</button>
</div>
<div class="card">
<div class="card-title">🧪 Tag Validator</div>
<div class="text-sm text-muted mb-8">Paste a JSON object to validate it against your tag schema.</div>
<textarea id="tag-validator-input" rows="6" placeholder='{"Environment":"prod","Owner":"admin@company.com","CostCenter":"IT-001"}'></textarea>
<button class="btn-secondary btn-sm w-full mt-8" onclick="validateTagObject()">Validate</button>
<div id="tag-validator-result" class="mt-8"></div>
</div>
</div>
<!-- RIGHT: Tag table -->
<div class="flex-col">
<div class="card">
<div class="card-title">🗂 Tag Schema (<span id="tag-count">0</span> tags)</div>
<div class="table-wrap">
<table>
<thead>
<tr>
<th>Tag Key</th>
<th>Category</th>
<th>Required</th>
<th>Allowed Values</th>
<th>Scope</th>
<th>Effect</th>
<th></th>
</tr>
</thead>
<tbody id="tag-tbody">
<tr><td colspan="7" class="text-muted text-center">No tags defined. Load a template or add tags.</td></tr>
</tbody>
</table>
</div>
</div>
<div class="card">
<div class="card-title">📄 Azure Policy Snippet Preview</div>
<div class="text-sm text-muted mb-8">Preview the Azure Policy rule for the selected tag. Click a tag row to preview.</div>
<div id="tag-policy-preview" class="code-block">// Select a tag above to see its Azure Policy definition</div>
</div>
<div class="card">
<div class="card-title">📊 Tag Coverage Matrix</div>
<div id="tag-matrix" class="text-sm text-muted">Add tags to see the coverage matrix.</div>
</div>
</div>
</div>
</div>
<div class="tab-panel" id="tab-landingzone">
<div class="section-header">
<div class="section-title">🏗️ Azure Landing Zone Planner</div>
<div class="section-desc">Plan your Azure management group hierarchy and subscription layout following the CAF Azure Landing Zone (ALZ) reference architecture.</div>
<div class="section-actions">
<button class="btn-secondary btn-sm" onclick="exportLZ('json')">⬇ Export JSON</button>
<button class="btn-secondary btn-sm" onclick="exportLZ('markdown')">⬇ Markdown Outline</button>
<button class="btn-secondary btn-sm" onclick="exportLZ('terraform')">⬇ Terraform Skeleton</button>
</div>
</div>
<div class="grid-2 mb-8" style="gap:8px">
<button class="btn-primary btn-sm" onclick="loadLZTemplate('alz')">🏛 Load CAF ALZ Template</button>
<button class="btn-secondary btn-sm" onclick="loadLZTemplate('simple')">🔹 Load Simple Template</button>
<button class="btn-ghost btn-sm" onclick="clearLZ()">🗑 Clear</button>
</div>
<div class="sidebar-layout">
<!-- LEFT: Add nodes -->
<div class="flex-col">
<div class="card">
<div class="card-title">➕ Add Management Group</div>
<div class="form-group">
<label>Display Name</label>
<input type="text" id="lz-mg-name" placeholder="e.g. Platform" />
</div>
<div class="form-group">
<label>ID / Short Name</label>
<input type="text" id="lz-mg-id" placeholder="e.g. platform" />
</div>
<div class="form-group">
<label>Parent Management Group</label>
<select id="lz-mg-parent"><option value="">— Tenant Root —</option></select>
</div>
<div class="form-group">
<label>Type</label>
<select id="lz-mg-type">
<option value="Platform">Platform</option>
<option value="LandingZone">Landing Zone</option>
<option value="Sandbox">Sandbox</option>
<option value="Decommissioned">Decommissioned</option>
<option value="Custom">Custom</option>
</select>
</div>
<button class="btn-primary btn-sm w-full" onclick="addMG()">+ Add Management Group</button>
</div>
<div class="card">
<div class="card-title">➕ Add Subscription</div>
<div class="form-group">
<label>Subscription Name</label>
<input type="text" id="lz-sub-name" placeholder="e.g. sub-connectivity-prod" />
</div>
<div class="form-group">
<label>Parent Management Group</label>
<select id="lz-sub-parent"><option value="">— Select MG —</option></select>
</div>
<div class="form-group">
<label>Purpose / Description</label>
<input type="text" id="lz-sub-purpose" placeholder="e.g. Connectivity hub resources" />
</div>
<div class="form-row form-row-2">
<div class="form-group">
<label>Monthly Budget (USD)</label>
<input type="number" id="lz-sub-budget" placeholder="5000" />
</div>
<div class="form-group">
<label>Owner Email</label>
<input type="text" id="lz-sub-owner" placeholder="owner@company.com" />
</div>
</div>
<button class="btn-primary btn-sm w-full" onclick="addSubscription()">+ Add Subscription</button>
</div>
<div class="card">
<div class="card-title">💡 ALZ Design Principles</div>
<div class="flex-col gap-4 text-sm">
<div>🔹 <strong>Platform MG:</strong> Contains Connectivity, Identity, Management subscriptions</div>
<div>🔹 <strong>Landing Zones MG:</strong> Corp (private) and Online (internet-facing) workloads</div>
<div>🔹 <strong>Sandbox MG:</strong> Developer experimentation, relaxed policies</div>
<div>🔹 <strong>Decommissioned MG:</strong> Subscriptions pending deletion</div>
<div>🔹 <strong>Policy Inheritance:</strong> Policies at MG level apply to all child subscriptions</div>
<div>🔹 <strong>Max Hierarchy:</strong> Azure supports up to 6 levels of MG nesting</div>
</div>
</div>
</div>
<!-- RIGHT: Tree visualization -->
<div class="flex-col">
<div class="card">
<div class="card-title">🌲 Management Group Hierarchy</div>
<div id="lz-tree" class="mt-8">
<div class="text-sm text-muted text-center" style="padding:32px">Load a template or add management groups to visualize your hierarchy.</div>
</div>
</div>
<div class="card">
<div class="card-title">📊 Subscription Inventory</div>
<div class="table-wrap">
<table>
<thead><tr><th>Subscription</th><th>Management Group</th><th>Purpose</th><th>Budget/mo</th><th>Owner</th><th></th></tr></thead>